Skip to content

Loom (Alpha) #1 of 4: skeleton + theme + Project Manager launcher#292

Merged
CoreyRDean merged 1 commit into
developfrom
coreyrdean/loom-skeleton
May 27, 2026
Merged

Loom (Alpha) #1 of 4: skeleton + theme + Project Manager launcher#292
CoreyRDean merged 1 commit into
developfrom
coreyrdean/loom-skeleton

Conversation

@CoreyRDean
Copy link
Copy Markdown
Collaborator

Summary

First of a multi-PR rebuild of the Loom GUE redesign as a parallel alpha editor (bin/Loom.exe), launched from Project Manager next to the existing Game Unified Editor button.

The previous round retrofitted Loom concepts on top of GUE's F-UI surface (PRs #271 / #273 / #274 / #275, all now closed). F-UI's quirks (window M_HIDE no-ops, listbox/combobox M_GETSELECTED handle inversion, Tab M_SETINDEX nested-iterator pathology, an unyielding visual language) made that path a losing game. This rebuild runs as its own .bb / .exe so the UI shell can be designed from scratch without fighting F-UI on a surface it wasn't designed for.

This PR is architectural proof only. The atlas, world view, and composer arrive in the next three PRs.

What's in

File What
src/Loom.bb Entry point. Boots Blitz3D, opens a window, runs a splash loop until Esc. Mirrors GUE.bb's bootstrap so paths and log placement match (writes Data/Logs/Loom Log.txt next to GUE's log).
src/Modules/Loom/Theme.bb Color tokens from the Loom design palette (stone / arcane / brass / parchment) plus 2D drawing helpers (LoomFill, LoomGradientV, LoomHRule, LoomText...) wrapping Blitz3D primitives. Subsequent surfaces paint through this layer instead of F-UI so they can express the gradient-heavy aesthetic.
src/Project Manager.bb New Loom (Alpha) button in the Editors group, next to Game Unified Editor. Auto-disables when bin/Loom.exe is missing. Launches with the same CWD as the GUE button so projects load identically.
compile.bat / compile.sh New build target for bin/Loom.exe.

What's deliberately NOT in (deferred)

  • Data loading. The skeleton does not Include Items.bb / Actors.bb / Spells.bb yet; PR Modernize and reorganize the project #2 wires those up so Loom reads the same in-memory representation GUE does.
  • F-UI integration. None of F-UI is pulled in here. PR #3 includes it only for the text-input + file-dialog surfaces where F-UI earns its keep; everything visual stays in the Loom theme layer.
  • Atlas / world view / composer. PRs Modernize and reorganize the project #2, #3, Replace FastLibs #4 respectively.

Roadmap

PR Slice Description
#1 (this) Skeleton Loom.exe builds, PM button launches it, themed splash, exits cleanly.
#2 Atlas Load existing project's data via GUE's data modules; show a zone picker.
#3 World view Picking a zone in the atlas renders it in a 3D viewport. Click an entity to select.
#4 Composer Right-side property panel painting the focused entity's data using Loom theme primitives. Read-only for alpha.

Blast radius

  • New files only, except for the additive button + path constant in Project Manager.bb and the additive build line in compile.bat / compile.sh.
  • Existing GUE.exe / Server.exe / Client.exe are untouched.
  • All five engine targets compile clean.

Test plan

  • Run compile.bat -- builds bin/Loom.exe alongside the others, no errors
  • Open Project Manager -- Editors group is taller, contains both Game Unified Editor and Loom (Alpha) buttons; the Loom button is enabled
  • Click Loom (Alpha) -- new window opens, dark background, LOOM title centered with brass divider underneath, project name shown, skeleton notice visible
  • Press Esc -- window closes
  • Check Data/Logs/Loom Log.txt -- contains startup / shutdown lines
  • Delete bin/Loom.exe, restart Project Manager -- Loom (Alpha) button is greyed out

🤖 Generated with Claude Code

First of a multi-PR rebuild of the "Loom" GUE redesign as a parallel
alpha editor. The previous attempt retrofitted Loom concepts on top of
GUE's F-UI surface; F-UI's quirks (window M_HIDE no-ops, listbox /
combobox handle inversion, Tab M_SETINDEX nested-iterator pathology,
unyielding visual language) made that path a losing game. This rebuild
runs as its own .bb / .exe so the UI shell can be designed from scratch
without fighting F-UI on a surface it wasn't designed for.

