aboutsummaryrefslogtreecommitdiff
path: root/src/script/lua_api/l_inventory.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/script/lua_api/l_inventory.h')
-rw-r--r--src/script/lua_api/l_inventory.h24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/script/lua_api/l_inventory.h b/src/script/lua_api/l_inventory.h
index fa8a77ae2..94f670c9d 100644
--- a/src/script/lua_api/l_inventory.h
+++ b/src/script/lua_api/l_inventory.h
@@ -30,8 +30,7 @@ class RemotePlayer;
InvRef
*/
-class InvRef : public ModApiBase
-{
+class InvRef : public ModApiBase {
private:
InventoryLocation m_loc;
@@ -40,9 +39,10 @@ private:
static InvRef *checkobject(lua_State *L, int narg);
- static Inventory *getinv(lua_State *L, InvRef *ref);
+ static Inventory* getinv(lua_State *L, InvRef *ref);
- static InventoryList *getlist(lua_State *L, InvRef *ref, const char *listname);
+ static InventoryList* getlist(lua_State *L, InvRef *ref,
+ const char *listname);
static void reportInventoryChange(lua_State *L, InvRef *ref);
@@ -88,17 +88,16 @@ private:
// Returns the leftover stack
static int l_add_item(lua_State *L);
- // room_for_item(self, listname, itemstack or itemstring or table or nil) ->
- // true/false Returns true if the item completely fits into the list
+ // room_for_item(self, listname, itemstack or itemstring or table or nil) -> true/false
+ // Returns true if the item completely fits into the list
static int l_room_for_item(lua_State *L);
- // contains_item(self, listname, itemstack or itemstring or table or nil,
- // [match_meta]) -> true/false Returns true if the list contains the given count
- // of the given item name
+ // contains_item(self, listname, itemstack or itemstring or table or nil, [match_meta]) -> true/false
+ // Returns true if the list contains the given count of the given item name
static int l_contains_item(lua_State *L);
- // remove_item(self, listname, itemstack or itemstring or table or nil) ->
- // itemstack Returns the items that were actually removed
+ // remove_item(self, listname, itemstack or itemstring or table or nil) -> itemstack
+ // Returns the items that were actually removed
static int l_remove_item(lua_State *L);
// get_location() -> location (like get_inventory(location))
@@ -117,8 +116,7 @@ public:
static void Register(lua_State *L);
};
-class ModApiInventory : public ModApiBase
-{
+class ModApiInventory : public ModApiBase {
private:
static int l_create_detached_inventory_raw(lua_State *L);