public void ExecuteUpdate(BattleContext context) { // ステート遷移 if (isDecision) { if (context.isOffense) { context.ChangeState(context.stateActionSelect); } else { context.ChangeState(context.stateIdle); } } }
public void ExecuteExit(BattleContext context) { Debug.Log("[Exit] Battle State : Init"); }
public void ExecuteUpdate(BattleContext context) { }
// 他ステートへの遷移直前 の処理 public void ExecuteExit(BattleContext context) { Debug.Log("[Exit] Battle State : Action Select"); }
/// <summary> /// 攻守決定処理 /// </summary> void DecideOffense(BattleContext context) { isDecision = true; }
public void ExecuteExit(BattleContext context) { Debug.Log("[Entry] Battle State : Offensive Decision"); }
public void ExecuteEntry(BattleContext context) { Debug.Log("[Entry] Battle State : Offensive Decision"); isDecision = false; }
public void ExecuteEntry(BattleContext context) { Debug.Log("[Entry] Battle State : Idle"); }