diff options
author | Fire-Head <Fire-Head@users.noreply.github.com> | 2020-10-14 23:33:57 +0200 |
---|---|---|
committer | Fire-Head <Fire-Head@users.noreply.github.com> | 2020-10-14 23:33:57 +0200 |
commit | e4ac934dbf57392c2b231f32d4f101bb9a183a51 (patch) | |
tree | 615f44c68ff0c174135eefc1b2279d46de45f864 /src/control/Script.cpp | |
parent | Merge pull request #753 from majesticCoding/miami (diff) | |
download | re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar.gz re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar.bz2 re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar.lz re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar.xz re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.tar.zst re3-e4ac934dbf57392c2b231f32d4f101bb9a183a51.zip |
Diffstat (limited to 'src/control/Script.cpp')
-rw-r--r-- | src/control/Script.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/control/Script.cpp b/src/control/Script.cpp index aa4e109f..55139f2e 100644 --- a/src/control/Script.cpp +++ b/src/control/Script.cpp @@ -31,6 +31,7 @@ #include "GameLogic.h" #include "Garages.h" #include "General.h" +#include "Glass.h" #ifdef MISSION_REPLAY #include "GenericGameStorage.h" #endif @@ -13002,12 +13003,12 @@ int8 CRunningScript::ProcessCommands1300To1399(int32 command) case COMMAND_HAS_GLASS_BEEN_SHATTERED_NEARBY: { CollectParameters(&m_nIp, 3); - static bool bShowed = false; - if (!bShowed) { - debug("HAS_GLASS_BEEN_SHATTERED_NEARBY not implemented, default to TRUE\n"); // TODO(MIAMI) - bShowed = true; - } - UpdateCompareFlag(true); + + bool shattered = false; + if ( CGlass::HasGlassBeenShatteredAtCoors(*(float*)&ScriptParams[0], *(float*)&ScriptParams[1], *(float*)&ScriptParams[2]) ) + shattered = true; + + UpdateCompareFlag(shattered); return 0; } case COMMAND_ATTACH_CUTSCENE_OBJECT_TO_BONE: |