CheckTransformChangedSinceLastCheckByObject Class Reference

Provides the ability to check if a transform has changed, as far a particular object is concerned. It returns true only if the transform has actually changed since the last time the provided object was used to check if had changed. Note: any scripts that specifically set a monitors transform's hasChanged flag to false, will render this class non-functional for that transform.

Static Public Member Functions

static void Clear ()
 Clears the internal storage of which objects have check for changes, for all transforms. Does NOT affect the transforms' "hasChanged" state.
 
static bool HasChangedByObject (this Transform transformToCheck, object whosAsking, bool includeDecendants=false)
 This function will return the HasChanged value of this component's transform, uniquely for the 'whosAsking' object passed to this function. So, calling this function after the transform has changed, with the same object passed as the parameter- will yield true only the first time it's called, and false thereafter (until the transform changes again). But calling the function with different object parameters, would yield true for each different object passed (the first time is passed- until the transform changes again).
 
static void SetHasChangedByObject (this Transform transformToCheck, object whosAsking, bool setTo, bool includeDecendants=false)
 Allows the user to manually change the hasChanged flag for a particular transform and checking object combination. If this particular transformToCheck/whosAsking combination does not exist in the internal dictionary, a new entry will be added.