diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2012-01-23 20:23:56 +0100 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-02-02 15:54:20 +0200 |
commit | 64af6d3afe6ff677aa25e2cbb7395a911f8621af (patch) | |
tree | ab73593d00325ca2866ef240331749ed20645f3a | |
parent | 365f7a5bfe0cf1838b0c6f3936c4437f3dd9f1f7 (diff) | |
download | minetest-64af6d3afe6ff677aa25e2cbb7395a911f8621af.tar.gz minetest-64af6d3afe6ff677aa25e2cbb7395a911f8621af.tar.bz2 minetest-64af6d3afe6ff677aa25e2cbb7395a911f8621af.zip |
Fix some warnings on some compilers
ItemStack is a struct, not a class
CollisionInfo is a struct, not a class
InventoryAction is abstract and it needs a virtual destructor
-rw-r--r-- | src/inventorymanager.h | 1 | ||||
-rw-r--r-- | src/player.h | 2 | ||||
-rw-r--r-- | src/scriptapi.h | 2 | ||||
-rw-r--r-- | src/serverobject.h | 2 |
4 files changed, 4 insertions, 3 deletions
diff --git a/src/inventorymanager.h b/src/inventorymanager.h index 55e8f8402..52377f9a4 100644 --- a/src/inventorymanager.h +++ b/src/inventorymanager.h @@ -103,6 +103,7 @@ struct InventoryAction virtual void apply(InventoryManager *mgr, ServerActiveObject *player, IGameDef *gamedef) = 0; virtual void clientApply(InventoryManager *mgr, IGameDef *gamedef) = 0; + virtual ~InventoryAction() {}; }; struct IMoveAction : public InventoryAction diff --git a/src/player.h b/src/player.h index 085a4a15a..d62fb6111 100644 --- a/src/player.h +++ b/src/player.h @@ -30,7 +30,7 @@ with this program; if not, write to the Free Software Foundation, Inc., class Map; class IGameDef; -class CollisionInfo; +struct CollisionInfo; class Player { diff --git a/src/scriptapi.h b/src/scriptapi.h index 500a9ab99..df8ae344e 100644 --- a/src/scriptapi.h +++ b/src/scriptapi.h @@ -30,7 +30,7 @@ class ServerActiveObject; class ServerRemotePlayer; typedef struct lua_State lua_State; struct LuaEntityProperties; -class ItemStack; +struct ItemStack; struct PointedThing; //class IGameDef; diff --git a/src/serverobject.h b/src/serverobject.h index 94ceb4895..380bf7302 100644 --- a/src/serverobject.h +++ b/src/serverobject.h @@ -42,7 +42,7 @@ Some planning */ class ServerEnvironment; -class ItemStack; +struct ItemStack; class Player; struct ToolDiggingProperties; |