PIE: viewport-embedded playback with UE-style main toolbar
Play no longer switches to fullscreen direct rendering: PIE now keeps the editor UI alive and renders the primary camera into the Viewport panel (new SceneRenderer::SetGameView flag; kDisplayDirect stays a manual fullscreen preview for later release form). Editor camera stops being driven during PIE, and viewport click-pick is gated off while playing (clicks are game input now). The Play/Stop buttons move out of the menu bar into a dedicated main toolbar row below it (centered, UE Main Toolbar semantics): green Play when idle; Pause (yellow, highlighted while paused) + Stop (orange) while playing. Ctrl+P hotkey kept. Stats "Pause Simulation" merged into the toolbar Pause; viewport overlay shows PAUSED accordingly.
This commit is contained in:
+4
-1
@@ -65,8 +65,11 @@ namespace
|
||||
{
|
||||
// 编辑器形态:驱动编辑器相机(RMB 飞行 / MMB 焦点环绕 /
|
||||
// 滚轮推拉)。暂停(timeScale=0)时仍可飞行——unscaled dt。
|
||||
// PIE 内嵌播放:渲染源已切 primary 相机,编辑器相机停驱
|
||||
//(否则与游戏脚本抢 WASD,Stop 后视角也被偷跑)。
|
||||
// 游戏形态:相机实体由游戏逻辑驱动(本沙盒无逻辑 = 静止)
|
||||
if (GetRenderer().GetDisplayMode() == kDisplayViewport)
|
||||
if (GetRenderer().GetDisplayMode() == kDisplayViewport &&
|
||||
!m_Editor->IsPlaying())
|
||||
{
|
||||
GetRenderer().GetEditorCamera().Update(GetWindow(),
|
||||
frameTime.UnscaledDt());
|
||||
|
||||
Reference in New Issue
Block a user