Inventory

Lua related functions

class miney.Inventory(minetest: miney.minetest.Minetest, parent: object)[source]

Inventories are places to store items, like Chests or player inventories.

add(item: str, amount: int = 1)None[source]

Add an item to an inventory. Possible items can be obtained from type.

Parameters
  • item – item type

  • amount – item amount

Returns

None

remove(item: str, amount: int = 1)None[source]

Remove an item from an inventory. Possible items can be obtained from mt.node.type.

Parameters
  • item – item type

  • amount – item amount

Returns

None