// // SceneDelegate.swift // ylgamehall // import UIKit final class SceneDelegate: UIResponder, UIWindowSceneDelegate { var window: UIWindow? func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { guard let windowScene = scene as? UIWindowScene else { return } let window = UIWindow(windowScene: windowScene) // 用 UINavigationController 承载大厅,便于 Phase 6 push 子游戏 / Phase 7 push 弹层。 // 栈深约束 ≤ 3(Design §2.4.3),由 AppCoordinator 在 push 处守门。 let lobby = WebContainerViewController() let nav = UINavigationController(rootViewController: lobby) nav.setNavigationBarHidden(true, animated: false) nav.interactivePopGestureRecognizer?.isEnabled = false AppCoordinator.shared.navigationController = nav window.rootViewController = nav self.window = window window.makeKeyAndVisible() } }