Skip to content

Camera Controller

A Camera Controller is a component attached to a camera object that has at most one associated Camera Shot reference. This associated camera shot can be changed at runtime and will dictate the behavior of the camera controller.

Main Camera

Most games will only have one single camera. The camera in these cases will have the Main Camera component attached, which is a camera controller that can be accessed globally by any script.

Creating the Main Camera

To create a main camera, right click on the Hierarchy Panel and select Game Creator → Cameras → Main Camera from the dropdown menu.

Main Camera

The Main Camera component has the following sections:

  • Time Mode: Defines the time mode used to update the camera. By default it uses the Game Time option, which is affected by the game's time scale (so the camera freezes when the time scale is set to zero). The Unscaled Time option ignores the time scale.
  • Run In: Determines whether the camera is updated every frame (Main Update) or in sync with the physics engine (Fixed Update).
  • Transition: Contains the Camera Shot currently associated with this camera controller. If none is set, the camera won't have any behavior. It also allows you to smooth the position and rotation changes of the camera.
  • Avoid Clip: Allows the camera to avoid clipping through the geometry of the scene.

Smooth Camera Movement

The Shot's smoothing options determine how much the camera lags from the Shot's behavior. It's recommended to add some lag to avoid any jittering. However, introducing too much lag will make controls feel a bit unresponsive.

Transition to a new Shot

To transition a Camera Controller from one Camera Shot to another one, it's recommended to use the Change to Shot instruction.

Change Camera Shot instruction

Simply drop in the Camera Shot you want the Camera Controller to mimic and how long it should take to transition. Game Creator will handle the rest.