// ============================================================================================================ // Ctor, Initialization, Dispose, Update // ============================================================================================================ public WorldModel() { Service.Add <WorldModel>(this); m_Engine = Service.Get <UltimaGame>(); m_Network = Service.Get <INetworkClient>(); m_UserInterface = Service.Get <UserInterfaceService>(); Entities = new EntityManager(this); Entities.Reset(true); Effects = new EffectManager(this); Statics = new StaticManager(); Input = new WorldInput(this); Interaction = new WorldInteraction(this); Client = new WorldClient(this); }
public override void Update(double totalMS, double frameMS) { if (!m_Network.IsConnected) { if (m_UserInterface.IsModalControlOpen == false) { MsgBox g = m_UserInterface.MsgBox("You have lost your connection with the server.", MsgBoxTypes.OkOnly); g.OnClose = onCloseLostConnectionMsgBox; } } else { Input.Update(frameMS); EntityManager.Update(frameMS); Effects.Update(frameMS); StaticManager.Update(frameMS); } }