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"

Top down template look at enemy while moving to location?

I'm currently using the top-down template and would like to make it so that the player can "lock on" to an enemy.

Essentially, while the player pawn is locked on to an enemy, the player can still click to move the pawn around, but the pawn will remain facing the enemy and appropriately back up, strafe or what have you to the clicked location.

So if the enemy is directly in front of the character and you click directly to the character's right, the character will remain looking at the enemy and simply strafe right. Clicking behind the character will cause him to back up away from the enemy.

I've got it so that the player will remain facing the enemy, but I am unsure how to affect the player animation depending on the clicked location relative to the player. The default animbp just calculates speed.

Thanks in advance.

Product Version: UE 4.20
more ▼

asked Oct 03 '18 at 04:25 AM in Blueprint Scripting

avatar image

6 6 6 11

(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