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"

AnswerHub Maintenance

Background maintenance is scheduled to occur between 9 - 11am EDT on Tuesday, May 21. Site operation may be slower than normal during this time and a brief interruption in operation may be observed

How do I make my actor look at the center of the camera view when holding right mouse button (in third person)?

So I am making my "game", and I would like a mechanic that makes the character turn to where you're looking at with the mouse when you're holding right mouse button. I have puzzled around a bit but I just can't seem to find the answer.

Can you guys help me?

Also, if you want to help me out more with UE4 you can add me on discord: Jevise#6274 Thanks!

Product Version: UE 4.12
more ▼

asked Jul 23 '17 at 03:50 PM in Blueprint Scripting

avatar image


(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

Line trace from your cursor position to the ground, then set your character's rotation to be the value of a Find Look at Rotation using the character's location and the line-trace hit location. You'll also want to zero-out the Z values so that the character doesn't rotate up or down.

To get the Mouse location and direction for trace, use this...

more ▼

answered Jul 24 '17 at 03:46 AM

avatar image

2.1k 38 17 52

(comments are locked)
10|2000 characters needed characters left
Your answer
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