aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Conditions/ConditionMgr.cpp
diff options
context:
space:
mode:
authorthesensei <aconstantgoal@abv.bg>2012-09-21 00:07:56 +0300
committerthesensei <aconstantgoal@abv.bg>2012-09-21 00:07:56 +0300
commite34b7e70c54522e8ae933fffddaae04136b48103 (patch)
tree1850fc6008d43c2b1a489cd0611bcf783a68bf5a /src/server/game/Conditions/ConditionMgr.cpp
parent1f03439fc2365a751febbfe86ab823b55daa040e (diff)
Core/Conditions: Add relation to creator
* This is used in spells with effect summon where the summoned creature doesn't get a *summonedby* flag and so relation to owner is not working. This way the unit get relation to the master who created it. * World case where I'm going to use this is summoning Oculus drakes * Blizzard seems to handle such cases with special spells in dbc that are missing and sniff gives nothing for them. The number of spells is unknown, but existence of atleast 10 is seen. They are used usually as bonus effects to make the check however mechanic is unknown. Guessing it is good as adding this.
Diffstat (limited to 'src/server/game/Conditions/ConditionMgr.cpp')
-rwxr-xr-xsrc/server/game/Conditions/ConditionMgr.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/server/game/Conditions/ConditionMgr.cpp b/src/server/game/Conditions/ConditionMgr.cpp
index 546c4f303b2..7dc4b57d188 100755
--- a/src/server/game/Conditions/ConditionMgr.cpp
+++ b/src/server/game/Conditions/ConditionMgr.cpp
@@ -223,6 +223,9 @@ bool Condition::Meets(ConditionSourceInfo& sourceInfo)
case RELATION_PASSENGER_OF:
condMeets = unit->IsOnVehicle(toUnit);
break;
+ case RELATION_CREATED_BY:
+ condMeets = unit->GetCreatorGUID() == toUnit->GetGUID();
+ break;
}
}
}