Potion counts on the bottom bar and potion stacks in the inventory
- potioncounts.cpp: each potion slot shows how many potions of its kind the hero carries (stacks added up) - potionstack.cpp: potions of one type stack up to 20 per cell; every potion entering the hero's grid pours into stacks with room, the sort button stacks first, drinking takes one off a stack, counts drawn on the cells and saved in the JSON inventories - game/engine/items.h: potion kinds and grid helpers; ObjectManager and DestroyObject in objects.h - auto-attack: the projectile-weapon target radius is a design value - docs/potion-stacks.md: measured paths and the design Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
b2e886c7f5
commit
13b91cdd3d
13 files changed
+612
-10
No files matched your search
@@ -102,6 +102,24 @@
|
||||
0x005dd9f0 cInventoryEntry::Serialize # (stream, write)
|
||||
0x005de8a0 cInventoryEntry::FixInventory
|
||||
0x005da880 cInventoryEntry::GetPotionRef
|
||||
0x0043f630 ItemPotionKind # (ecx = item type table *0xaa9564, type): potion kind 1-5, 0 = none
|
||||
0x006e39e0 cUI_Taskbar2::RenderPotionSlots # 5 potion kinds, controls at +0x258 (stride 0xbc)
|
||||
0x005d9ec0 cInventoryEntry::PlaceItem # (cell, id, w, h, notify) -> network 0x13f; returns the item it replaced
|
||||
0x005da290 cInventoryEntry::GetItemAt # (cell, resolve covered cells)
|
||||
0x005da360 cInventoryEntry::CountItems
|
||||
0x005da390 cInventoryEntry::RemoveAt # (cell, notify) -> network 0x13e
|
||||
0x005da5f0 cInventoryEntry::RemoveItem # (id, notify)
|
||||
0x005dab60 cInventoryEntry::FindFreeSpace # (w, h, out cell, mode)
|
||||
0x005dac70 cInventoryEntry::FitsAt # (cell, w, h)
|
||||
0x005db670 cInventoryEntry::Sort # (mode): the inventory window's sort button, trader stock
|
||||
0x005dc3f0 cInventoryEntry::DrawItems # (renderer, flag)
|
||||
0x005dd530 cInventoryEntry::CellRect # (out rect, cell): 32x32 from the origin at +0x1164 / +0x1166
|
||||
0x0054a8f0 cCreature::UseItem # (id): event 0x10 to the item; used up -> RemoveItem + DestroyObject
|
||||
0x005fbe10 cObjectManager::DestroyObject # (id, 1, 0, 0)
|
||||
0x005ca9d0 cPotion3D::ReceiveEvent # vf18: drink effect, sets +0x14 bit 0x8000000 (used up)
|
||||
0x00613040 cEngine::UseActionSlot # (potion kind, ...): potion keys
|
||||
0x006c5f40 cUI_Inventory3::HandleEvent # sort button (+0x158) -> cInventoryEntry::Sort
|
||||
0x006c1210 cUI_InventoryTab::Render # grid origin (0, 0x188), DrawItems
|
||||
0x0057f750 SlotCountForLevel # table 0x95503c, max 5
|
||||
0x008110d0 GameWindowProc # in-game window procedure: keys (dead keys, modifiers 0x182cdec)
|
||||
0x005def60 cInventoryManager::Serialize # (stream, write, x): all 32 inventories, save games
|
||||
|
||||
Reference in new issue
Block a user