Is it possible to instantiate a Lua class from API

Place to get help with not working mods / modding interface.
User avatar
TelemakFactorio
Long Handed Inserter
Long Handed Inserter
Posts: 53
Joined: Fri Oct 14, 2016 4:30 pm
Contact:

Is it possible to instantiate a Lua class from API

Post by TelemakFactorio »

I am looking for a hidden inventory. I think the invisible chest solution is overcomplicated.
Is it possible to instantiate a LuaInventory by code ? How do I do that ? There is a "new" word or something like in C++ ?

Regards
User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5207
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: Is it possible to instantiate a Lua class from API

Post by eradicator »

TelemakFactorio wrote: Is it possible to instantiate a LuaInventory by code ? How do I do that ? There is a "new" word or something like in C++ ?
No. Inventories only exist when they're bound to an actual entity.
User avatar
TelemakFactorio
Long Handed Inserter
Long Handed Inserter
Posts: 53
Joined: Fri Oct 14, 2016 4:30 pm
Contact:

Re: Is it possible to instantiate a Lua class from API

Post by TelemakFactorio »

Ok thanks :)
Post Reply

Return to “Modding help”