A4: Item models and icons

tools/models/items.py builds every item in headless Blender from
primitives: the boathook, the eight weapons and powder keg, four
consumables and five kinds of ammo, each with its own outline. It
writes an OBJ per item (the Debian Blender's glTF exporter needs numpy),
a JSON with the grip and the left hand's support point, and a 128 px
Cycles icon rendered on the CPU. Materials are named after Palette
colours, and TRIM2_/TRIM3_ surfaces are the tier treatment: rope
whipping from tier 2, brass bands from tier 3; tier 0 is faded.

ItemModels paints the models from Palette by tier. EntityView puts the
held item's grip in each figure's right hand, turned with the player's
pitch and put away aboard, falling, gliding or swimming, and draws
items lying in the world with their models, one MultiMesh per model
and tier. The hotbar shows each slot's icon.

make models rebuilds them; make item-captures renders the items held,
over the shoulder, on the ground and by tier.

Closes #44

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-13 14:46:41 -05:00
co-authored by Claude Opus 5.5
parent 2545337204
commit 0991f27700
127 changed files with 22903 additions and 28 deletions
+11 -1
View File
@@ -1,7 +1,7 @@
# Tidewall build entry points. Everything runs headless with the repo-local engine.
GODOT := tools/godot.sh
.PHONY: audio audio-check check import parse test test-selfcheck smoke capture-test terrain-capture binaries verify-engine bot-matches match match-captures client-check client-captures hud-captures style-captures menu-captures chart-captures discovery-check fuzz soak soak-selfcheck server-package-check
.PHONY: models item-captures audio audio-check check import parse test test-selfcheck smoke capture-test terrain-capture binaries verify-engine bot-matches match match-captures client-check client-captures hud-captures style-captures menu-captures chart-captures discovery-check fuzz soak soak-selfcheck server-package-check
## A8: regenerates every sound in assets/audio/ from tools/audio/ (about 6 s).
audio: import
@@ -11,6 +11,16 @@ audio: import
audio-check: import
@$(GODOT) --script res://tools/audio/check.gd
## A4: rebuilds every item model and icon in headless Blender (CPU only, about 20 s).
models:
@nice -n 15 blender --background --factory-startup --python tools/models/items.py
@$(GODOT) --import --quit >/dev/null 2>&1 || true
## A4: items held in the hand, over the shoulder, lying on the ground and by tier
## (captures/items_*.png, about 3 min). Needs Docker. Look at them.
item-captures: import
@for stage in held shoulder ground tiers; do tools/capture.sh items_$$stage captures/items_$$stage.png; done
## Everything that must pass before a push.
check: verify-engine binaries parse test test-selfcheck smoke