// EXECUTE METHOD: ------------------------------------------------------------------------ public override bool InstantExecute(GameObject target, IAction[] actions, int index) { ListVariables list = this.listVariables.GetListVariables(target); if (list == null || list.variables.Count == 0) { return(true); } for (int i = list.variables.Count - 1; i >= 0; --i) { switch (this.clear) { case ClearType.ClearAll: list.Remove(i); break; case ClearType.ClearEmpty: Variable variable = list.Get(i); if (variable == null || variable.Get().Equals(null)) { list.Remove(i); } break; } } return(true); }
// EXECUTE METHOD: ------------------------------------------------------------------------ public override bool InstantExecute(GameObject target, IAction[] actions, int index) { ListVariables list = this.listVariables.GetListVariables(target); if (list == null || list.variables.Count == 0) { return(true); } list.Remove(this.listVariables.select, this.listVariables.index); return(true); }
public static void ListRemove(ListVariables target, ListVariables.Position position) { target.Remove(position); }
public static void ListRemove(ListVariables target, int index) { target.Remove(index); }