okay so sorry if i say or do something stupid i am entirely new to modding factorio( but i am already good at lua )
What im trying to do:
im trying to make a machine that stores a dynamically increasing amount of one item type,
and that increases that storage amount when provided a specific item (dynomite),
example, 5 bombs will increase the machines capacity by 10 ( numbers will probably be different )
any help appreciated, sorry if im just dumb.
new and need help with giving a machine custom functionality
Re: new and need help with giving a machine custom functionality
If you're already good with Lua, you need to get yourself familiar with the Data Life Cycle and the API
I'm no expert in either of those, but it seems that dynamicly changing inventory size is only possible for the player through inventory size bonus, which seems exclusive to player armor and research, while containers (chests) get their inventory size set in the prototype stage.
There might be a hack around it for what you need with non container entities that have inventory, but im not sure if that could help you, if it's even possible.
I'm no expert in either of those, but it seems that dynamicly changing inventory size is only possible for the player through inventory size bonus, which seems exclusive to player armor and research, while containers (chests) get their inventory size set in the prototype stage.
There might be a hack around it for what you need with non container entities that have inventory, but im not sure if that could help you, if it's even possible.
Re: new and need help with giving a machine custom functionality
As it turns out, you absolutely can resize a inventory with LuaInventory, in fact LuaInventory can do everything i needed it to.GrumpyJoe wrote: ↑Wed Jul 03, 2024 4:01 amIf you're already good with Lua, you need to get yourself familiar with the Data Life Cycle and the API
I'm no expert in either of those, but it seems that dynamicly changing inventory size is only possible for the player through inventory size bonus, which seems exclusive to player armor and research, while containers (chests) get their inventory size set in the prototype stage.
There might be a hack around it for what you need with non container entities that have inventory, but im not sure if that could help you, if it's even possible.
Thanks for the help!