entity.fluidbox.get_capacity(i) and entity.fluidbox.get_connections(i) returns the capacity/connections of the (i+1)st fluid box
Example: To get the contents of a boiler's fluidboxes, you use boiler.fluidbox[1] and boiler.fluidbox[2]. To get their capacities, currently you need to use boiler.fluidbox.get_capacity(0) and boiler.fluidbox.get_capacity(1).
I'll assume this is a bug and not that you've suddenly switched to 0-based indexing.
[0.15.1] LuaFluidbox.get_capacity() indices off by 1
-
- Inserter
- Posts: 37
- Joined: Sun Jul 17, 2016 9:05 pm
- Contact:
[0.15.1] LuaFluidbox.get_capacity() indices off by 1
I don't visit the forum very often. If you want to contact me, message me on the mod portal for Factorissimo-related things, or on Discord.
Re: [0.15.1] LuaFluidbox.get_capacity() indices off by 1
Thanks for the report. Fixed for 0.15
If you want to get ahold of me I'm almost always on Discord.