From 8a17d95647f2d87a5a6c08efbcb32040462b4f37 Mon Sep 17 00:00:00 2001 From: Shauren Date: Sat, 16 Oct 2010 16:34:21 +0200 Subject: Scripts/Icecrown Citadel: Added Professor Putricide script Scripts/Icecrown Citadel: Fixed Professor Putricide gate opening when both Rotface and Festergut are dead Scripts/Icecrown Citadel: Added script updating entries of NPCs at Light's Hammer depending on faction Scripts/Icecrown Citadel: Rotface should not pick main tank as target for Slime Spray (removed debugging code) Core/Spells/Conditions : Spell script target condition now accepts ConditionValue3 as affecting effect mask (only search targets with matching mask) --HG-- branch : trunk extra : rebase_source : 943e3bac5d9063974d7f7132f144e91946f825d4 --- src/server/game/Conditions/ConditionMgr.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/server/game/Conditions/ConditionMgr.cpp') diff --git a/src/server/game/Conditions/ConditionMgr.cpp b/src/server/game/Conditions/ConditionMgr.cpp index a6626ca62b2..155d73569f2 100755 --- a/src/server/game/Conditions/ConditionMgr.cpp +++ b/src/server/game/Conditions/ConditionMgr.cpp @@ -828,10 +828,17 @@ bool ConditionMgr::isSourceTypeValid(Condition* cond) spellProto->EffectImplicitTargetB[i] == TARGET_UNIT_CONE_ENTRY) { targetfound = true; - break; + //break; + } + else if (cond->mConditionValue3 & (1 << i)) + { + cond->mConditionValue3 &= ~(1 << i); + sLog.outErrorDb("SourceEntry %u in `condition` table does not have any implicit target TARGET_UNIT_NEARBY_ENTRY(38) or TARGET_DST_NEARBY_ENTRY (46)" + ",TARGET_UNIT_AREA_ENTRY_SRC(7), TARGET_UNIT_AREA_ENTRY_DST(8), TARGET_UNIT_CONE_ENTRY(60), TARGET_GAMEOBJECT_NEARBY_ENTRY(40)" + "TARGET_GAMEOBJECT_AREA_SRC(51), TARGET_GAMEOBJECT_AREA_DST(52) in effect %u", cond->mSourceEntry, uint32(i)); } } - if (!targetfound) + if (!targetfound && !cond->mConditionValue3) // cond->mConditionValue3 already errored up there { sLog.outErrorDb("SourceEntry %u in `condition` table does not have any implicit target TARGET_UNIT_NEARBY_ENTRY(38) or TARGET_DST_NEARBY_ENTRY (46)" ",TARGET_UNIT_AREA_ENTRY_SRC(7), TARGET_UNIT_AREA_ENTRY_DST(8), TARGET_UNIT_CONE_ENTRY(60), TARGET_GAMEOBJECT_NEARBY_ENTRY(40)" @@ -1175,9 +1182,6 @@ bool ConditionMgr::isConditionTypeValid(Condition* cond) break; } } - - if (cond->mConditionValue3) - sLog.outErrorDb("SpellTarget condition has useless data in value3 (%u)!", cond->mConditionValue3); break; } case CONDITION_CREATURE_TARGET: -- cgit v1.2.3