I have been trying to set the rotation of my FPS character from the FPS template using c++. I want to set the rotation instantly but SetActorRotation does not seem to work for some reason.
Am i supposed to use another function to set the rotation or something?
No, what i want is to set the player characters rotation instantly. As an example, if something happens to the player i want to set the rotation instantly to a certain value to have the player instantly look in that direction.
I’m actually having a similar problem using a blueprint.
I’m using a key press Q or E to have the character “look” 90 degrees left or right but when I have the player selected in the inspect in game mode and I press the key nothing happens to the rotation value … other than a odd jittery small movement of the z axes (the roll?) but in this case I’m trying to adjust the Yaw
I’m attaching a sample of the Q to look left , in this case I get the actor’s current rotation , break it apart so I can add the yaw 90 degrees and then make a new rotation and then pass it to the setactorlocationandrotation (I’ve also tried setactorrotation)
I’m not posting this to hijack your question ; I think we have the same question in blueprint and c++ but it makes me wonder if something is not working right especially given this bug that was posted not long ago:
Interestingly enough though; I don’t exactly have that issue? I wonder if they fixed the visual component but something in the method source is wrong? I’m new at UE4 so I’m probably doing something wrong