mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-05-10 20:46:47 +03:00
Don't call nonexistent volume functions
This commit is contained in:
parent
673db7a866
commit
6d91e7ddba
1 changed files with 6 additions and 3 deletions
|
@ -943,12 +943,14 @@ void TestTriggers(short *data, int heavy, int HeavyFlags)
|
|||
if (volume->status == TriggerStatus::TS_OUTSIDE)
|
||||
{
|
||||
volume->status = TriggerStatus::TS_ENTERING;
|
||||
g_GameScript->ExecuteFunction(volume->onEnter);
|
||||
if (!volume->onEnter.empty())
|
||||
g_GameScript->ExecuteFunction(volume->onEnter);
|
||||
}
|
||||
else
|
||||
{
|
||||
volume->status = TriggerStatus::TS_INSIDE;
|
||||
g_GameScript->ExecuteFunction(volume->onInside);
|
||||
if (!volume->onInside.empty())
|
||||
g_GameScript->ExecuteFunction(volume->onInside);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -958,7 +960,8 @@ void TestTriggers(short *data, int heavy, int HeavyFlags)
|
|||
if (volume->status == TriggerStatus::TS_INSIDE)
|
||||
{
|
||||
volume->status = TriggerStatus::TS_LEAVING;
|
||||
g_GameScript->ExecuteFunction(volume->onLeave);
|
||||
if (!volume->onLeave.empty())
|
||||
g_GameScript->ExecuteFunction(volume->onLeave);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue