mirror of
https://github.com/prosolis/gogobee.git
synced 2026-07-15 08:32:41 +00:00
J3 D8-e: GOGOBEE_SIM_INLINE_BOSS toggle for engine A/B
Diagnostic env toggle (off by default) routing the sim's boss/elite doorways through the inline SimulateCombat path instead of the turn engine, for A/B-ing the martial T4/T5 'regression'. D8-e confirmed the gap is honest multiattack math (inline swings the enemy once/round; the turn engine loops the full SRD profile) and that prod autopilot is secretly easier than manual !fight. Toggle left in for the D8-f parity work.
This commit is contained in:
@@ -14,6 +14,7 @@ package plugin
|
|||||||
import (
|
import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"os"
|
||||||
"sort"
|
"sort"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
@@ -22,6 +23,12 @@ import (
|
|||||||
"maunium.net/go/mautrix/id"
|
"maunium.net/go/mautrix/id"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// simInlineBossCombat is a D8-e DIAGNOSTIC toggle. When GOGOBEE_SIM_INLINE_BOSS=1
|
||||||
|
// the sim routes boss/elite doorways through the inline SimulateCombat path
|
||||||
|
// (production autopilot behavior) instead of the turn-based !fight engine.
|
||||||
|
// Used to A/B the martial T4/T5 regression. NOT for production.
|
||||||
|
func simInlineBossCombat() bool { return os.Getenv("GOGOBEE_SIM_INLINE_BOSS") == "1" }
|
||||||
|
|
||||||
// SimRunner owns a temp-DB AdventurePlugin + EuroPlugin pair and exposes
|
// SimRunner owns a temp-DB AdventurePlugin + EuroPlugin pair and exposes
|
||||||
// just enough surface to drive synthetic players end-to-end.
|
// just enough surface to drive synthetic players end-to-end.
|
||||||
type SimRunner struct {
|
type SimRunner struct {
|
||||||
@@ -429,7 +436,7 @@ func (s *SimRunner) RunExpedition(uid id.UserID, zoneID ZoneID, walkCap, maxDays
|
|||||||
|
|
||||||
for i := 0; i < walkCap; i++ {
|
for i := 0; i < walkCap; i++ {
|
||||||
simNow = simNow.Add(simWalkInterval)
|
simNow = simNow.Add(simWalkInterval)
|
||||||
walk := s.P.runAutopilotWalk(ctx, autopilotRoomCap, true, false)
|
walk := s.P.runAutopilotWalk(ctx, autopilotRoomCap, true, simInlineBossCombat())
|
||||||
if walk.initErr != "" {
|
if walk.initErr != "" {
|
||||||
res.Outcome = "halted"
|
res.Outcome = "halted"
|
||||||
res.StopCode = "init:" + walk.initErr
|
res.StopCode = "init:" + walk.initErr
|
||||||
|
|||||||
Reference in New Issue
Block a user