Adds new run prevention script hooks.
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:
@@ -273,3 +273,15 @@ void AngelScriptScript::OnFail(CreatureLib::Battling::Creature* target) {
|
||||
void AngelScriptScript::OnOpponentFail(CreatureLib::Battling::Creature* target) {
|
||||
CALL_HOOK(OnOpponentFail, { ctx->SetArgObject(0, (void*)target); })
|
||||
}
|
||||
void AngelScriptScript::PreventRunAway(const CreatureLib::Battling::FleeTurnChoice* choice, bool* result) {
|
||||
CALL_HOOK(PreventRunAway, {
|
||||
ctx->SetArgObject(0, (void*)choice);
|
||||
ctx->SetArgAddress(1, result);
|
||||
})
|
||||
}
|
||||
void AngelScriptScript::PreventOpponentRunAway(const CreatureLib::Battling::FleeTurnChoice* choice, bool* result) {
|
||||
CALL_HOOK(PreventOpponentRunAway, {
|
||||
ctx->SetArgObject(0, (void*)choice);
|
||||
ctx->SetArgAddress(1, result);
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user