This PR is architectural proof only -- it ships the smallest possible
slice that demonstrates the build pipeline and the Project Manager
hook. The atlas, world view, and composer surfaces arrive in PRs 2-4.

What's in:
  - src/Loom.bb -- entry point. Boots Blitz3D, opens a window, runs
    a splash loop until Esc. Mirrors GUE.bb's bootstrap so paths and
    log placement match (writes to Data/Logs/Loom Log.txt next to
    GUE's log).
  - src/Modules/Loom/Theme.bb -- color tokens from the Loom design
    palette (stone / arcane / brass / parchment) plus 2D drawing
    helpers (LoomFill, LoomGradientV, LoomHRule, LoomText...) wrapping
    Blitz3D primitives. Subsequent surfaces paint through this layer
    instead of F-UI so they can express the gradient-heavy aesthetic.
  - src/Project Manager.bb -- adds an "Open in Loom (Alpha)" button
    next to the existing "Game Unified Editor" button in the Editors
    group. Auto-disables when bin/Loom.exe is missing. Launches with
    the same CWD as the GUE button so projects load identically.
  - compile.bat / compile.sh -- new build target for bin/Loom.exe
    placed alongside the existing GUE.exe / Server.exe / Client.exe
    invocations.

What's deliberately NOT in (deferred to PR 2+):
  - Data loading. The skeleton does not Include Items.bb / Actors.bb /
    Spells.bb yet; PR 2 wires those up so Loom reads the same in-memory
    representation GUE does.
  - F-UI integration. None of F-UI is included here. PR 3 will pull it
    in only for the text-input + file-dialog surfaces where F-UI earns
    its keep; everything visual stays in the Loom theme layer.
  - Atlas / world view / composer. PRs 2, 3, 4 respectively.

Verified: all five engine targets (Server, Client, Project Manager,
GUE, Loom) compile clean.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@CoreyRDean CoreyRDean requested a review from a team as a code owner May 26, 2026 20:05
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f290a65427

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/Modules/Loom/Theme.bb
Comment on lines +135 to +137
rr = r1 + ((r2 - r1) * i) / (h - 1)
gg = g1 + ((g2 - g1) * i) / (h - 1)
bb = b1 + ((b2 - b1) * i) / (h - 1)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Handle 1px gradients without dividing by zero

LoomGradientV divides by (h - 1) for color interpolation, which triggers an arithmetic exception when h = 1. A 1-pixel-tall fill is a valid input for this helper (e.g., thin bars or collapsed panels), so this can crash the editor as soon as such a call is added. Add a fast path for h = 1 (draw one line with either endpoint color) before entering the interpolation loop.

Useful? React with 👍 / 👎.

@CoreyRDean CoreyRDean merged commit 525e227 into develop May 27, 2026
1 check passed
@CoreyRDean CoreyRDean deleted the coreyrdean/loom-skeleton branch May 27, 2026 00:02
CoreyRDean added a commit that referenced this pull request May 27, 2026
Reviewer corrections on the dead-BVM audit-comment cluster:

1. Stale line numbers (3 of 5 audit cross-references were off after the
   comment blocks themselves displaced the dispatch cases downward).
   Rewrote as symbolic references:
   - "ServerAreas.bb:53" -> "ServerAreas.bb (the Type OwnedScenery and
     Field OwnedScenery[] declarations are commented out)" -- the Type
     name is unique enough to grep.
   - "RC_Standard_Invoker.bb:1363/1494" -> "Case 501 / Case 530" --
     Case numbers don't drift even if the surrounding code shifts.
   - "ScriptingCommands.bb:1046/1071" -> the impls are now found via
     `grep ';Function BVM_SETOWNER'` / `;Function BVM_SCENERYOWNER`
     instead of by line.
   - "RC_Standard_Invoker.bb:~95" -> "near the top of this file (grep
     'DEAD-API')" -- the unique sentinel finds the comment.

2. "Above" wording was wrong (the contract entries are *after* the
   audit-comment block, not before). Replaced with "next two lines".

3. .bcs file was not updated. Added the same audit-comment block at
   src/RC_Standard.bcs:113-121 so a maintainer reading the static
   command-set file sees the same trap warning as one reading the
   runtime-string builder.

Recon also surfaced that the just-rebased develop pulled in PR #292
(Loom Alpha) which adds src/Loom.bb + src/Modules/Loom/Theme.bb.
Verified Loom compiles cleanly alongside the BVM fix.

Compile-verified across all 5 engine targets (Server + Client + GUE +
Project Manager + Loom).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant