Inheritance
SpatialScrollModule.SpatialScrollData
public class SpatialScrollData : INodeToRay
Constructors
Declaration
public SpatialScrollData(IControlSpatialScrolling caller, Node node, Vector3 startingPosition, Vector3 currentPosition, float repeatingScrollLengthRange, int scrollableItemCount, int maxItemCount = -1, bool centerVisuals = true)
Parameters
Properties
The object/caller initiating this particular spatial scroll action
Declaration
public IControlSpatialScrolling caller { get; set; }
Property Value
If true, expand scroll visuals out from the center of the trigger/origin/start position
Declaration
public bool centerVisuals { get; set; }
Property Value
The current scroll position
Declaration
public Vector3 currentPosition { get; set; }
Property Value
Value representing how much of the pre-scroll drag amount has occurred
Declaration
public float dragDistance { get; set; }
Property Value
Maximum number of items (to be scrolled through) that will be allowed
Declaration
public int maxItemCount { get; set; }
Property Value
The node on which this spatial scroll is being processed
Declaration
public Node node { get; set; }
Property Value
0-1 offset/magnitude of current scroll position, relative to the trigger/origin/start point, and the repeatingScrollLengthRange
Declaration
public float normalizedLoopingPosition { get; set; }
Property Value
Bool denoting that the scroll trigger magnitude has been exceeded
Declaration
public bool passedMinDragActivationThreshold { get; }
Property Value
The ray origin on which this spatial scroll is being processed
Declaration
public Transform rayOrigin { get; set; }
Property Value
Type |
Description |
Transform |
|
The magnitude at which a scroll will repeat/reset to its original scroll starting value
Declaration
public float repeatingScrollLengthRange { get; set; }
Property Value
Number of items being scrolled through
Declaration
public int scrollableItemCount { get; set; }
Property Value
The vector defining the spatial scroll direction
Declaration
public Vector3? spatialDirection { get; set; }
Property Value
The origin/starting position of the scroll
Declaration
public Vector3 startingPosition { get; set; }
Property Value
Methods
Declaration
public void UpdateExistingScrollData(Vector3 newPosition)
Parameters
Type |
Name |
Description |
Vector3 |
newPosition |
|
Extension Methods