protected override void Update(GameTime gameTime) { CurrentGameTime = gameTime; InputKeyboard.UpdateState(); InputMouse.UpdateState(); if (InputKeyboard.KeyNowPressed(Keys.I)) { StatusText.DrawStatus = !StatusText.DrawStatus; } if (InputKeyboard.KeyNowPressed(Keys.H)) { StatusText.DrawControls = !StatusText.DrawControls; } StatusText.Update(); ManipulationMenu.Update(); if (Pause) { PausedActions(); } else { RunningActions(); } CamControl.Update(); }
public void OnFrame() { Dispatcher.ProcessFrame(); CamControl.Update(ActiveCamera, State != AppState.World); EditManager.Instance.UpdateChanges(); // do not move before mCamControl.Update to have the latest view/projection if (State == AppState.World) { UpdateCursorPosition(); UpdateBrushTime(TimeManager.Instance.GetTime()); CheckUpdateGlobalBuffer(); } GraphicsContext.Context.VertexShader.SetConstantBuffer(0, mGlobalBuffer.Native); GraphicsContext.Context.PixelShader.SetConstantBuffer(0, mGlobalBuffer.Native); MapManager.OnFrame(ActiveCamera); if (!HideWMO) { WmoManager.OnFrame(ActiveCamera); } if (!HideM2) { M2Manager.OnFrame(ActiveCamera); } WorldTextManager.OnFrame(ActiveCamera); BoundingBoxDrawManager.OnFrame(); }
public void OnFrame() { Dispatcher.ProcessFrame(); CamControl.Update(ActiveCamera, State != AppState.World); Editing.EditManager.Instance.UpdateChanges(); // do not move before mCamControl.Update to have the latest view/projection UpdateCursorPosition(); UpdateBrushTime(Utils.TimeManager.Instance.GetTime()); UpdateBuffers(); GraphicsContext.Context.VertexShader.SetConstantBuffer(0, mGlobalBuffer.Native); GraphicsContext.Context.PixelShader.SetConstantBuffer(0, mGlobalParamsBuffer.Native); MapManager.OnFrame(); WmoManager.OnFrame(); M2Manager.OnFrame(); }