DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ Register()

void BunkerBroadcastHandler::Register ( BunkerBroadcastComponentBase component)
inlineprivate

already active (custom persistence storage)

См. определение в файле BunkerBroadcastHandler.c строка 192

193 {
194 if (!m_ConfigLoaded)
195 return;
196
198 int componentId = component.GetId();
199 string lockCode;
200 if (m_PersitenceStorage.m_HandlerData.m_LastActiveBunkers.Find(componentId, lockCode))
201 {
202 // necessary to postpone while loaded and activated from storage
203 Param2<string, bool> params = new Param2<string, bool>(lockCode, true);
204 g_Game.GetCallQueue(CALL_CATEGORY_GAMEPLAY).CallLaterByName(component, "OnActivate", 1000, false, params);
205
206 m_RegisteredBunkers.Set(componentId, component);
208
209 #ifdef ENABLE_LOGGING
210 Log(string.Format("Directly registering (store load) - object=%1, id=%2, pos=%3, code=%4", component, componentId, component.GetPosition(), lockCode));
211 #endif
212
214
215 return;
216 }
217
218 if (m_RegisterQueue.Contains(componentId))
219 {
220 #ifdef ENABLE_LOGGING
221 Log(string.Format("Already in register queue - object=%1, id=%2, pos=%3", component, componentId, component.GetPosition()));
222 #endif
223 return;
224 }
225
226 m_RegisterQueue.Set(componentId, component);
227
228 m_CanUpdate = true;
229 }
DayZGame g_Game
Определения DayZGame.c:4074
class BoxCollidingParams component
ComponentInfo for BoxCollidingResult.
class LogTemplates Log(string message, LogTemplateID template_id=0)
Creates debug log (optional) from LogTemplate which are registred.
Определения LogTemplates.c:75
ref map< int, ref BunkerBroadcastComponentBase > m_RegisterQueue
Определения BunkerBroadcastHandler.c:102
ref map< int, ref BunkerBroadcastComponentBase > m_RegisteredBunkers
how often is update called [seconds]
Определения BunkerBroadcastHandler.c:100
ref BunkerComponentsArray m_ActiveBunkers
Определения BunkerBroadcastHandler.c:101
int m_ActiveBunkersFromStorageCount
Определения BunkerBroadcastHandler.c:124
BunkerBroadcastPersistenceStorage m_PersitenceStorage
Определения BunkerBroadcastHandler.c:112
const int CALL_CATEGORY_GAMEPLAY
Определения 3_Game/DayZ/tools/tools.c:10

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, component, g_Game, Log(), m_ActiveBunkers, m_ActiveBunkersFromStorageCount, m_CanUpdate, m_ConfigLoaded, m_PersitenceStorage, m_RegisteredBunkers и m_RegisterQueue.