//State Initialization => //Add Loading screen animation, and ServerComponent public override void Initialize(SharpDX.Direct3D11.DeviceContext context) { if (PreviousGameState != this) { GameComponents.Clear(); } var loading = _ioc.Get <LoadingComponent>(); _vars = _ioc.Get <RealmRuntimeVariables>(); AddComponent(loading); //Will "Mask" the Components being loaded. AddComponent(_ioc.Get <ServerComponent>()); AddComponent(_ioc.Get <GuiManager>()); base.Initialize(context); }
protected override void Dispose(bool disposing) { GameComponents.Clear(); base.Dispose(disposing); }
public void ResetGame() { SyncedGameCollection.ComponentCollection.Clear(); world.Clear(); GameComponents.Clear(); }