VisualRotationMimic
A class in Root.Township, the global namespace.
Client: turns this transform to follow how a target transform turns, tracked through one axis and optionally scaled. Off on a headless server.
- Listed in Global namespace: T to X
- Inherits or implements
MonoBehaviour
Constructors
| Member | What it is |
|---|---|
VisualRotationMimic() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
6 private and internal fields
| Member | What it is |
|---|---|
private Transform cachedTransform | This object's transform. |
private IUnityUpdateMethod copyRotation | Handle for the registered late-update method. |
private Vector3 lastValue | The target's axis direction, in this transform's space, from the last update. |
private Vector3 nonRotationAxis | Axis on the target whose direction is tracked (default forward). |
private float rotationMultiplier | Scales the copied rotation angle. |
private Transform targetTransform | Transform whose rotation is followed. |