Hello,
A small request. Make burner inventory for new entities valid in game API.
I created radar with burner energy source. It works fine, player or inserter can put fuel inside and it burns -> consumes energy, scans chunks...
But it doesn't allow to do anything with its inventory (e.g. get items count or insert fuel) in mod script. Burner inventory validity check always returns false. And if this check is skipped then error occurs about burner inventory currently being not valid. I tried to give entity some time to maybe finish initiating burner, but its inventory always remains invalid, even after player puts some fuel.
Tried to fuel stone-furnace via script - works fine, its burner inventory is always valid.
Excuse me if I put this request in wrong thread.
Burner inventory validity for different entities
Re: Burner inventory validity for different entities
I think you might want to post in modding help. I tried what you said and it all works correctly for me:
If you want to get ahold of me I'm almost always on Discord.
Re: Burner inventory validity for different entities
Hello Rseding91,
But... you did it not how API documentation describes it.
I replaced getting burner inventory with your example and mod started to work as it should.
Thank you!
P.S.
API documentation way (and it works, but only with default game entities) for your example will be:
global f = game.player.selected.burner.inventory
game.print(global.f.valid)
But... you did it not how API documentation describes it.
I replaced getting burner inventory with your example and mod started to work as it should.
Thank you!
P.S.
API documentation way (and it works, but only with default game entities) for your example will be:
global f = game.player.selected.burner.inventory
game.print(global.f.valid)
Re: Burner inventory validity for different entities
Ahh ok, so that's a bug that needs to be fixed.
If you want to get ahold of me I'm almost always on Discord.