DragonsPlusMinecraft / CreateCentralKitchen

An add-on for Create, offering more tools and methods to automate food processing of other mod.
https://modrinth.com/mod/create-central-kitchen
MIT License
22 stars 12 forks source link

Don't try to insert an unreasonable amount of watter into the poor kettle #51

Closed SiverDX closed 1 year ago

SiverDX commented 1 year ago

Should fix #41

Cannot test it since I have no experience with the mod(s) invovled, but here is the reasoning:

Water level is 2 I have 5 Bottles

Math.max(5, 1) It now tries to increment by 5 since that is the higher value

Math.min(5, 1) It increments by 1 and that is all we need


Water level is 1 I have 1 Bottle

Math.max(1, 2) It now tries to increment by 2 even though I only have 1 Bottle

Math.min(1, 2) It increments by 1 since I only have 1 bottle


With min it should only increment by a maximum of 3 since that is the highest 3 - waterLevel can go

MarbleGateKeeper commented 1 year ago

Thank you for the fix!