Skip to content

Set Camera Type

Set Camera Type

Changes the camera mode between 2D and 3D, and select the projection type for 3D cameras.

Properties

System

Name Explanation Type
2D Whether the camera uses 2D mode. Toggle
3D Whether the camera uses 3D mode. Toggle
First Person Mode Whether the camera uses first person perspective in 3D mode. Toggle
Orthographic Projection Whether the camera uses orthographic projection in 3D mode. Toggle
Perspective Projection Whether the camera uses perspective projection in 3D mode. Toggle
Reset to Default Whether to reset the camera type to its default configuration. Toggle

Examples

Switch to 2D Camera Mode

This sets the camera to 2D mode.

set_camera_type(2d);
{"Data":{"Is2D":true,"IsFirstPerson":false,"IsOrthographic":true,"IsPerspective":false,"IsReset":false,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Map.MapCameraTypeCommand"}

Switch to 3D Camera with Perspective Projection

This sets the camera to 3D mode with perspective projection.

set_camera_type(3d, perspective);
{"Data":{"Is2D":false,"IsFirstPerson":false,"IsOrthographic":false,"IsPerspective":true,"IsReset":false,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Map.MapCameraTypeCommand"}

Switch to 3D Camera with First Person Mode

This sets the camera to 3D mode with first person perspective.

set_camera_type(3d, first_person);
{"Data":{"Is2D":false,"IsFirstPerson":true,"IsOrthographic":false,"IsPerspective":false,"IsReset":false,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Map.MapCameraTypeCommand"}

Reset Camera Type to Default

This resets the camera type to its default configuration.

set_camera_type(reset);
{"Data":{"Is2D":false,"IsFirstPerson":false,"IsOrthographic":true,"IsPerspective":false,"IsReset":true,"Metadata":null},"TypeName":"MAR.Game.RPGCore.Models.Scripts.Commands.Map.MapCameraTypeCommand"}