|  | Adventure Creator 1.84.3
    An adventure game toolkit for Unity, by Chris Burton, ICEBOX Studios 2013-2024 | 
 
 | Public Member Functions | |
| void | CentreToCamera () | 
| Public Attributes | |
| _Camera | cameraToAlignTo | 
| bool | lockDistance = true | 
| float | distanceToCamera | 
| bool | lockScale | 
| Vector2 | scaleFactor = Vector2.zero | 
| AlignType | alignType = AlignType.YAxisOnly | 
| Protected Member Functions | |
| void | Awake () | 
| void | Update () | 
| void | Align () | 
| void | CalculateScale () | 
Aligns an object to a camera's viewport. This is intended for sprites being used as foreground objects in 2.5D games.
| void AC.AlignToCamera.CentreToCamera | ( | ) | 
Attempts to place the GameObject in the centre of cameraToAlignTo's view.
| AlignType AC.AlignToCamera.alignType = AlignType.YAxisOnly | 
How the object is aligned (YAxisOnly, CopyFullRotation)
| float AC.AlignToCamera.distanceToCamera | 
How far to place the GameObject away from the cameraToAlignTo, once set
| bool AC.AlignToCamera.lockDistance = true | 
If True, the distance from the camera will be fixed (though adjustable in the Inspector)
| bool AC.AlignToCamera.lockScale | 
If True, the percieved scale of the GameObject, as seen through the cameraToAlignTo, will be fixed even if the distance between the two changes
| Vector2 AC.AlignToCamera.scaleFactor = Vector2.zero | 
If lockScale is True, this GameObject's scale will be multiplied by this value