# To do ## Better pathfinder (mouse clicks and monsters) Replace the game's pathfinding with a more reliable and efficient one, for click-to-move and for monster AI. What we know so far: - Walk orders are `cEvent_creature` command 4 with a ground target (+0x18/+0x1c), sent through `cEngine::SendCreatureOrder` (`0x6170d0`), which snaps the target to a walkable point (`0x616b70`) and hands it to `cCreature::ReceiveOrder` (`0x52e400`, vf18, ~6400 decompiled lines). - Far targets (~2000 world units) are rejected or followed badly. - Still to map: the path search itself, the sector/tile collision data it reads, and how monster AI issues its moves. ## Key bindings moved for WASD movement (temporary) W, A and S were game hotkeys. With WASD movement (`src/mods/wasd.cpp`) their actions moved to other keys for now; choose final bindings (and update the in-game texts/tooltips that name the old keys): | Key | Action | Temporary key (`[wasd]` in sacred_re.ini) | |---|---|---| | W | action slot 3 (`cEngine::UseActionSlot`, like Q/E/R/B/Space) | G (`ActionKeyW`) | | A | pick up items nearby (creature event 0x113) | V (`ActionKeyA`) | | S | save game window (`UI_WND_SAVEGAME`) | K (`ActionKeyS`) | | D | unbound | - | Globally bound letters (engine `0x618130`, UI manager `0x757120`): A B C E F H I L M N O P Q R S T W, Space, ^, digits. Individual windows may use more.