Time Rewizer  v.1.1
Created by: Mark Oostveen
MarkOostveen.TimeRewizer.AnimationRewizer Class Reference

Monobehaviour for Rewinding animations in unity More...

+ Inheritance diagram for MarkOostveen.TimeRewizer.AnimationRewizer:
+ Collaboration diagram for MarkOostveen.TimeRewizer.AnimationRewizer:

Classes

class  AnimatorParameter
 struct storing animator parameters More...
 
struct  Snapshot
 Snapshot holding animation info More...
 
struct  SnapshotData
 Snapshot data for animation rewinding More...
 

Public Member Functions

ISnapShot Track ()
 Return Current state of the object More...
 
void Rewind (ISnapShot variableStruct)
 Replaces current state of object with state given, Note object type must actually be snapshot value type of current type More...
 
void ForceRewind (ISnapShot variableStruct)
 Forces a value to be used for rewinding next frame More...
 
ScriptableBake LoadScriptableContent ()
 Returns scriptable object Reference More...
 
bool CompatibilityCheck (ScriptableBake scriptableobject, string tag)
 Indicates if scriptable object is compatible with this rewindable type More...
 

Public Attributes

Animator m_Animator
 Animator of character More...
 
AnimatorParameter [] m_Parameters
 Animator Parameters More...
 

Properties

RewizeSystem.ERewindingType RewindType [get, set]
 Setting with which the rewind manager threats this instance More...
 
GameObject Linkedobj [get]
 Game object connected to this instance More...
 
ScriptableBake PreLoadInfo [set]
 install baked info into object More...
 
bool Rewinding [get, set]
 Rewinding ON/OFF More...
 
bool Paused [get, set]
 Pause ON/OFF More...
 

Events

Action< SnapshotOnTracked
 Invoked when being tracked More...
 

Detailed Description

Monobehaviour for Rewinding animations in unity

Member Function Documentation

◆ CompatibilityCheck()

bool MarkOostveen.TimeRewizer.AnimationRewizer.CompatibilityCheck ( ScriptableBake  scriptableobject,
string  tag 
)

Indicates if scriptable object is compatible with this rewindable type

Parameters
scriptableobject
tag
Returns

Implements MarkOostveen.TimeRewizer.IRewizeable.

61  {
62  if (tag != "A_R") return false;
63 
64  if (m_PreLoadInfo != null)
65  return scriptableobject.GetContents(tag).Length > 0;
66  return true;
67  }
+ Here is the call graph for this function:

◆ ForceRewind()

void MarkOostveen.TimeRewizer.AnimationRewizer.ForceRewind ( ISnapShot  variableStruct)

Forces a value to be used for rewinding next frame

Parameters
variableStruct

Implements MarkOostveen.TimeRewizer.IRewizeable.

39  {
40  m_SnapshotValue = (Snapshot)variableStruct;
41 
42  m_ForceRewind = true;
43  }

◆ LoadScriptableContent()

ScriptableBake MarkOostveen.TimeRewizer.AnimationRewizer.LoadScriptableContent ( )

Returns scriptable object Reference

Returns

Implements MarkOostveen.TimeRewizer.IRewizeable.

50  {
51  return m_PreLoadInfo;
52  }
+ Here is the caller graph for this function:

◆ Rewind()

void MarkOostveen.TimeRewizer.AnimationRewizer.Rewind ( ISnapShot  variableStruct)

Replaces current state of object with state given, Note object type must actually be snapshot value type of current type

Parameters
variableStruct

Implements MarkOostveen.TimeRewizer.IRewizeable.

30  {
31  m_SnapshotValue = (Snapshot)variableStruct;
32  }

◆ Track()

ISnapShot MarkOostveen.TimeRewizer.AnimationRewizer.Track ( )

Return Current state of the object

Returns

Implements MarkOostveen.TimeRewizer.IRewizeable.

19  {
20  OnTracked?.Invoke(m_SnapshotValue);
21  return m_SnapshotValue;
22  }

Member Data Documentation

◆ m_Animator

Animator MarkOostveen.TimeRewizer.AnimationRewizer.m_Animator

Animator of character

◆ m_Parameters

AnimatorParameter [] MarkOostveen.TimeRewizer.AnimationRewizer.m_Parameters

Animator Parameters

Property Documentation

◆ Linkedobj

GameObject MarkOostveen.TimeRewizer.AnimationRewizer.Linkedobj
get

Game object connected to this instance

37 { get; private set; }

◆ Paused

bool MarkOostveen.TimeRewizer.AnimationRewizer.Paused
getset

Pause ON/OFF

55 { get; set; }

◆ PreLoadInfo

ScriptableBake MarkOostveen.TimeRewizer.AnimationRewizer.PreLoadInfo
set

install baked info into object

43  {
44  set => m_PreLoadInfo = value;
45  }

◆ Rewinding

bool MarkOostveen.TimeRewizer.AnimationRewizer.Rewinding
getset

Rewinding ON/OFF

50 { get; set; }

◆ RewindType

RewizeSystem.ERewindingType MarkOostveen.TimeRewizer.AnimationRewizer.RewindType
getset

Setting with which the rewind manager threats this instance

32 { get; set; }

Event Documentation

◆ OnTracked

Action<Snapshot> MarkOostveen.TimeRewizer.AnimationRewizer.OnTracked

Invoked when being tracked