Add this class on a Transform, and it'll record its position periodically The Positions array can then be read from anywhere to know where that object was in the past
More...
Inherits MonoBehaviour.
Add this class on a Transform, and it'll record its position periodically The Positions array can then be read from anywhere to know where that object was in the past
◆ Modes
the possible modes to run this recorder on
Enumerator |
---|
Framecount | |
Time | |
◆ Awake()
virtual void MoreMountains.Tools.MMPositionRecorder.Awake |
( |
| ) |
|
|
protectedvirtual |
On Awake, we initialize our array of positions
◆ StorePositions()
virtual void MoreMountains.Tools.MMPositionRecorder.StorePositions |
( |
| ) |
|
|
protectedvirtual |
Stores the position in the array and offsets it
◆ Update()
virtual void MoreMountains.Tools.MMPositionRecorder.Update |
( |
| ) |
|
|
protectedvirtual |
On Update we store our positions
◆ _frameCountLastRecord
int MoreMountains.Tools.MMPositionRecorder._frameCountLastRecord = 0 |
|
protected |
◆ _timeLastRecord
float MoreMountains.Tools.MMPositionRecorder._timeLastRecord = 0f |
|
protected |
◆ FrameCounter
int MoreMountains.Tools.MMPositionRecorder.FrameCounter |
the current frame counter
◆ FrameInterval
int MoreMountains.Tools.MMPositionRecorder.FrameInterval = 0 |
the amount of frames to wait for between two recordings
◆ Mode
whether to record every X frames, or every X seconds
◆ NumberOfPositionsToRecord
int MoreMountains.Tools.MMPositionRecorder.NumberOfPositionsToRecord = 100 |
the amount of positions to record
◆ Positions
Vector3 [] MoreMountains.Tools.MMPositionRecorder.Positions |
the array of positions (0 most recent, higher less recent)
◆ RecordOnTimescaleZero
bool MoreMountains.Tools.MMPositionRecorder.RecordOnTimescaleZero = false |
whether or not to record if the timescale is 0
◆ TimeInterval
float MoreMountains.Tools.MMPositionRecorder.TimeInterval = 0.02f |
the duration (in seconds) between two recordings
The documentation for this class was generated from the following file:
- F:/Github/Store/InventoryEngineStore/Assets/InventoryEngine/MMTools/Tools/MMMovement/MMPositionRecorder.cs