play-test copies are temporary (levels/.playtest, removed and mod selection restored when the game ends), add to llamamod and keep option in the editor, remove level and open levels folder in the launcher plus --remove-level, unique level mod ids for files differing only in case, esc leaves the waypoint tool
This commit is contained in:
1 parent
2386443fac
commit
1c8b766454
24 files changed
+823
-87
No files matched your search
@@ -15,17 +15,26 @@ seconds after the game window opens, and **Escape** quits back to the editor.
|
||||
| Play boots straight into the level | Level menu (check) | off = old behaviour (main menu, map cursor) |
|
||||
| Escape quits the play-test | Level menu (check) | boot mod option `quitOnEscape` |
|
||||
|
||||
* Run: `PlayTest.build` (built-in, background) → the project snapshot is written to
|
||||
`<data>/levels/<stem>.llamalevel` → the user's **active** mods (others on the same WAD and Test
|
||||
* Run: `PlayTest.build` (built-in, background) → the project snapshot is written to the
|
||||
**temporary** `<data>/levels/.playtest/<stem>.llamalevel` (mod id `playtest-<stem>`; with
|
||||
"Keep play-tested level in LlamaMod" on: `<data>/levels/<stem>.llamalevel` as before) → the user's **active** mods (others on the same WAD and Test
|
||||
World on chapter 1 turned off) + the level mod become `enabledMods`; `boot-to-level` is applied
|
||||
**in addition** (not stored in `enabledMods`) with world/chapter of the project, slot
|
||||
(Preferences, default 3), `logos=true`, `quitOnEscape`, `start` → save slot unlocked up to the
|
||||
level → `GameLauncher.launch`.
|
||||
* **Restore**: a daemon thread polls `GameLauncher.isRunning()` every 2 s; when the game has
|
||||
ended it re-applies the user's selection without the boot mod (cached outputs, < 1 s) and
|
||||
restores the boot mod's own options → LlamaMod's normal Play starts at the menu again
|
||||
(`RestoreCheck`: active `[level-…, boot-to-level]` → `[level-…]`, exe without mod patches).
|
||||
If the editor is closed before the game, LlamaMod shows the selection as "apply needed".
|
||||
ended it re-applies the user's **previous** active mods and enabled list (stored in the
|
||||
session: `mods`, `enabled`, `bootOptions`), restores the boot mod's own options and deletes
|
||||
`levels/.playtest/` plus `playtest-*` entries in `enabledMods`/`modOptions`
|
||||
(`LevelProjects.clearPlaytest`). With "keep" the level stays enabled/active (old behaviour).
|
||||
The session file `<data>/editor/playtest-session.json` lets the next editor start finish it;
|
||||
without a session, the next editor start deletes leftover copies if no game runs
|
||||
(`clearStale`). The non-boot Play (menu, map cursor) uses the same install/restore path now.
|
||||
* **Level → Add to LlamaMod…**: writes the snapshot to `<data>/levels/` (`PlayTest.installTarget`:
|
||||
the same project's file is reused, file names compared case-insensitively) and sets the mod's
|
||||
`chapter` option to the project's TestLevel chapter.
|
||||
* The launcher hides `playtest-*` mods unless enabled/active (then: "(play-test)" + blue badge
|
||||
"temporary play-test", no Remove button).
|
||||
* **Play from camera position**: ground point = depth-buffer hit at the viewport centre
|
||||
(export space → game x, y, −z), heading = camera yaw (`atan2(f.x, −f.z)`, 0 = +z).
|
||||
`FloorFinder` then looks for **collision**: highest floor polygon (|n.y| ≥ 0.5) at or below
|
||||
@@ -102,7 +111,17 @@ hardware is untested.
|
||||
|
||||
## Tests
|
||||
|
||||
`BootToLevelModTest` (hooks at both frame handlers, logo patch, exe re-parses; Escape hook only
|
||||
`PlaytestLifecycleTest` (temporary copy listed as `playtest-…` → restore removes it and puts
|
||||
the enabled list back; keep → stays; stale copies cleared; Remove → backups, refused while the
|
||||
game runs; regression: `My-level`/`my-level` get distinct ids), `BootToLevelModTest` (hooks at both frame handlers, logo patch, exe re-parses; Escape hook only
|
||||
when asked; start parsing; original village: only the llama moves, file size unchanged;
|
||||
editor-style chain moves and turns with the llama), `RestoreCheck` (manual), `EdTour` +
|
||||
`PlayTourSteps` (scripted editor runs on an X display: camera placement, play-from-here).
|
||||
|
||||
## Temporary play-test copies – verified in game (apptest lvlrm, game on :5, editor on :31, 2026-11-07)
|
||||
|
||||
EdTour `run:level.play` on `/tmp/…/mytest.llamalevel` (real launch, private pulse): during the
|
||||
game `levels/.playtest/mytest.llamalevel`, enabled `[playtest-mytest]`, active
|
||||
`[playtest-mytest, boot-to-level]`, Testwelt plaza in game (`img/mods/levels_playtest_temporary.jpg`);
|
||||
Escape → game gone → `.playtest` deleted, enabled `[]` and active `[level-old-village-test]` as
|
||||
before the test, session file removed. Launcher badge: `img/mods/levels_playtest_badge.jpg`.
|
||||
Reference in new issue
Block a user