Check if the user is usable when we set the choice
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
f13b78e297
commit
dcf6b20e65
@ -10,6 +10,9 @@ using namespace CreatureLib::Battling;
|
||||
const ArbUt::BorrowedPtr<const BattleLibrary>& Battle::GetLibrary() const noexcept { return _library; }
|
||||
|
||||
bool Battle::CanUse(const ArbUt::BorrowedPtr<BaseTurnChoice>& choice) {
|
||||
if (!choice->GetUser()->IsUsable()) {
|
||||
return false;
|
||||
}
|
||||
if (choice->GetKind() == TurnChoiceKind::Attack) {
|
||||
auto attack = choice.ForceAs<AttackTurnChoice>();
|
||||
// HOOK: change number of uses needed.
|
||||
|
Loading…
x
Reference in New Issue
Block a user