Using Custom Static Cameras for 'Look At' events

+
Using Custom Static Cameras for 'Look At' events

Figured this out tonight in case others care:

You can trigger custom cameras during gameplay, if you want to make the camera look at a monster spawning or a particular spot in your level, for example. With the current inability to make cutscenes, this is pretty useful. You can also make the camera follow the player from a different static perspective, which could be used for interesting gameplay opportunities.

This assumes you know how to use triggers.

1) Search for 'static_camera' entity in the asset browser
2) Copy it to your level and rename it whatever you want
3) Place it in your level
4) Tag it
5) In your quest, use one of the Camera blocks ('Run Static Camera' for example) to trigger the camera. You can use an area trigger but I imagine you can fire it off pretty much anything.
6) Change the camera's settings as you please.

View attachment 238

'ActivattionDuration/DeactivationDuration' control the time it takes for the camera to move from the default 3rd person position to the camera. 0 means an instant cut to the new camera.
Timeout is the duration of the camera. 0 is infinite.
Zoom/Fov are self explanatory.
animState controls whether the camera is 100% static or if there is some sway on it.
blockPlayer controls whether or not the player is able to move during the static camera.

The more interesting setting is TargetController at the bottom. If you set it to Dynamic, you can make the camera follow the player's position (but the camera remains static in position in the world) by using PLAYER as the tag.

You can chain multiple cameras using the 'Run Static Camera Sequence' block, with each camera's 'Timeout' being its duration.

You can also chain multiple cameras based on where the player is, using multiple area triggers. For example, if you want to make some sort side-scrolling sequence in your level, you could simply place multiple static cameras along the path the user will take, and have the camera switch to the next camera and so on fairly smoothly by putting a high activationDuration value.

Lastly, you can essentially create an isometric camera by setting movementController to SphereArea and putting 'PLAYER' in the tag field, but it's kind of janky.
 

Attachments

  • Capture.jpg
    Capture.jpg
    12.9 KB · Views: 85
Top Bottom