summaryrefslogtreecommitdiff
path: root/src/serverobject.h
diff options
context:
space:
mode:
authorSmallJoker <SmallJoker@users.noreply.github.com>2019-08-07 19:16:31 +0200
committerGitHub <noreply@github.com>2019-08-07 19:16:31 +0200
commite462a9a5ef46776d974203bb44e0b89e8c980b29 (patch)
tree4562ef5587bd896890d843877031d5818de19bbc /src/serverobject.h
parent003af7421352ec1b8ba0d230b807862e1e4cc7e9 (diff)
downloadminetest-e462a9a5ef46776d974203bb44e0b89e8c980b29.tar.gz
minetest-e462a9a5ef46776d974203bb44e0b89e8c980b29.tar.bz2
minetest-e462a9a5ef46776d974203bb44e0b89e8c980b29.zip
Unify wield item handling (#8677)
This moves the wield item functions to Player and the tool utils for range calculation Also 'local_inventory' was removed due to redundancy in Client
Diffstat (limited to 'src/serverobject.h')
-rw-r--r--src/serverobject.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/serverobject.h b/src/serverobject.h
index 08f7a7e58..c81abb972 100644
--- a/src/serverobject.h
+++ b/src/serverobject.h
@@ -170,9 +170,7 @@ public:
{}
// Inventory and wielded item
- virtual Inventory* getInventory()
- { return NULL; }
- virtual const Inventory* getInventory() const
+ virtual Inventory *getInventory() const
{ return NULL; }
virtual InventoryLocation getInventoryLocation() const
{ return InventoryLocation(); }
@@ -180,7 +178,7 @@ public:
{}
virtual std::string getWieldList() const
{ return ""; }
- virtual int getWieldIndex() const
+ virtual u16 getWieldIndex() const
{ return 0; }
virtual ItemStack getWieldedItem() const;
virtual bool setWieldedItem(const ItemStack &item);