x

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"

how do i get my pawn to move forward?

Hello!

when i press w i want my pawn to move forward. and it does move forward. but if i turn 90 degrees clockwise and press w again my pawn moves to the left. what do i need to do so that my pawn moves like in the FPS example project or Call of Duty or nearly every other FPS game?

Thanks,

wamo

Product Version: UE 4.16
Tags:
more ▼

asked Oct 02 '17 at 01:15 PM in Using UE4

avatar image

wambo0402
12 4 3 5

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Mutiply it with the forward vector of your pawn

more ▼

answered Oct 02 '17 at 04:32 PM

avatar image

Iotti
524 1 4 8

avatar image wambo0402 Oct 03 '17 at 05:12 PM

i'm sorry i don't understand what you mean. multiply what with the forward vector of the pawn?

here is what i have now: alt text

foward.jpg (30.3 kB)
avatar image Iotti Oct 04 '17 at 07:32 PM

First, really sorry for the delay, I got some problems so I couldn't respond you properly.

Now, the first thing to check is if the Control Rotation is changing, can you print it? If it is changing, I may recomend you to get a fixed vector, like 1,0,0 and try to rotate it with the Control Rotation before set it to Add Movement Input

avatar image wambo0402 Oct 05 '17 at 09:24 AM

No worries, thanks for your reply! I followed your advice and printed the control rotation. stayed at 0 always. what i forgot to mention is that i'm working in VR with a vive. maybe that has something to do with it.

anyway i figured it out yet. i locked the camera of my pawn to the hmd and got the rotation from the camera, see attached picture. i had to do it this way because the "Get Orientation and Direction" function for HMDs wasn't working. when i used that i got weird movement during playing when i looked around. but thats an other story.

thank you for your help! it now works as intended

alt text

working.jpg (53.6 kB)
(comments are locked)
10|2000 characters needed characters left
Viewable by all users
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