summaryrefslogtreecommitdiff
path: root/src/spellmanager.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-02-24 01:30:46 +0300
committerAndrei Karas <akaras@inbox.ru>2013-02-24 01:32:02 +0300
commit3da7fa61442364be6713359690a35f89aa8e613a (patch)
tree48a941dbbb0234b897478aa50518112407d08e5b /src/spellmanager.cpp
parent470aaad15a0f9a08dd12ab34c8602cd93fc57b76 (diff)
downloadmanaplus-3da7fa61442364be6713359690a35f89aa8e613a.tar.gz
manaplus-3da7fa61442364be6713359690a35f89aa8e613a.tar.bz2
manaplus-3da7fa61442364be6713359690a35f89aa8e613a.tar.xz
manaplus-3da7fa61442364be6713359690a35f89aa8e613a.zip
Add support for show quest variables in skills window (evol only)
This allow use pseudo skills controlled by quest variables.
Diffstat (limited to 'src/spellmanager.cpp')
-rw-r--r--src/spellmanager.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/spellmanager.cpp b/src/spellmanager.cpp
index 27b6f45e7..93480fb63 100644
--- a/src/spellmanager.cpp
+++ b/src/spellmanager.cpp
@@ -135,11 +135,10 @@ void SpellManager::invoke(const int spellId)
if (spell->getCommandType() == TEXT_COMMAND_TEXT
|| (Net::getPlayerHandler()->canUseMagic()
- && PlayerInfo::getStatEffective(static_cast<PlayerInfo::Attribute>(
- SKILL_MAGIC)) >= static_cast<signed>(spell->getBaseLvl())
+ && PlayerInfo::getStatEffective(SKILL_MAGIC)
+ >= static_cast<signed>(spell->getBaseLvl())
&& PlayerInfo::getStatEffective(
- static_cast<PlayerInfo::Attribute>(spell->getSchool()))
- >= static_cast<signed>(spell->getSchoolLvl())
+ spell->getSchool()) >= static_cast<signed>(spell->getSchoolLvl())
&& PlayerInfo::getAttribute(PlayerInfo::MP) >= spell->getMana()))
{
const Being *const target = player_node->getTarget();