Commit graph

230 commits

Author SHA1 Message Date
Erik
e2982e34b5 feat: render actual dungeon tile textures in radar
Extract 614 UB tile BMPs into dungeon_tiles.json (287KB base64 bundle).
Frontend loads tiles once, then draws them rotated per-cell using
environment IDs. Falls back to colored rectangles if tiles not loaded.
Current floor at 70% opacity, other floors at 15%.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 15:14:52 +02:00
Erik
b941a29f04 feat: add dungeon map streaming and rendering in radar
- Backend: dungeon_map event handler with permanent in-memory cache
  by landblock ID, request_dungeon_map for late-joining browsers
- Frontend: render dungeon cells as colored rectangles when in dungeon,
  multi-level Z support (current floor bright, others dimmed),
  automatic overworld/dungeon switching based on is_dungeon flag,
  raw physics coordinate positioning for dungeon objects

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 13:16:36 +02:00
Erik
2f21159acb feat: add dereth.png map background to radar canvas
Draws a rotated/scaled slice of the overworld map behind radar dots.
Map clips to the radar circle, rotates with heading-up mode, and
renders at 40% opacity so dots remain visible on top.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:49:38 +02:00
Erik
2b9aa7f4ae revert: switch back to original dereth.png (6123x6123)
The original high-res map matches GoArrow's in-game map.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:47:14 +02:00
Erik
672819e591 feat: switch to UtilityBelt's acmap.png (2048x2048)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:43:22 +02:00
Erik
f6301a8cab feat: swap map to high-res color-corrected Dereth map
Replace dereth.png with Thwargle's highres_colorCorrect.png (2041x2041).
Same coordinate bounds (-102.1 to 102.1), dimensions read dynamically.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:41:47 +02:00
Erik
60eab15fff feat: scroll-wheel zoom and click-to-select in radar
- Replace range dropdown with smooth scroll-wheel zoom on canvas
- Click dot on canvas to select it (white ring + name label)
- Click row in entity list to select on canvas
- Click again to deselect
- Selected row highlighted with blue accent in list
- Auto-scrolls list to keep selected row visible

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:28:09 +02:00
Erik
359d255730 fix: correct compass E/W and object rotation
AC heading is standard clockwise (0=N, 90=E). Both compass labels
and object rotation need positive heading — previous negation broke
the compass while fixing objects. Now both use the same sign.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:20:35 +02:00
Erik
eaa5b5c48d fix: negate AC heading for correct E/W compass orientation
AC's Actions.Heading uses opposite rotation from standard math
angles (confirmed by UtilityBelt's HeadingToQuaternion negation).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:14:51 +02:00
Erik
502467e075 fix: radar compass always heading-up with rotating N/E/S/W labels, fix reopen bug
- Compass is now always heading-up: player facing direction is fixed
  pointing up, N/E/S/W labels rotate around the edge as player turns
- Fix: reopening a closed radar window now resends start_radar command
  so streaming resumes without needing a full page refresh

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 12:07:40 +02:00
Erik
3852cf205e Add real-time radar feature for nearby objects
Browser can open a radar window per character that streams nearby
monsters, players, NPCs, portals, and other objects in real-time.
On-demand activation via start_radar/stop_radar commands through
the existing WebSocket command channel.

- Backend: nearby_objects event handler with in-memory cache and broadcast
- Frontend: canvas mini-map + entity list table in draggable window
- Radar button added to player list alongside Chat/Stats/Inventory/Char

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-07 23:01:05 +02:00
erik
c0da36c280 fix: decouple browser broadcast from plugin WebSocket receive loop
🧝‍♂️ Fix 1: The Mailman Story

Imagine you're a mailman delivering letters. Before, you had to
knock on every door and wait for someone to answer before you could
go back to your truck and get more letters.

But your truck keeps getting MORE letters dumped in it! And if
you're stuck waiting at grandma's door... your truck overflows
and letters fall everywhere! 📬💥

The fix: Now you have a magic helper elf! You hand the letters to
the elf and say "you go deliver these!" while you run back to the
truck to grab more. The elf handles the doors, you handle the truck.
Nobody waits! 🧝‍♂️

🍕 Fix 2: The Pizza Party Story

Now let's talk about that elf. The elf had a problem too!

Imagine you have 5 friends at a pizza party and you're handing out
slices. Before, the elf would:

1. Give pizza to Tommy → wait for him to take a bite 🍕
2. Give pizza to Sally → wait for her to take a bite 🍕
3. Give pizza to Bobby → wait for him to take a bite 🍕

So boring! Everyone's just sitting there hungry!

The fix: Now the elf throws ALL the pizza slices at the same time!
🍕🍕🍕🍕🍕 Everyone gets their pizza at once and nobody has to
wait for Tommy to finish chewing!

Yay! 🎉

Technical details:
- Use asyncio.create_task() to fire-and-forget broadcasts
- Use asyncio.gather() to send to all browsers concurrently
- Plugin receive loop no longer blocks on slow browser clients

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-30 20:53:59 +00:00
Erik
5c20d40f1f Reduce inventory column gap from 20px to 13px 2026-03-13 20:54:31 +01:00
Erik
0f1fcc1231 Fix active pack indicator: change sidebar/pack-list overflow to visible so yellow frame and arrow show 2026-03-13 20:51:51 +01:00
Erik
0b2fe8fb1e Fix inventory 3-column layout: 20px gaps, fixed 316px left column width 2026-03-13 20:46:49 +01:00
Erik
e02edfde8a fix: increase column gap to 8px 2026-03-13 20:41:43 +01:00
Erik
932a6d8ea7 fix: narrow container column to reduce paperdoll overlap 2026-03-13 20:38:29 +01:00
Erik
cff99f9b87 refactor: 3-column inventory layout (paperdoll+items | packs | mana) 2026-03-13 20:34:36 +01:00
Erik
66ff5f01fc fix: constrain item grid to 6-slot width, fix scroll chain 2026-03-13 20:27:15 +01:00
Erik
e7879c57fb fix: remove scrollbar from pack list sidebar 2026-03-13 20:21:13 +01:00
Erik
50de20c5a7 fix: restore item grid scrollbar (was overflow-y: hidden) 2026-03-13 20:09:14 +01:00
Erik
f028e3421c fix: cap sidebar height to paperdoll, scroll pack list 2026-03-13 20:07:38 +01:00
Erik
83deb20a7f fix: move backpack contents below paperdoll, not below mana panel 2026-03-13 20:03:17 +01:00
Erik
a6e941eb01 fix: simplify burden meter to pure inline styles 2026-03-13 19:52:49 +01:00
Erik
bb89aaa6bc fix: drop stalled browser websocket clients 2026-03-13 16:55:17 +01:00
Erik
a3c3d0286e fix: separate burden label from meter 2026-03-13 16:29:30 +01:00
Erik
ca88f90476 fix: unclip burden meter label and fill 2026-03-13 16:26:22 +01:00
Erik
c3f5450e0d fix: force burden meter visibility 2026-03-13 11:26:35 +01:00
Erik
a17b1fc11e fix: layer burden meter fill correctly 2026-03-13 11:22:44 +01:00
Erik
b318c04fd6 fix: restore burden meter colors 2026-03-13 11:17:45 +01:00
Erik
8bea346a57 fix: refine burden meter display 2026-03-13 11:08:30 +01:00
Erik
40217572b1 fix: accept burden stats from plugin 2026-03-13 10:55:27 +01:00
Erik
692a92128c fix: compute burden percent from capacity 2026-03-13 10:29:43 +01:00
Erik
26624a302b fix: show true character burden 2026-03-13 10:04:25 +01:00
Erik
7013288152 fix: use the correct main pack icon 2026-03-13 09:55:44 +01:00
Erik
a7e2d4d404 feat: stream live equipment cantrip states 2026-03-13 08:59:43 +01:00
Erik
0cb8e2f75a fix: refine mana panel item filtering 2026-03-13 08:31:16 +01:00
Erik
b204ba8e75 fix: improve mana tracker state matching 2026-03-13 08:25:37 +01:00
Erik
84da2a8752 fix: refine mana panel layout and state display
Widen the inventory layout so the backpack column no longer crowds the paperdoll, and base mana active/inactive display on the live data currently available from inventory payloads.
2026-03-13 07:32:57 +01:00
Erik
4972b342d2 fix: size inventory window to fit mana rows
Grow the inventory window and mana panel dynamically based on tracked item count so all mana entries remain visible without introducing a scrollable panel.
2026-03-13 07:23:35 +01:00
Erik
dc7b26676d fix: tighten mana panel layout and icon sizing
Adjust the inventory mana panel to fit beside the backpack column without overlap, prevent the panel from scrolling, shrink composite icons correctly, and refine mana-state derivation using existing item spell data.
2026-03-12 07:54:56 +01:00
Erik
63ea242167 refactor: tighten inventory mana panel layout
Move the Mana panel to the right of the backpack column, widen the inventory window, and switch to a smaller Mag-Tools-style row layout with compact icons and status dots.
2026-03-11 20:09:05 +01:00
Erik
0e8186b8e5 feat: add mana tracker panel to inventory
Derive equipped item mana state and time-remaining data in inventory-service, then render a Mana panel inside the inventory window with live icon, state, mana, and countdown display.
2026-03-11 20:02:52 +01:00
erik
4e73a5d07d docs: add suitbuilder algorithm documentation
Describes the full search pipeline, item loading, bucket creation,
armor reduction, scoring weights, and constraint satisfaction logic.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 21:01:25 +00:00
erik
ede333ed2e feat: add Healing and Summoning cantrip constraints to suitbuilder
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 20:57:11 +00:00
erik
fc557ab1d5 feat: update inventory frontend and services to current production state 2026-03-07 08:37:32 +00:00
erik
7050cfb8b7 feat: add missing legendary cantrips to suitbuilder
Add Dual Wield, Recklessness, Deception, Sneak Attack, and Dirty Fighting cantrips to both the HTML checkbox UI and the COMMON_CANTRIPS JS array for lock form dropdowns.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-03-04 16:16:52 +00:00
erik
973c3722bc fix: address code review findings for inventory delta feature
- Fix remaining f-string SQL injection in process_inventory (same pattern
  as single-item endpoints: parameterized ANY(:ids) queries)
- Add null guard for item_id in backend delta remove handler
- Add response status logging for inventory service HTTP calls
- Fix frontend ID fallback consistency in updateInventoryLive
- Replace debug print() with logger.debug()
- Add comment for Decal Slot_Decal magic number

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-28 15:58:10 +00:00
erik
f145e6e131 feat: fix inventory service SQL injection, add slot population, and live frontend updates
- Replace f-string SQL interpolation with parameterized ANY(:ids) queries
- Populate slot column from IntValues[231735296] (Decal Slot key)
- Add startup migration to add container_id/slot columns to existing DB
- Extract createInventorySlot() for reuse by initial load and live deltas
- Add updateInventoryLive() handler for WebSocket inventory_delta messages
- Add inventory_delta case to browser WebSocket message dispatcher

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-28 15:51:20 +00:00
erik
749652d534 feat: add single-item upsert/delete endpoints and container/slot columns
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-28 15:43:58 +00:00