Module talk:Possible modifiers

From Terraria Wiki
Jump to navigation Jump to search

Rounding

Item.Prefix uses Math.Round to round the modified stat values when checking whether the modifier is valid to use. According to MSDN, this method uses "to-even" midpoint rounding instead of "away-from-zero", which causes x.5 values to be rounded to the even number instead of the greater number. For instance, while 2.5 would be rounded to 3 with "away-from-zero", it is rounded to 2 with "to-even". The round function in the module should represent this correctly now. --Rye Greenwood (talk) 17:41, 20 November 2020 (UTC)