ak86 / Milk-Mod-Economy

http://www.loverslab.com/files/file/1382-milk-mod-economy/
2 stars 0 forks source link

extract MME.MilkMaid.LactacidCount to storage module #20

Closed ghost closed 8 years ago

ghost commented 8 years ago

The functions '(set|change)LactacidCurrent()' now automatically verify the provided value to make sure it is not set to an invalid value. The allowed range is '0 <= x <= LactacidMax'. For normal operation this is expected to have no influence but as a side effect it is now no longer possible to set a LactacidCount > LactacidMax (e.g. up to 100) via the MCM debug menu. The MCM slider max value has been adjusted to reflect this restriction.

Tracing output is provided if such a condition occurs. Additionally these functions will return 'true' in case the provided value is accepted without change or 'false' if the value was outside the allowed range. (It is safe to ignore these return values.)