Closed NathanSalapat closed 9 years ago
Well, it could be caused by the thirsty.dat
reading. I currently don't think it's worth saving thirst_factor
(please correct me if I'm wrong here), but the reading part does attempt to initialize all the player's values; thirst_factor
should at least be set to the default value there.
I've pushed a (potential) bug fix: 05f0cac0b42eb00b1fbdfe5bed18a37907c9d7f5 . I'd be grateful if you could give it a spin, and see if that fixes it.
I can't see why it would be worth saving, as if it is changed by the environment it would be changed back on the next check. Unless somebody wanted to do potions at some time?
I'll certainly give it a spin and let you know if it is working for me.
Thanks! Since the bug fix is something that I probably should have done anyway (initializing a field), I went ahead and tagged it as a release, version 0.9.1. I'm still very much interested in whether this actually fixes the bug, of course.
Both of my worlds are now playable with Thirsty enabled, so I'd say this fixes it.
When trying to enter a saved world with the latest release I get this error. ServerError: ...athan/.minetest/games/Survive/mods/thirsty/functions.lua:205: attempt to perform arithmetic on field 'thirst_factor' (a nil value) 2015-07-14 18:44:51: ERROR[main]: stack traceback: 2015-07-14 18:44:51: ERROR[main]: ...athan/.minetest/games/Survive/mods/thirsty/functions.lua:205: in function <...athan/.minetest/games/Survive/mods/thirsty/functions.lua:86>
From what I can tell the 'thirst_factor' doesn't get saved or read, which might be all the problem is, but deleting the thirst.dat in the world folder had no difference.