mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-05-02 15:47:58 +03:00
Call Director.Unpause() to execute running scripts
This commit is contained in:
parent
ec3259271e
commit
77a9cd5a9a
5 changed files with 9 additions and 27 deletions
|
@ -4512,12 +4512,8 @@ void Actor::UpdateAnim
|
|||
Com_Printf("ChangeAnim\n");
|
||||
ChangeAnim();
|
||||
}
|
||||
Director.iPaused--;
|
||||
if (!Director.iPaused)
|
||||
{
|
||||
Director.ExecuteRunning();
|
||||
}
|
||||
Director.iPaused++;
|
||||
Director.Unpause();
|
||||
Director.Pause();
|
||||
|
||||
if (m_csSayAnim != STRING_EMPTY)
|
||||
{
|
||||
|
@ -5534,9 +5530,7 @@ void Actor::Think
|
|||
|
||||
m_bNeedReload = false;
|
||||
mbBreakSpecialAttack = false;
|
||||
Director.iPaused--;
|
||||
if (!Director.iPaused)
|
||||
Director.ExecuteRunning();
|
||||
Director.Unpause();
|
||||
|
||||
//gi.DPrintf("Actor::Think 5: entnum %d, classname: %s\n", entnum, G_GetEntity(0) ? G_GetEntity(0)->getClassname() : "");
|
||||
}
|
||||
|
@ -8234,13 +8228,9 @@ void Actor::IdleTurn
|
|||
|
||||
SafePtr<SimpleEntity> prevTurnEntity = m_pTurnEntity;
|
||||
|
||||
Director.iPaused--;
|
||||
if (!Director.iPaused)
|
||||
{
|
||||
Director.ExecuteRunning();
|
||||
}
|
||||
Director.Unpause();
|
||||
Unregister(STRING_TURNDONE);
|
||||
Director.iPaused++;
|
||||
Director.Pause();
|
||||
|
||||
|
||||
if (m_pTurnEntity == prevTurnEntity)
|
||||
|
|
|
@ -545,14 +545,8 @@ void G_RunFrame( int levelTime, int frameTime )
|
|||
}
|
||||
}
|
||||
|
||||
Director.iPaused--;
|
||||
g_iInThinks++;
|
||||
|
||||
if( !Director.iPaused )
|
||||
{
|
||||
Director.ExecuteRunning();
|
||||
}
|
||||
|
||||
Director.Unpause();
|
||||
g_iInThinks--;
|
||||
|
||||
// Process any pending events that got posted during the script code
|
||||
|
|
|
@ -1218,9 +1218,7 @@ void Level::ServerSpawned(void)
|
|||
ent->entity->Unregister(STRING_SPAWN);
|
||||
}
|
||||
|
||||
if (Director.iPaused-- == 1) {
|
||||
Director.ExecuteRunning();
|
||||
}
|
||||
Director.Unpause();
|
||||
|
||||
Unregister(STRING_SPAWN);
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
===========================================================================
|
||||
Copyright (C) 2015 the OpenMoHAA team
|
||||
Copyright (C) 2023 the OpenMoHAA team
|
||||
|
||||
This file is part of OpenMoHAA source code.
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
===========================================================================
|
||||
Copyright (C) 2015 the OpenMoHAA team
|
||||
Copyright (C) 2023 the OpenMoHAA team
|
||||
|
||||
This file is part of OpenMoHAA source code.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue