void NextState(BehaviourTreeInstance.NodeState _state, BehaviourTreeInstance _instance) { if (_state == BehaviourTreeInstance.NodeState.SUCCESS) { _instance.nodeStateDic[key] = BehaviourTreeInstance.NodeState.SUCCESS; } else if (_state == BehaviourTreeInstance.NodeState.FAILURE) { _instance.nodeStateDic[key] = BehaviourTreeInstance.NodeState.FAILURE; } }
void NextState(BehaviourTreeInstance.NodeState state, BehaviourTreeInstance behaviourTreeInstance) { if (state == BehaviourTreeInstance.NodeState.SUCCESS) { behaviourTreeInstance.nodeStateDict[this.key] = BehaviourTreeInstance.NodeState.SUCCESS; } else if (state == BehaviourTreeInstance.NodeState.FAILURE) { behaviourTreeInstance.nodeStateDict[this.key] = BehaviourTreeInstance.NodeState.FAILURE; } }
void NextState(BehaviourTreeInstance.NodeState _state, BehaviourTreeInstance _instance) { if (_state == BehaviourTreeInstance.NodeState.FAILURE) { _instance.nodeStateDic[key] = BehaviourTreeInstance.NodeState.FAILURE; } else if (_state == BehaviourTreeInstance.NodeState.SUCCESS) { if (actions.MoveNext()) { actions.Current.Execute(_instance); } else { _instance.nodeStateDic[key] = BehaviourTreeInstance.NodeState.SUCCESS; } } }
void NextState(BehaviourTreeInstance.NodeState state, BehaviourTreeInstance behaviourTreeInstance) { if (state == BehaviourTreeInstance.NodeState.FAILURE) { behaviourTreeInstance.nodeStateDict[this.key] = BehaviourTreeInstance.NodeState.FAILURE; } else if (state == BehaviourTreeInstance.NodeState.SUCCESS) { if (this.actions.MoveNext()) { this.actions.Current.Execute(behaviourTreeInstance); } else { behaviourTreeInstance.nodeStateDict[this.key] = BehaviourTreeInstance.NodeState.SUCCESS; } } }