void OnActionComplete(ArAction actionTaken, GameObject prefabInstance) { if (prefabInstance && optionalPrefab) { if (prefabInstance != optionalPrefab) { return; } } if (actionTaken == actionRequired) { ActionCompletedEvent.Invoke(); if (!overrideFadeOutTransition) { fader.FadeOutNow(); } else { DoneFadeOut(); } } }
IEnumerator FireActionTakenEvent(ArAction actionMade, GameObject inst) { bool isObjectManipulateAction = (actionMade == ArAction.PrefabMoved || actionMade == ArAction.PrefabScaled || actionMade == ArAction.PrefabRotated); if (actionMade == lastAction && isObjectManipulateAction) // same object, same thing, don't fire event { yield break; } if (inst) { Debug.Log("Action invoked: " + actionMade.ToString() + " on " + inst.name); } else { Debug.Log("Action invoked: " + actionMade.ToString()); } OnActionTaken?.Invoke(actionMade, inst); // Inform whoever's listening (e.g. ArInstructionController) lastAction = actionMade; yield return(null); }
public virtual void remAction(ArAction action) { AriaCSPINVOKE.ArActionGroup_remAction(swigCPtr, ArAction.getCPtr(action)); }
public static global::System.Runtime.InteropServices.HandleRef getCPtr(ArAction obj) { return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr); }
public virtual void addAction(ArAction action, int priority) { AriaCSPINVOKE.ArActionGroup_addAction(swigCPtr, ArAction.getCPtr(action), priority); }