void IModule <TState> .OnConstruct() { this.states = new CircularQueue <TState>(this.GetTicksPerState(), this.GetQueueCapacity()); this.events = PoolDictionary <ulong, SortedList <long, HistoryEvent> > .Spawn(1000); PoolSortedList <int, HistoryEvent> .Prewarm(1000, 2); this.world.SetStatesHistoryModule(this); }
void IModuleBase.OnConstruct() { this.statesHistory = new ME.ECS.Network.StatesHistory <TState>(this.world, this.GetQueueCapacity()); //this.states = new StatesCircularQueue<TState>(this.GetTicksPerState(), this.GetQueueCapacity()); this.events = PoolDictionary <Tick, ME.ECS.Collections.SortedList <long, HistoryEvent> > .Spawn(StatesHistoryModule <TState> .POOL_EVENTS_CAPACITY); this.syncHash = PoolDictionary <Tick, int> .Spawn(StatesHistoryModule <TState> .POOL_SYNCHASH_CAPACITY); PoolSortedList <int, HistoryEvent> .Prewarm(StatesHistoryModule <TState> .POOL_HISTORY_SIZE, StatesHistoryModule <TState> .POOL_HISTORY_CAPACITY); this.world.SetStatesHistoryModule(this); }