private readonly int _Progress | Shader property ID for the fade progress. |
private float acceleration | Page acceleration toward the target. |
private int animatingPages | Pages still to land. The book closes when this reaches 0. |
private Material animationMaterial | Material copy whose _Progress drives the fade. |
private Animator animator | Animator for opening and closing. |
private TransformEvent bookAppearsAfterRotatingEffect | Event raised after the fade in, before opening. |
private TransformEvent bookAppearsBeforeRotatingEffect | Event raised when the book is positioned. |
private TransformEvent bookCloseEffect | Event raised once the book has closed. |
private TransformEvent bookDisappearAfterRotatingEffect | Event raised when the fade out ends. |
private float closeDuration | Time the close animation is given (default 0.25s). |
private static List<GhostBook> currentlyOpenBooks | Static list of books that are open or opening, for reuse by nearby pages. |
private float fadeDuration | Fade in and fade out time. |
private bool isOpen | Whether the open animation has finished. |
private float maxDistanceToReuseSquared | Squared distance within which a new page reuses this book. |
private float movementLerpSpeed | Not used in this file. |
private float moveSpeed | Page move speed toward the target. |
private readonly int Open | Animator hash for the Open bool. |
private float openDuration | Time the open animation is given (default 0.25s). |
private TransformEvent pageAddedEffect | Event raised for each page that lands. |
private List<PageAutoAddEffect> pagesToAdd | Pages queued for this book, released when it closes. |
private Transform pageTarget | Transform pages fly to. |
private Vector3 placedRotation | Rotation offset applied on top of the placed rotation. |
private float rotationLerpSpeed | Page rotation lerp speed, faster as the page gets close. |
private float scaleLerpSpeed | Page scale lerp speed. |
private float snapDistanceSquared | Squared distance at which a page snaps to the target. |
private float snapDuration | Not used in this file. |
private Vector3 targetPagePosition | Page target position stored in Position. |
private Quaternion targetPageRotation | Page target rotation stored in Position. |
private Vector3 targetPageScale | Page target scale stored in Position. |