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"

"Set Actor Rotation" doesn't work...

Hi there! :) I'm trying to make a blueprint of a function so that if the character walks into a box trigger and presses spacebar while in it, it automatically rotates the character so it faces the same (world) direction as the box trigger. I was able to figure out pretty much everything on how to do it, however my character does absolutely nothing when I press spacebar. I am able to get the specific yaw (for example -90) of the box trigger I'm standing in, but when I tried to apply the yaw to the new character rotation, it just doesn't work :( I've spent so much time trying to fix this already without any luck that I decided to try and get some help from you guys. Included is screenshot from my blueprint of the first person character. The relevant part is the uppermost branch of the graph. Can someone help me with this please? Thanks!! :)

problem

Product Version: Not Selected
Tags:
more ▼

asked Apr 06 '15 at 09:26 PM in Blueprint Scripting

avatar image

Kiwi2703
25 6 5 8

avatar image vanlacke Apr 06 '15 at 09:30 PM

Have you narrowed down the issue?

Are all the branches going through?

Is the input firing?

Have you compared the Other Actor rotation with your player rotation?

avatar image Kiwi2703 Apr 06 '15 at 09:34 PM

Thanks for the reply! I've been trying to solve this particular issue for half a day and I really tried everything I could think of. The input is firing, I tested that. Also when I connect "make rot" function to the "new rotation" of the "set actor rotation" with some random pitch, roll and yaw numbers, it does rotate the actor, but ONLY the pitch and roll work. It totally ignores the yaw amount for some reason. And when I connect it like in the picture I posted, it ignores the rotation of the reference object altogether.

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

4 answers: sort voted first

Alright, did some testing and the issue is that setting the actor rotation does nothing because your character rotation tied to the PlayerController.

So, you need to rotate your controller.

alt text

That should do it, hope I made sense!

rotate.png (105.1 kB)
more ▼

answered Apr 06 '15 at 09:55 PM

avatar image

vanlacke
1.5k 65 132 103

avatar image Kiwi2703 Apr 06 '15 at 10:40 PM

Thanks, but I can't find the "Set Control Rotation" function, only "Set Actor Rotation" and with that it doesn't work :/

avatar image vanlacke Apr 06 '15 at 10:49 PM

Even if you drag from the Get Player Controller? You could also turn off the "context sensitive" option at the top right when adding a node

avatar image Kiwi2703 Apr 06 '15 at 10:54 PM

Oh yeah, the context sensitive options needed to be turned off :) It works now! Thank you!!

avatar image vanlacke Apr 06 '15 at 11:02 PM

Awesome, could you set this as answered? Thanks :)

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

The same issue occurs when the pawn you are trying to manipulate doesn't have a camera within the class (rookie mistake, I know but that's how i ended up at this post).

more ▼

answered Jun 28 '17 at 02:11 PM

avatar image

EagleEye314
11 1 3

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

I know that I'm to late with the answer but maybe I will help some beginners. The correct answer is: You are using Character as base class and probably you forgot to unselect "Use Controller Rotation Yaw".

more ▼

answered Mar 09 '19 at 03:05 AM

avatar image

Czubaka1234
1

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

FYI, if you only need to add deltas then as of Unreal Engine 4.21, and maybe earlier, there's are helpful blueprint nodes under Pawn> Input> Add Controller Pitch/Roll/Yaw Input. For example:alt text

more ▼

answered Apr 03 '19 at 12:50 AM

avatar image

christopheraugustus
31 1 3

(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