Commit graph RynthSuite/Tools/RynthCore.RynthAiHostTests/Tests/LearnSpellsTests.cs
Author SHA1 Message Date
Daniel Wallace
bb8ac3e60f Pace scroll reads and the stance restore from the read's UseDone
ACE sends "The scroll is destroyed." before the return-to-ready animation and
the UseDone after it (Scroll.ActOnUse, Player.TryUseItem); in a client log they
were ~0.7 s apart, and the next read went ~0.8 s after the UseDone.

- The first UseDone after a read's send is that read's. The next read goes
  250 ms after it; with no UseDone seen, 1.5 s after the read's end as before.
- The stance restore goes at the last read's UseDone when no scroll is pending,
  instead of 3.5 s after the read; a pending scroll keeps the settle wait.
- Tests: ReadGapFromUseDone, StanceRestoredAtLastUseDone.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 16:50:23 -07:00
Daniel Wallace
bef9b2b1a3 Restore the combat stance after a scroll read
Using a scroll puts the character in Peace. ScrollLearner remembers the mode from
before the first read of a run (Melee/Missile/Magic, Peace Mode When Idle off) and
requests it once, 3.5 s after the last read ends, through ChangeCombatModeFor (pacing,
busy wait, 3 tries). Dropped when the tick is not safe (fight/buff), or another
subsystem already changed the mode.

Review fixes:
- A restore more than 15 s after the settle time is dropped (death/vendor/buff holds, a stuck busy).
- The main-hand weapon is recorded at the first read; a different one cancels the restore (ACE reverts
  a mode the weapon does not fit).
- Only a request that went out counts toward the 3-request cap; pacer holds are retried.
- Peace Mode When Idle is re-checked each tick; the macro-stop close logs only from Peace; logs name modes.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 16:44:15 -07:00
12ca25f911 RynthSuite as of 2026-10-04 (internal c94715f): RynthOracle (based on Oracle of Dereth by Advis Eveldan) and RynthInventory, RynthAi patrol doorways and rooms, healing priority, strict monster priority, finish the wounded target, slayer weapons, arcs when clear, blasts like rings, learn unknown spells, looting fixes, release 2026.10.4.6
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 18:34:29 -04:00