Closes the two open issues and lands the pending unreleased batch: - #90: `Sprite { atlas: 1 }` routes esys_sprite through atlas_draw_ex (scale/flip/tint), so cell / cell_span / strip ids of any size draw through the engine sprite-render system. examples/library/sprite_atlas is the pixel-readback regression. - #91: `become` from an @On(Event) listener / global handler / plain function no longer segfaults the compiler; it emits @L_scene_leave() (a dispatch on the live scene id) so the leaving scene's on-exit runs. UI_* handles are readable from any code (widget table built on first use). examples/library/scene_menus covers it. - fix: a windowed `ludicc -o` build that reaches the audio runtime only through the atlas/Assets preload import now links audio.ll + AVFoundation (the audio backend link was gated on a game-level Audio.* call, so any windowed game declaring Sprite failed to link). - the hand-written "Unreleased" CHANGELOG section is converted to changesets under changes/ so `x release` generates it. - plus the batch: engine-driven retained UI + UiClicked event, Overlay phase, TileSkin tilemap-render system, Key.* constants, Font/Ui/File namespaces, Sprite.strip, prefabs, managers, countdown fields, enum-typed machines, layer @Queries, ludic.prefs / ludic.dungeon packages, Ai.seek pathing, Solids.solid2, cursor confine (mode 3) fix, shooter centre-aim fix, reserved-word function diagnostic. Verified: x test (124/124), x test-tools, check-impl, check-vocabulary, check-docs, docs-gen + docs-check, bootstrap-cfree (seed is a fixpoint). Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
parent
e9c2c51bc3
commit
ad548840c7
139 changed files with 58981 additions and 43671 deletions
|
|
@ -38,7 +38,7 @@ function getenv_or(name: pointer, dflt: pointer) -> pointer {
|
|||
return v
|
||||
}
|
||||
|
||||
# guarantee a directory string ends in '/' so path_join concatenates cleanly
|
||||
# guarantee a directory string ends in '/' so join_path concatenates cleanly
|
||||
function ensure_slash(d: pointer) -> pointer {
|
||||
let n = len(d)
|
||||
if n == 0 { return d }
|
||||
|
|
@ -63,7 +63,7 @@ function chomp(s: pointer) -> pointer {
|
|||
# so a version change never requires reseeding the compiler.
|
||||
function show_version() -> void {
|
||||
let home = ensure_slash(getenv_or("LUDIC_HOME", dir_of(arg(0))))
|
||||
let v = read_file(path_join(home, "VERSION"))
|
||||
let v = read_file(join_path(home, "VERSION"))
|
||||
if (v == null) { print("ludic (version unknown)") }
|
||||
else { print(`ludic {chomp(v)}`) }
|
||||
exit(0)
|
||||
|
|
@ -124,6 +124,7 @@ entry {
|
|||
if fmt { exit(0) }
|
||||
|
||||
maybe_splice_runtime()
|
||||
ui_register_gotos() # `goto:` buttons -> generated UiClicked listeners
|
||||
|
||||
# a game gets a window by default; a plain program stays headless. An explicit
|
||||
# flag always wins. The stdout-IR path (no target) also stays headless, which
|
||||
|
|
@ -160,7 +161,7 @@ entry {
|
|||
# would otherwise warn about on every build.
|
||||
var cmd = `{cc} -O2 -Wno-override-module {ll}`
|
||||
if g_windowed {
|
||||
let cocoa = path_join(home, "runtime/native/cocoa.ll")
|
||||
let cocoa = join_path(home, "runtime/native/cocoa.ll")
|
||||
# GameController holds no symbol cocoa.ll references directly (its classes are
|
||||
# reached by name through objc_getClass), so a plain -framework link gets
|
||||
# dead-stripped; -needed_framework forces the load command so the class is
|
||||
|
|
@ -170,7 +171,7 @@ entry {
|
|||
# when the program actually uses it — the snd_* calls are is_windowed()-guarded
|
||||
# yet still live in a windowed build, so the backend must link.
|
||||
if g_uses_audio {
|
||||
let audio = path_join(home, "runtime/native/audio.ll")
|
||||
let audio = join_path(home, "runtime/native/audio.ll")
|
||||
cmd = `{cmd} {audio} -Wl,-needed_framework,AVFoundation`
|
||||
}
|
||||
}
|
||||
|
|
@ -178,7 +179,7 @@ entry {
|
|||
# reached by name). Works headless too, so it is outside the windowed block —
|
||||
# macOS-only for now, which is where the toolchain runs.
|
||||
if g_uses_http {
|
||||
let http = path_join(home, "runtime/native/http.ll")
|
||||
let http = join_path(home, "runtime/native/http.ll")
|
||||
cmd = `{cmd} {http} -Wl,-needed_framework,Foundation`
|
||||
}
|
||||
cmd = `{cmd} -o {out}`
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue