Yeah. I think this was broken by r26962.
(and by "think" I mean I checked the output of `numeric_modifier weapon damage` on login with both r26961 and r26962, and confirmed that r26962 introduced the regression I've been using as my test case.)
Yeah, this isn't a new bug per se, but rather one that became much, much more visible with the organ tracking change. I checked out an earlier revision (r27601 contained the organ tracking change), and saw the same results for Weapon Damage:
modtrace calls recalculateAdjustments, but that happens at the end of the invocation...?
Well, at least we're consistent. And it looks like that call to modtrace recomputes the modifiers.
Changing mall_price() to return 0 would definitely break existing scripts.
I just cited that as the first instance that I found that checked historical_price(it) == 0, even if it's probably fine here.
I'm inclined to agree, but this has been observable behavior for so many years that it's...
One concern I have with storing -1 as a valid (crowdsourced) mallprice is that if an item is temporarily extinct (very possible for a low-volume item) or hasn't been added to the mall yet, we may end up caching -1 for longer than intended. This is probably fine, but something to be aware of...
r25983 apparently changed this behavior. Should be an easy enough fix, although it's a little worrying that nobody seems to have noticed in nearly 2 years.
https://forums.kingdomofloathing.com/vb/showthread.php?t=186384
Some other strategy comments:
1. Get unlockers (bombs / missiles / ice beam) to access more treasure rooms.
2. Get all the treasure rooms for upgrades, and more creds so you can buy more things in between levels.
3. bombs and...
modifiers.txt is appropriately qualified:
and have_skill correctly identifies which one I have.
I'm pretty sure this is further fallout from https://github.com/kolmafia/kolmafia/commit/7b9441e2fee0ad94ab9e5d4137a0d1ae82e291c3.
r27600 is fine, r27601 is broken (after hitting refresh). It was...
I've noticed on two separate occasions, with two separate scripts (my own and vconsume), that I've been overdrinking (but only on heeheehee).
Hard Drinker (Avatar of West of Loathing) is being mistaken for the AoSP skill.
The root cause is that if this.content == null, then this:
public Value get_path() {
return DataTypes.makePathValue(getAscensionClass().getPath());
}
tries to access getPath() on a null pointer.
Two relevant pieces:
1.
(note the absence of "path")
2.
Unexpected error, debug log printed.
class java.lang.NullPointerException: Cannot invoke "net.sourceforge.kolmafia.textui.AshRuntime.runtimeException(String)" because "interpreter" is null
java.lang.NullPointerException: Cannot invoke...
I believe the traditional (unoptimized) interpreter implements lexically-scoped closures by creating a new scope on each function call (with the parent scope being where the function is defined), which allows you to capture the value of any provided arguments and local variables.
Would I be...
Maybe in Java, but that's actually atypical, as far as I'm aware.
function makeCounter(a) {
// `a` below is bound to the provided function argument
return () => a += 1;
}
> counter = makeCounter(5)
() => a += 1
> counter()
6
> counter()
7
Closures have the ability to provide a...