Wait a moment. Is this just a small change in the type(..)-method or is this a massive code change with huge performance gains for mods?
Search found 4 matches
- Thu Feb 23, 2023 2:50 pm
- Forum: Resolved Problems and Bugs
- Topic: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
- Replies: 9
- Views: 5323
Re: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
- Thu Feb 23, 2023 2:25 pm
- Forum: Resolved Problems and Bugs
- Topic: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
- Replies: 9
- Views: 5323
Re: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
This looks awesome. Thank you. 
- Thu Feb 23, 2023 10:31 am
- Forum: Resolved Problems and Bugs
- Topic: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
- Replies: 9
- Views: 5323
Re: [1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
I agree. Before that it would be nice to add a line in the api documentation informing about this bugrobot256 wrote: Thu Feb 23, 2023 12:20 amAlternatively, the devs could simply delete the LuaFluidBox::get_prototype(n) from the API, since it does not work as advertised or in any consistent manner, so we can stop wasting time with it.
- Wed Feb 22, 2023 1:42 pm
- Forum: Resolved Problems and Bugs
- Topic: [boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
- Replies: 9
- Views: 5323
[boskid][1.1.76] calling LuaEntity.fluidbox.get_prototype(index) sometimes returns wrong prototype.
code:
for i = 1,#machine.fluidbox do
game.print(i.." ".. machine.fluidbox.get_prototype(i).base_level .. " " .. machine.fluidbox.get_prototype(i).production_type)
end
correct result for "Advanced oil processing":
1 -1 input
2 -1 input
3 1 output
4 1 output
5 1 output
unexpected result for ...
for i = 1,#machine.fluidbox do
game.print(i.." ".. machine.fluidbox.get_prototype(i).base_level .. " " .. machine.fluidbox.get_prototype(i).production_type)
end
correct result for "Advanced oil processing":
1 -1 input
2 -1 input
3 1 output
4 1 output
5 1 output
unexpected result for ...