Properly implemented CONDITION_ACHIEVEMENT for the DB gossip system.

--HG--
branch : trunk
This commit is contained in:
Xanadu committed 2010-03-15 04:37:28 +01:00
1 parent 8cc3d2ad7f
commit f9566e08ac
4 files changed
+12 -4

No files matched your search

+2 -1
View File
@@ -47,6 +47,7 @@
#include "InstanceData.h" //for condition_instance_data
#include "GossipDef.h"
#include "Vehicle.h"
#include "AchievementMgr.h"
INSTANTIATE_SINGLETON_1(ObjectMgr);
@@ -7728,7 +7729,7 @@ bool PlayerCondition::Meets(Player const * player) const
case CONDITION_ACHIEVEMENT:
{
AchievementEntry const* achievement = GetAchievementStore()->LookupEntry(value1);
return (achievement,1);
return player->GetAchievementMgr().HasAchieved(achievement);
}
case CONDITION_TEAM:
return player->GetTeam() == value1;