In the 3rd Person template, what actually causes the camera on the springarm to work? I found a lot of articles saying to use BeginPlay to set the view target, but I’m not seeing that anywhere in the template. I want to learn this by creating a blank game, and making a camera and springarm then have it use that camera, but to understand it I think I need to know how it’s working in the template. Can someone please help?
tl;dr: the springarm is using control rotation
-
the
Player Controller
has aControl Rotation
rotator attribute other actors can utilise. In short: tell the controller a rotation value and any other entity can query it.[This rotation scheme meshes well with
Pawn
andCharacter
classes and can be automatically inherited, too.] -
the
Character
in the template is instantiated by theGame Mode
and possessed, making callingSet View Target with Blend
redundant. Possession already tells the controller which view target to look through. -
the character’s
Springarm
(here renamed to CameraBoom) takes advantage ofControl Rotation
and the mouse input in the character adjusts it:
I want to learn this by creating a blank game, and making a camera and springarm then have it use that camera
Do note that this is a neat way to handle camera / character rotation but your mileage may vary as you may simply have other needs / requirements.
Completely awesome repy, thank you!
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.