Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

Knockback Attack

Hi Is there any way to create a 'knockback' attack in UE4? I'm trying to recreate a move where the person utilizes control of gravity to push back a specific opponent, or just knockback everything around them.

I'm aware of 'Launch Character', but have no idea how to use it, or if its even relevant to creating an attack where you can push people or things away from you. Thanks in advance.

Product Version: UE 4.19
more ▼

asked May 09 '18 at 06:23 PM in Blueprint Scripting

avatar image

1 1 2 4

avatar image ThompsonN13 May 09 '18 at 10:58 PM

below is one method i used to implement a knockback. it was based on a begin overlap event and the blue line you see that goes off screen is the actor to be knocked back (a character in this case), the cube is the mesh of the actor that is knocking things away. this is physics based but im sure theres another method that could be done using other means.

alt text

capture.png (141.5 kB)
avatar image Danial.A9 May 13 '18 at 02:15 PM

So for the cube that is knocking the actor away, i assume its invisible right? do you have it being launched at the character? Could I theoretically spawn this invisible cube on my character, then anyone who steps inside it would be launched/knocked back? Thanks

avatar image ThompsonN13 May 13 '18 at 02:57 PM

in the example the way i was working it was when the character overlapped the cube they would be knocked back. but in your case you could probably just use another character location and have the ability triggered off of a input event.

heres a little example on how this could be used as an on use ability. i made it very quickly so it may not be optimal but it shows how you could set it up. also you could use the launch character node instead of the add impulse is you wanted to.

alt text

capture.png (269.1 kB)
(comments are locked)
10|2000 characters needed characters left
Viewable by all users

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question