I am creating a prop hunt minigame in UE5 and am trying to create a rotation system that will work with it.
I have implemented a first-person system that hunters should be able to use, as well as a third-person that both hunters and hiders should be able to use.
When a player is hiding as a prop, I’d like to force them into the third-person mode, and always have their player model rotated in the same orientation as their camera UNLESS they press a “lock rotation” InputAction, which will allow them to move their camera, but not the player model itself.
I have achieved a close result with the “Use Controller Rotation Yaw” Set node, however, this method only affects rotation on the client’s own game, and does not affect others. I need a solution that will update the player’s rotation for all clients.
(Additionally, I need a way to distinguish between a hider and a seeker to determine whether I should allow the player to go into the first-person mode or lock rotation, as well as whether or not they have a gun or can hide as a prop.)
My Toggle Perspective Event Segment:
TL;DR I need a way to rotate a player’s mesh server-wide and a way to lock the rotation with an InputAction keybind.