示例#1
0
 public override void Update(double delta)
 {
     session.Update();
     ProcessCutscenes();
     if (scene != null)
     {
         scene.UpdateViewport(Game.RenderContext.CurrentViewport);
         if (paused)
         {
             scene.Update(0);
         }
         else
         {
             scene.Update(firstFrame ? 0 : delta);
         }
     }
     firstFrame = false;
     if (!firstFrame)
     {
         if (session.Popups.Count > 0 && session.Popups.TryDequeue(out var popup))
         {
             FLLog.Debug("Room", "Displaying popup");
             ui.Event("Popup", popup.Title, popup.Contents, popup.ID);
         }
     }
     ui.Update(Game);
     if (ui.KeyboardGrabbed)
     {
         Game.EnableTextInput();
     }
     else
     {
         Game.DisableTextInput();
     }
 }
示例#2
0
 public override void Update(double delta)
 {
     ui.Update(Game);
     Game.TextInputEnabled = ui.KeyboardGrabbed;
     scene.UpdateViewport(Game.RenderContext.CurrentViewport);
     scene.Update(delta);
     api._Update();
 }