ModernUO/Projects
Kamron Batman 7da4171bbe
fix: creatures track and chase targets reliably around corners
Fixes the long-standing "monster loses track of a player who runs
around a corner" reports. Root causes and fixes:

1. Movement contract: MoveTo/ApproachTarget returned false on every
   healthy mid-chase tick, so MeleeAI's inherited "move failed and
   >RangePerception+1 -> Guard" clause (RunUO only ran it on real
   blockage) fired every tick of every chase. They now report failure
   only on genuine movement failure (no step with no working path, or
   approach give-up). ArcherAI's equivalent clause moves to the hard
   leash.

2. Last-known-position pursuit: while a combatant is in LOS its
   position is recorded each think tick. When the target vanishes
   (corner, hiding, recall) the creature investigates the last-seen
   spot, stands guard there ~10s (restoring RunUO's guard grace that
   had decayed to a single tick), and re-engages instantly if the same
   target re-enters view - bypassing the 10s reacquire throttle.

3. ChaseLeashRange (virtual, default RangePerception * 2 = 32 tiles)
   replaces the inline RangePerception * 3; per-creature tunable.

4. Group movement is now a crowding refinement, not a movement mode:
   it only engages near the target when allies contest the ring, and
   blocked/wall-slid steps escalate to the pathfinder instead of
   reporting success - previously any creature with one ally on the
   same target greedy-stepped for the whole chase and never pathfound.

5. Mages close distance when geometry (not hiding) blocks line of
   sight instead of standing at a wall holding a spell until the 60s
   combatant expiry.

6. Move budget: one actual step per AI think tick (half-step NextMove
   charge). Code paths that attempted several moves in one tick could
   cross multiple tiles at once - visible as "warping" when crowded
   creatures jockey for position. Blocked attempts consume nothing, so
   retry ladders are unaffected. CanMoveNow is wraparound-safe now.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-23 01:07:39 -07:00
..
Application fix: Bumps dependencies. (#2531) 2026-07-14 15:17:55 -07:00
BuildTool feat: Bumps dependencies. Introduces Serialization Generator v3 (#2584) 2026-08-22 15:48:53 -07:00
Logger fix: Bumps dependencies. (#2531) 2026-07-14 15:17:55 -07:00
Server feat: convert all delta-time serialization to anchored time (#2589) 2026-08-22 19:34:43 -07:00
Server.Tests feat: convert all delta-time serialization to anchored time (#2589) 2026-08-22 19:34:43 -07:00
UOContent fix: creatures track and chase targets reliably around corners 2026-08-23 01:07:39 -07:00
UOContent.Tests feat: Bumps dependencies. Introduces Serialization Generator v3 (#2584) 2026-08-22 15:48:53 -07:00