From 995bc5ba7d1b5e38cf294d6fa27db7ee89886a28 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 17 Nov 2015 20:16:14 +0300 Subject: Use magic command properties only if compiled for tmwa. --- src/textcommand.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'src/textcommand.cpp') diff --git a/src/textcommand.cpp b/src/textcommand.cpp index 04d479ece..3674ac9dc 100644 --- a/src/textcommand.cpp +++ b/src/textcommand.cpp @@ -34,6 +34,7 @@ #include "debug.h" +#ifdef TMWA_SUPPORT TextCommand::TextCommand(const unsigned int id, const std::string &symbol, const std::string &command, @@ -59,23 +60,27 @@ TextCommand::TextCommand(const unsigned int id, { loadImage(); } +#endif - -TextCommand::TextCommand(const unsigned int id, const std::string &symbol, +TextCommand::TextCommand(const unsigned int id, + const std::string &symbol, const std::string &command, const std::string &comment, - const CommandTargetT type, const std::string &icon) : + const CommandTargetT type, + const std::string &icon) : mCommand(command), mComment(comment), mSymbol(symbol), mTargetType(type), mIcon(icon), mId(id), +#ifdef TMWA_SUPPORT mMana(0), mSchool(MagicSchool::SkillMagic), mBaseLvl(0), mSchoolLvl(0), mCommandType(TextCommandType::Text), +#endif mImage(nullptr) { loadImage(); @@ -88,11 +93,13 @@ TextCommand::TextCommand(const unsigned int id) : mTargetType(CommandTarget::NoTarget), mIcon(""), mId(id), +#ifdef TMWA_SUPPORT mMana(0), mSchool(MagicSchool::SkillMagic), mBaseLvl(0), mSchoolLvl(0), mCommandType(TextCommandType::Text), +#endif mImage(nullptr) { loadImage(); -- cgit v1.2.3-70-g09d2