From 83bf1d0d4d837bb882672f616e2e267c5dff3606 Mon Sep 17 00:00:00 2001 From: Untold Engine Date: Tue, 6 Oct 2026 23:20:26 -0700 Subject: [PATCH] [Patch] Skip intro gallery and disable Explore asset panel, drop AWS URLs The editor no longer serves demo/asset-pack content from AWS, so launch straight into the full editor instead of the Explore gallery, hide the Explore tab in the Asset Browser, and remove the CloudFront URLs from the demo and asset-pack catalogs. Updated tests to match the now-empty catalogs. --- .../Editor/AssetPacks/AssetPackCatalog.swift | 18 ++--------- .../UntoldEditor/Editor/Docking/PanelID.swift | 1 + .../Editor/Explore/StarterStreamModels.swift | 30 ++----------------- .../Editor/Window/EditorView.swift | 6 ++-- .../AssetBrowserViewTests.swift | 7 ++--- .../DemoGalleryViewTests.swift | 16 ++++++++-- 6 files changed, 25 insertions(+), 53 deletions(-) diff --git a/Sources/UntoldEditor/Editor/AssetPacks/AssetPackCatalog.swift b/Sources/UntoldEditor/Editor/AssetPacks/AssetPackCatalog.swift index e4fe882..bc23639 100644 --- a/Sources/UntoldEditor/Editor/AssetPacks/AssetPackCatalog.swift +++ b/Sources/UntoldEditor/Editor/AssetPacks/AssetPackCatalog.swift @@ -110,21 +110,9 @@ struct AssetPackInstallResult: Equatable { } func defaultAssetPackCatalog() -> AssetPackCatalog { - AssetPackCatalog( - version: "1.0.0", - assets: [ - AssetPackCatalogItem( - id: "starter", - name: "StarterPack", - description: "Soccer field, goals, ball, and a sample scene.", - version: "1.0.0", - downloadURL: "https://d8pyi1c08k1w.cloudfront.net/StarterPack.zip", - size: "5.3 MB", - thumbnailName: "starterpack", - replacePaths: ["Models/starterpack"] - ), - ] - ) + // No asset packs are hosted; the Explore panel (hidden via PanelID.available) + // has nothing to list. + AssetPackCatalog(version: "1.0.0", assets: []) } func configuredAssetPackCatalogURL( diff --git a/Sources/UntoldEditor/Editor/Docking/PanelID.swift b/Sources/UntoldEditor/Editor/Docking/PanelID.swift index bf947ee..53f4c5b 100644 --- a/Sources/UntoldEditor/Editor/Docking/PanelID.swift +++ b/Sources/UntoldEditor/Editor/Docking/PanelID.swift @@ -88,5 +88,6 @@ enum PanelID: String, Codable, CaseIterable, Identifiable { /// The panels this build of the editor offers. static var available: [PanelID] { allCases.filter { $0 != .plugins || EditorFeatureFlags.enableCodeComponents } + .filter { $0 != .explore } } } diff --git a/Sources/UntoldEditor/Editor/Explore/StarterStreamModels.swift b/Sources/UntoldEditor/Editor/Explore/StarterStreamModels.swift index 3560e41..06b64c9 100644 --- a/Sources/UntoldEditor/Editor/Explore/StarterStreamModels.swift +++ b/Sources/UntoldEditor/Editor/Explore/StarterStreamModels.swift @@ -23,33 +23,9 @@ struct StreamModelCameraFrame { let usesOriginOrbit: Bool } -let starterStreamModels: [StreamModelCatalogItem] = [ - .init( - id: "dungeon", - title: "Game Dungeon", - manifestURL: URL(string: "https://d8pyi1c08k1w.cloudfront.net/Dungeon/dungeon.json")! - ), - .init( - id: "city", - title: "Cartoon City", - manifestURL: URL(string: "https://d8pyi1c08k1w.cloudfront.net/city/city.json")! - ), - .init( - id: "f1car", - title: "Formula 1", - manifestURL: URL(string: "https://d8pyi1c08k1w.cloudfront.net/F1Car/F1Car.json")! - ), - .init( - id: "airplane", - title: "Skyhawk", - manifestURL: URL(string: "https://d8pyi1c08k1w.cloudfront.net/Shyhawk_stream/Skyhawks.json")! - ), - .init( - id: "porsche964", - title: "Porsche 964", - manifestURL: URL(string: "https://d8pyi1c08k1w.cloudfront.net/Porsche964-stream/Porsche964-stream.json")! - ), -] +/// No streamed demo scenes are hosted; the Explore gallery (unreachable since +/// the editor now launches straight into the full editor) has nothing to list. +let starterStreamModels: [StreamModelCatalogItem] = [] extension StreamModelCatalogItem { var cameraFrame: StreamModelCameraFrame { diff --git a/Sources/UntoldEditor/Editor/Window/EditorView.swift b/Sources/UntoldEditor/Editor/Window/EditorView.swift index 462f9e4..2b40416 100644 --- a/Sources/UntoldEditor/Editor/Window/EditorView.swift +++ b/Sources/UntoldEditor/Editor/Window/EditorView.swift @@ -60,7 +60,7 @@ public struct EditorView: View { @State var panelSearchText: [PanelID: String] = [:] @State var renderPauseGeneration = 0 let panelAnimationDuration = 0.28 - @State var showWelcomeStart = true + @State var showWelcomeStart = false @State var showCameraControlHints = false @State var showQuickPreviewWarning = false @State var quickPreviewEntities: [(EntityID, String)] = [] @@ -72,8 +72,8 @@ public struct EditorView: View { @State var quickPreviewCompressGeometry = false @State var quickPreviewCompressTextures = false @State var quickPreviewAstcencBinPath = "" - @State var experienceMode: EditorExperienceMode = .explore - @State var showDemoGallery = true + @State var experienceMode: EditorExperienceMode = .edit + @State var showDemoGallery = false @State var showPreviewImportGallery = false @State var activeDemoScene: DemoSceneCatalogItem? @State var activeDemoCameraFrame: StreamModelCameraFrame? diff --git a/Tests/UntoldEditorTests/AssetBrowserViewTests.swift b/Tests/UntoldEditorTests/AssetBrowserViewTests.swift index 37ba4eb..a2b4cbe 100644 --- a/Tests/UntoldEditorTests/AssetBrowserViewTests.swift +++ b/Tests/UntoldEditorTests/AssetBrowserViewTests.swift @@ -967,12 +967,9 @@ final class AssetBrowserViewTests: XCTestCase { XCTAssertTrue(item.replacePaths.isEmpty) } - func test_defaultAssetPackCatalog_onlyShowsStarterPackWithThumbnail() { + func test_defaultAssetPackCatalog_isEmpty() { let catalog = defaultAssetPackCatalog() - XCTAssertEqual(catalog.assets.map(\.id), ["starter"]) - XCTAssertEqual(catalog.assets.first?.name, "StarterPack") - XCTAssertEqual(catalog.assets.first?.thumbnailName, "starterpack") - XCTAssertEqual(catalog.assets.first?.replacePaths, ["Models/starterpack"]) + XCTAssertTrue(catalog.assets.isEmpty) } func test_assetPackCategoryNames_sortsUniqueCategories() { diff --git a/Tests/UntoldEditorTests/DemoGalleryViewTests.swift b/Tests/UntoldEditorTests/DemoGalleryViewTests.swift index eebf89d..4bcece9 100644 --- a/Tests/UntoldEditorTests/DemoGalleryViewTests.swift +++ b/Tests/UntoldEditorTests/DemoGalleryViewTests.swift @@ -36,8 +36,18 @@ import XCTest } } - func test_demoGalleryView_wiresCallbacks() { - let firstDemo = demoSceneCatalog[0] + func test_demoGalleryView_wiresCallbacks() throws { + let firstDemo = try DemoSceneCatalogItem( + id: "sample", + title: "Sample", + subtitle: "A sample demo scene.", + thumbnailName: "sample", + systemImageName: "cube", + tags: ["Demo"], + source: .remoteManifest(XCTUnwrap(URL(string: "https://example.com/sample.json"))), + cameraFrame: nil, + loadsSceneAuthoredPayload: false + ) var selectedDemoId: String? var didTryOwnScene = false var didCreateProject = false @@ -45,7 +55,7 @@ import XCTest var didOpenFullEditor = false let sut = DemoGalleryView( - demos: demoSceneCatalog, + demos: [firstDemo], onDemoSelected: { selectedDemoId = $0.id }, onTryOwnScene: { didTryOwnScene = true }, onCreateProject: { didCreateProject = true },