cameroncondry / cbc-kitten-scientists

Add-on for the wonderful incremental browser game: http://kittensgame.com/web/
MIT License
113 stars 94 forks source link

Show number of kittens sent to hunt, not catpower #165

Closed cokernel closed 8 years ago

cokernel commented 8 years ago

This modifies the hunt() function so that it looks up game.village.getJob('hunter').value instead of game.getDisplayValueExt(catpower.value) when recording hunts in the activity log, fixing #154. The word "kittens" is correctly singularized when only one hunter is available.

cameroncondry commented 8 years ago

Thanks again!

cokernel commented 8 years ago

Unfortunately, I missed the interaction with storeForSummary(), and so I will see (e.g.) "Sent 11 kittens on the hunt" in the regular log but "Sent 10.97 adorable kitten hunters" in the activity summary. I think it ought to be sufficient to call storeForSummary() with the number of hunters (instead of the current catpower) and then avoid the division by 100 in displayActivitySummary().

I hope to submit a correction soon. Am I correct in thinking that getDisplayValueExt() should be used even for expressing numbers of kittens? (I've never had more than 543 kittens in my games, but I imagine that for any resource I struggle with, there's someone who has more than they know what to do with generating every second.)