/// <summary>
        /// Officially starts the BattleEntity's turn.
        /// </summary>
        public void StartTurn()
        {
            OnTurnStart();

            //Invoke the event
            TurnStartEvent?.Invoke();
        }
示例#2
0
        //Battle-turn related methods
        public void StartTurn()
        {
            //Default to one action. If a StatusEffect changes this, it'll happen in the TurnStartEvent
            NumActions = 1;

            TurnStartEvent?.Invoke();
            HandleTurnStart();

            /*NOTE: We check if NumActions is 0 here then end the turn if so. If NumActions is already 0, don't allow it
            *  to be set to any other value in ModifyNumActions().
            *  This fixes problems with Sleep, Fast, and other turn-modifying StatusEffects on an Entity at the same time*/
            if (NumActions == 0)
            {
                EndTurn();
            }
        }
 public void EndTurn()
 {
     TurnEndEvent?.Invoke();
     TurnStartEvent?.Invoke();
 }
示例#4
0
 /// <summary>
 /// 回合开始
 /// </summary>
 public void TurnStart()
 {
     TurnStartEvent?.Invoke();
 }