DIFF

class BunkerBroadcastHandler

BunkerBroadcastHandler › Managed

Constructors 2

void ~BunkerBroadcastHandler()

history of lock codes selected history of previously active bunkers

Constants 3

protected const int LOCK_CODE_HISTORY_LENGTH = 5

how many of previously generated codes are stored (prevents the reuse)

protected const int UPDATE_BATCH_SIZE = 10

max batch size

Referenced by ProcessBatch()
protected const float UPDATE_TIME = 10.0

how often is update called [seconds]

Referenced by Update()

Members 22

protected ref BunkerComponentsArray m_ActiveBunkers
protected ref map<int, ref BunkerBroadcastComponentBase> m_RegisterQueue
protected ref map<int, ref BunkerBroadcastComponentBase> m_UnregisterQueue
protected bool m_ConfigLoaded
Referenced by BunkerBroadcastHandler(), Register(), Unregister()
Show 1 more, Update()
protected bool m_CanUpdate
Referenced by CheckUpdating(), Register(), and Update()
protected bool m_ProcessComponents
Referenced by Reset(), and Update()
protected bool m_ProcessingFinished
protected int m_NextToProcessIdx
protected float m_UpdateTimer
Referenced by BunkerBroadcastHandler(), ProcessBatch(), Reset()
Show 1 more, Update()
protected BunkerBroadcastPersistenceStorage m_PersitenceStorage
protected BunkerBroadcastScheduler m_BroadcastScheduler
protected ref SimpleCircularBuffer<string> m_LockCodeHistory
protected ref SimpleCircularBuffer<int> m_ActiveBunkersHistory
protected ref ScriptInvoker m_OnActiveBunkersSelected
private static ref BunkerBroadcastHandler m_Instance
Referenced by GetInstance(), and Log()
private int m_LastActiveBunkersCount
private int m_ActiveBunkersFromStorageCount
static ref BunkerComponentsArray m_RegisteredBunkersStorageDIAG_DEVELOPER
static ref TIntArray m_BunkersHistoryStorageDIAG_DEVELOPER
static bool m_LoggingEnabledDIAG_DEVELOPER

Methods 21

void Unregister(BunkerBroadcastComponentBase component)

already active (custom persistence storage)

protected void SelectNew()

not active bunkers and storage has processed without results

protected bool ProcessBatch()

returns 'true' when all the batches are finished

Referenced by Update()
protected void Reset()
Referenced by Update()
protected void HandleChangedComponents()
Referenced by Update()
private void SyncBunkersInfo(BunkerComponentsArray bunkers, TIntArray bunkersHistory)DIAG_DEVELOPER
Referenced by Update()
protected void CheckUpdating()
Referenced by Update()