From df8346ef4d70ba7c717c4c7b9c783df876378ca8 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Wed, 16 Nov 2011 14:08:31 +0200 Subject: Do not expose CONTENT_* stuff in content_mapnode.h and use a name converter wrapper in old code --- src/content_nodemeta.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/content_nodemeta.cpp') diff --git a/src/content_nodemeta.cpp b/src/content_nodemeta.cpp index 17b4a3da4..ab9849668 100644 --- a/src/content_nodemeta.cpp +++ b/src/content_nodemeta.cpp @@ -19,10 +19,14 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "content_nodemeta.h" #include "inventory.h" -#include "content_mapnode.h" #include "log.h" #include "utility.h" +#define NODEMETA_SIGN 14 +#define NODEMETA_CHEST 15 +#define NODEMETA_LOCKABLE_CHEST 17 +#define NODEMETA_FURNACE 16 + /* SignNodeMetadata */ @@ -38,7 +42,7 @@ SignNodeMetadata::SignNodeMetadata(IGameDef *gamedef, std::string text): } u16 SignNodeMetadata::typeId() const { - return CONTENT_SIGN_WALL; + return NODEMETA_SIGN; } NodeMetadata* SignNodeMetadata::create(std::istream &is, IGameDef *gamedef) { @@ -79,7 +83,7 @@ ChestNodeMetadata::~ChestNodeMetadata() } u16 ChestNodeMetadata::typeId() const { - return CONTENT_CHEST; + return NODEMETA_CHEST; } NodeMetadata* ChestNodeMetadata::create(std::istream &is, IGameDef *gamedef) { @@ -142,7 +146,7 @@ LockingChestNodeMetadata::~LockingChestNodeMetadata() } u16 LockingChestNodeMetadata::typeId() const { - return CONTENT_LOCKABLE_CHEST; + return NODEMETA_LOCKABLE_CHEST; } NodeMetadata* LockingChestNodeMetadata::create(std::istream &is, IGameDef *gamedef) { @@ -215,7 +219,7 @@ FurnaceNodeMetadata::~FurnaceNodeMetadata() } u16 FurnaceNodeMetadata::typeId() const { - return CONTENT_FURNACE; + return NODEMETA_FURNACE; } NodeMetadata* FurnaceNodeMetadata::clone(IGameDef *gamedef) { -- cgit v1.2.3