fix: not exiting shooting gallery when clicking activity close button

Fixes #436
Fixes crash when replaying as well
This commit is contained in:
Aaron Kimbre
2023-05-10 19:26:04 -05:00
parent bf0ae6f181
commit 5af5b0f1c1
8 changed files with 70 additions and 39 deletions

View File

@@ -1485,6 +1485,12 @@ void Entity::OnChoiceBoxResponse(Entity* sender, int32_t button, const std::u16s
}
}
void Entity::RequestActivityExit(Entity* sender, LWOOBJID player, bool canceled) {
for (CppScripts::Script* script : CppScripts::GetEntityScripts(this)) {
script->OnRequestActivityExit(sender, player, canceled);
}
}
void Entity::Smash(const LWOOBJID source, const eKillType killType, const std::u16string& deathType) {
if (!m_PlayerIsReadyForUpdates) return;