* Fix crash in CTaskMngr::startFrame() * Fix crash in EventsMngr::executeEvents() * Fix loops * Fix loop iterators signess
This commit is contained in:
parent
7794f27dc2
commit
df4e4949c8
|
@ -458,8 +458,11 @@ void EventsMngr::executeEvents()
|
|||
auto parseFun = m_ParseFun;
|
||||
m_ParseFun = nullptr;
|
||||
|
||||
for (auto &event : *parseFun)
|
||||
auto lastSize = parseFun->length();
|
||||
for(auto i = 0u; i < lastSize; i++)
|
||||
{
|
||||
auto &event = parseFun->at(i);
|
||||
|
||||
if (event->m_Done)
|
||||
{
|
||||
event->m_Done = false;
|
||||
|
|
|
@ -269,8 +269,11 @@ bool CTaskMngr::taskExists(int iId, AMX *pAmx)
|
|||
|
||||
void CTaskMngr::startFrame()
|
||||
{
|
||||
for (auto &task : m_Tasks)
|
||||
auto lastSize = m_Tasks.length();
|
||||
for(auto i = 0u; i < lastSize; i++)
|
||||
{
|
||||
auto &task = m_Tasks[i];
|
||||
|
||||
if (task->isFree())
|
||||
continue;
|
||||
task->executeIfRequired(*m_pTmr_CurrentTime, *m_pTmr_TimeLimit, *m_pTmr_TimeLeft);
|
||||
|
|
Loading…
Reference in New Issue
Block a user