MCPcopy Create free account
hub / github.com/JACoders/OpenJK / WaitSignal

Method WaitSignal

code/icarus/TaskManager.cpp:1162–1185  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1160*/
1161
1162int CTaskManager::WaitSignal( CTask *task, bool &completed , CIcarus* icarus )
1163{
1164 CBlock *block = task->GetBlock();
1165 char *sVal;
1166 int memberNum = 0;
1167
1168 completed = false;
1169
1170 ICARUS_VALIDATE( Get( m_ownerID, block, memberNum, &sVal , icarus) );
1171
1172 if ( task->GetTimeStamp() == icarus->GetGame()->GetTime() )
1173 {
1174 //Print out the debug info
1175 icarus->GetGame()->DebugPrint(IGameInterface::WL_DEBUG, "%4d waitsignal(\"%s\"); [%d]", m_ownerID, sVal, task->GetTimeStamp() );
1176 }
1177
1178 if ( icarus->CheckSignal( sVal ) )
1179 {
1180 completed = true;
1181 icarus->ClearSignal( sVal );
1182 }
1183
1184 return TASK_OK;
1185}
1186
1187/*
1188-------------------------

Callers

nothing calls this directly

Calls 7

DebugPrintMethod · 0.80
GetBlockMethod · 0.45
GetTimeStampMethod · 0.45
GetTimeMethod · 0.45
GetGameMethod · 0.45
CheckSignalMethod · 0.45
ClearSignalMethod · 0.45

Tested by

no test coverage detected