Rotate view with a trigger box

Hi guys, I’m working on a Top Down shooter and I need to set some trigger boxes on the map, that makes the camera and the character rotating by 90 degrees in the right direction.
For example, let’s say my character, when the game starts, spawns in a certain place on the map, and both him and camera are facing the north. He walks forward until he reaches a crossroad, and there turns right.I’ll put there a trigger box, and when he collide with that both the camera and the character rotate by 90 degrees on the left, so now they are facing the east. I need also that, if he turns back and walks through the box trigger again by the other side, they rotates again to the initial position (facing north).

Is there a way to do something like this using blueprints? I wonder if could be easier to have two cameras attached to my character, and switch from one to the other when he walks through the boxtrigger, instead of rotating one single camera, but I’d anyway need to rotate the character, otherwise the movement key would swap to each other.

It’s possible, here’s how I did it using the TwinStickShooter template. Tried to go off of what you wrote but I’m not sure how you’re doing your character movement, but this should be a good starting point for you!

  • I created a Child Blueprint Class off of Trigger Box
  • Add a **Float **variable *FaceAngle *and mark it as Editable
  • On ***BeginOverlap ***for our new trigger Cast to the TwinStickPawn to get a handle on the Camera Boom component
  • I used *WorldRotation *to set a new one on the Camera Boom using the FaceAngle from the trigger + with a Y pitch -90 (to keep the camera in the sky because how the TwinStick camera is set up)

Then just place the new triggers in your map and in the properties set **FaceAngle **variable per trigger.

In my example I have the camera face 90° when you make that right hitting the selected trigger, and on the trigger to the left of it it’s set at 0° to go back to normal. Two triggers to detect in and out.

Caveats – The controls don’t change with the camera, something you’ll have to think about.

Hi! Your bp is perfect, the camera rotates axactly as i wanted to!
You were right anyway, Controls don’t change, so my character moves forward with D key, and left with W key… I’ve tried some nodes but I’m still not so experienced with blueprints.
I think there are two possible solutions: the first one is to swap the Input axis moveup and input axis moveright keys, but I really don’t know hot to do this via blueprint.
The second solution is to change the forward axis of my character’s skeletal mesh… something like rotating the mesh in the character blueprint, but using nodes… all attempts have failed.
This is my last one, I don’t even know if it does make sense… Maybe using the “set world location” function is useless, but I don’t know how to use the Rotate Vector’s return value. Am I on the wrong way?
83b1f44f8288df93af93569f08255529f234262e.jpeg