public void Run() { UInt32 SDLStart = SDL2.SDL.SDL_GetTicks(); UInt32 LastValue = SDL2.SDL.SDL_GetTicks(); GameTimeUpdateComponent Value = SingletonComponent <GameTimeUpdateComponent> .Get(); while (!QuitLoop) { SDLStart = SDL2.SDL.SDL_GetTicks(); Value.UpdateTime((SDLStart - LastValue) / 1000f); SDL2.SDL.SDL_PumpEvents(); myWorldManager.Update(); LastValue = SDL2.SDL.SDL_GetTicks(); } }
public OneToManySystem(World myBase, int SystemLevel = 1) : base(SystemLevel) { myReferenceSingleton = SingletonComponent <T> .Get(); myIterator = new EntityIteratorDefault <U>(myBase); }