|
Adventure Creator 1.85.1
An adventure game toolkit for Unity, by Chris Burton, ICEBOX Studios 2013-2025
|
Public Member Functions | |
| virtual Vector2 | CreateRotationOffset () |
| Returns a vector by which to tweak the camera's rotation. The x-axis will control the spin, and the y-axis will control the pitch. | |
| virtual void | SwitchTarget (Transform _target) |
| Switches the camera's target. | |
| virtual bool | Is2D () |
| Checks if the camera is for 2D games. This is necessary for working out if the MainCamera needs to change its projection matrix. | |
| virtual void | _Update () |
| virtual void | ResetTarget () |
| virtual void | MoveCameraInstant () |
| void | SetSplitScreen () |
| void | RemoveSplitScreen () |
| virtual Vector2 | GetPerspectiveOffset () |
| Gets the actual horizontal and vertical panning offsets. | |
| bool | IsActive () |
| Checks if the Camera is currently the MainCamera's active camera (attachedCamera) | |
| void | MakeActive () |
Public Attributes | |
| bool | targetIsPlayer = true |
| Transform | target |
| bool | isDragControlled = false |
| float | focalDistance = 10f |
| bool | updateWhilePaused = false |
Protected Attributes | |
| Char | targetChar |
| Camera | _camera |
| Vector2 | inputMovement |
| bool | is2D = false |
Properties | |
| Transform | Target [get] |
| Transform | CameraTransform [get] |
| Transform | Transform [get] |
| Camera | Camera [get] |
| bool | isFor2D [get, set] |
| virtual TransparencySortMode | TransparencySortMode [get] |
| Vector3 | TargetForward [get] |
| virtual bool | CursorOffsetForcesTranslation [get] |
The base class for all Adventure Creator cameras. To integrate a custom camera script to AC, just add this component to the same object as the Camera component, and it will be visible to AC's fields, functions and Actions.
|
virtual |
Updates the camera. This is called every frame by StateHandler.
Reimplemented in AC.GameCamera, AC.GameCamera2D, AC.GameCamera2DDrag, AC.GameCameraAnimated, and AC.GameCameraArray.
|
virtual |
Returns a vector by which to tweak the camera's rotation. The x-axis will control the spin, and the y-axis will control the pitch.
<return>A vector by which to tweak the camera's rotation.
Reimplemented in AC.CursorInfluenceCamera, and AC.GameCamera2D.
|
virtual |
Gets the actual horizontal and vertical panning offsets.
Reimplemented in AC.GameCamera25D, AC.GameCamera2D, and AC.GameCamera2DDrag.
|
virtual |
Checks if the camera is for 2D games. This is necessary for working out if the MainCamera needs to change its projection matrix.
Reimplemented in AC.GameCamera2D, and AC.GameCamera2DDrag.
| bool AC._Camera.IsActive | ( | ) |
Checks if the Camera is currently the MainCamera's active camera (attachedCamera)
| void AC._Camera.MakeActive | ( | ) |
Makes the Camera the MainCamera's active camera (attachedCamera)
|
virtual |
Moves the camera instantly to its destination.
Reimplemented in AC.GameCamera, AC.GameCamera25D, AC.GameCamera2D, AC.GameCameraAnimated, and AC.GameCameraArray.
| void AC._Camera.RemoveSplitScreen | ( | ) |
Removes the split-screen effect on this camera.
|
virtual |
Auto-assigns "target" as the Player prefab Transform if targetIsPlayer = True.
Reimplemented in AC.FirstPersonCamera, and AC.GameCamera25D.
| void AC._Camera.SetSplitScreen | ( | ) |
Enables the camera for split-screen, using the MainCamera as the "main" part of the split, with all the data.
|
virtual |
| float AC._Camera.focalDistance = 10f |
The camera's focal distance
| bool AC._Camera.isDragControlled = false |
If True, then the camera can be drag-controlled (used for GameCameraThirdPerson only)
| Transform AC._Camera.target |
The Transform that affects the camera's movement
| bool AC._Camera.targetIsPlayer = true |
If True, the camera will move according to the Player prefab
| bool AC._Camera.updateWhilePaused = false |
If True, the camera will not be frozen while the game is paused
|
get |
The Unity Camera component
|
get |
The Unity Camera's Transform
|
get |
If True, then the influence of the cursor (if any) will cause a change in position, rather than rotation
|
getset |
True if the game plays in 2D, making use of 2D colliders and raycasts
|
get |
The Transform that affects the camera's movement. If targetIsPlayer = True, this will return the Player's Transform.
|
get |
A cache of the object's transform component
|
get |
The camera's transparency sort mode. This will be copied over to the MainCamera when switched to