I recently started writing my own counterScript, and I’ve noticed a serious issue: It doesn’t seem to trigger reliably when running certain scripts (for example, Ezandora’s FantasyRealm script). I imagine this is related to the specific functions these scripts use, so I’d like to know exactly what triggers a counterScript to run.
Without having seen that particular script, I would guess it has to do with some scripts using adventure() vs visit_url(). The former includes a lot of configurable automation (moods, mana burning, before/afterBattle scripts, counterScripts, hp/mp recovery, combat/choiceadv handling), whereas the latter includes none of that. Replicating all of KoLmafia's adventure() automation when using visit_url() is possible, but it's recreating the wheel and script authors inevitably leave steps out.
Of course, that may not be what's going on here, in which case ignore this; but if it is, hopefully that helps.
It would be nice if there was a good way to do this, run KoLmafia's preadventure code without actually adventuring. I've taking to telling KoLmafia to go adventure some place it can't, but also can't know that.
Originally Posted by zarqon