CreatureLib/src/Battling/Flow/TurnHandler.hpp

30 lines
1.1 KiB
C++

#ifndef CREATURELIB_TURNHANDLER_HPP
#define CREATURELIB_TURNHANDLER_HPP
#include "../Models/ExecutingAttack.hpp"
#include "../TurnChoices/AttackTurnChoice.hpp"
#include "../TurnChoices/FleeTurnChoice.hpp"
#include "../TurnChoices/ItemTurnChoice.hpp"
#include "../TurnChoices/SwitchTurnChoice.hpp"
#include "ChoiceQueue.hpp"
namespace CreatureLib::Battling {
class Battle;
class TurnHandler {
static void ExecuteChoice(const ArbUt::BorrowedPtr<BaseTurnChoice>& choice);
static void ExecuteAttackChoice(const ArbUt::BorrowedPtr<AttackTurnChoice>& choice);
static void HandleAttackForTarget(ExecutingAttack* attack, const ArbUt::BorrowedPtr<Creature>& target);
static void ExecuteSwitchChoice(const ArbUt::BorrowedPtr<SwitchTurnChoice>& choice);
static void ExecuteFleeChoice(const ArbUt::BorrowedPtr<FleeTurnChoice>& choice);
static void ExecuteItemChoice(const ArbUt::BorrowedPtr<ItemTurnChoice>& choice);
public:
static void RunTurn(const ArbUt::BorrowedPtr<ChoiceQueue>& queue, const ArbUt::BorrowedPtr<Battle>& battle);
};
}
#endif // CREATURELIB_TURNHANDLER_HPP