public static IExecuteNodeChain Repeat <T>(this T selfbehaviour, int count = -1) where T : MonoBehaviour { var retNodeChain = new RepeatNodeChain(count); retNodeChain.Executer = selfbehaviour; // dispose when distroyed retNodeChain.DisposeWhenGameObjDestroyed(); return(retNodeChain); }
public static IActionChain Repeat <T>(this T selfbehaviour, int count = -1) where T : MonoBehaviour { var retNodeChain = new RepeatNodeChain(count) { Executer = selfbehaviour }; retNodeChain.AddTo(selfbehaviour); return(retNodeChain); }
public static IActionChain Repeat <T>(this T selfbehaviour, int count = -1) where T : MonoBehaviour { var retNodeChain = new RepeatNodeChain(count) { Executer = selfbehaviour }; retNodeChain.DisposeWhenGameObjectDestroyed(selfbehaviour); return(retNodeChain); }