Page 1 of 1

[1.6.7] T-engine bug with saving infinity

Posted: Tue Jun 02, 2020 8:04 pm
by minmay
Had an unloadable save due to an NPC saving its -math.huge high_value for a talent:

Code: Select all

["high_value"]=-inf
tostring() on infinity will result in "inf", and tostring() on negative infinity will result in "-inf", but unlike "999", "inf" in code won't be interpreted as a number literal, it will be interpreted as an identifier. Same goes for "nan". These need to be special cased for saving.