diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/game/Creature.cpp | 12 | ||||
| -rw-r--r-- | src/game/Creature.h | 4 | ||||
| -rw-r--r-- | src/game/ObjectMgr.cpp | 8 | 
3 files changed, 12 insertions, 12 deletions
| diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp index 3c90f4b3b62..aba48f985b7 100644 --- a/src/game/Creature.cpp +++ b/src/game/Creature.cpp @@ -733,12 +733,12 @@ bool Creature::isCanTrainingOf(Player* pPlayer, bool msg) const      switch(GetCreatureInfo()->trainer_type)      {          case TRAINER_TYPE_CLASS: -            if(pPlayer->getClass()!=GetCreatureInfo()->classNum) +            if(pPlayer->getClass()!=GetCreatureInfo()->trainer_class)              {                  if(msg)                  {                      pPlayer->PlayerTalkClass->ClearMenus(); -                    switch(GetCreatureInfo()->classNum) +                    switch(GetCreatureInfo()->trainer_class)                      {                          case CLASS_DRUID:  pPlayer->PlayerTalkClass->SendGossipMenu( 4913,GetGUID()); break;                          case CLASS_HUNTER: pPlayer->PlayerTalkClass->SendGossipMenu(10090,GetGUID()); break; @@ -763,12 +763,12 @@ bool Creature::isCanTrainingOf(Player* pPlayer, bool msg) const              }              break;          case TRAINER_TYPE_MOUNTS: -            if(GetCreatureInfo()->race && pPlayer->getRace() != GetCreatureInfo()->race) +            if(GetCreatureInfo()->trainer_race && pPlayer->getRace() != GetCreatureInfo()->trainer_race)              {                  if(msg)                  {                      pPlayer->PlayerTalkClass->ClearMenus(); -                    switch(GetCreatureInfo()->classNum) +                    switch(GetCreatureInfo()->trainer_class)                      {                          case RACE_DWARF:        pPlayer->PlayerTalkClass->SendGossipMenu(5865,GetGUID()); break;                          case RACE_GNOME:        pPlayer->PlayerTalkClass->SendGossipMenu(4881,GetGUID()); break; @@ -838,7 +838,7 @@ bool Creature::isCanTrainingAndResetTalentsOf(Player* pPlayer) const  {      return pPlayer->getLevel() >= 10          && GetCreatureInfo()->trainer_type == TRAINER_TYPE_CLASS -        && pPlayer->getClass() == GetCreatureInfo()->classNum; +        && pPlayer->getClass() == GetCreatureInfo()->trainer_class;  }  void Creature::prepareGossipMenu( Player *pPlayer,uint32 gossipid ) @@ -904,7 +904,7 @@ void Creature::prepareGossipMenu( Player *pPlayer,uint32 gossipid )                              cantalking=false;                          break;                      case GOSSIP_OPTION_UNLEARNPETSKILLS: -                        if(!pPlayer->GetPet() || pPlayer->GetPet()->getPetType() != HUNTER_PET || pPlayer->GetPet()->m_spells.size() <= 1 || GetCreatureInfo()->trainer_type != TRAINER_TYPE_PETS || GetCreatureInfo()->classNum != CLASS_HUNTER) +                        if(!pPlayer->GetPet() || pPlayer->GetPet()->getPetType() != HUNTER_PET || pPlayer->GetPet()->m_spells.size() <= 1 || GetCreatureInfo()->trainer_type != TRAINER_TYPE_PETS || GetCreatureInfo()->trainer_class != CLASS_HUNTER)                              cantalking=false;                          break;                      case GOSSIP_OPTION_TAXIVENDOR: diff --git a/src/game/Creature.h b/src/game/Creature.h index c22d670556b..9c94fa64423 100644 --- a/src/game/Creature.h +++ b/src/game/Creature.h @@ -207,8 +207,8 @@ struct CreatureInfo      uint32  family;                                         // enum CreatureFamily values (optional)      uint32  trainer_type;      uint32  trainer_spell; -    uint32  classNum; -    uint32  race; +    uint32  trainer_class; +    uint32  trainer_race;      float   minrangedmg;      float   maxrangedmg;      uint32  rangedattackpower; diff --git a/src/game/ObjectMgr.cpp b/src/game/ObjectMgr.cpp index d7337fadd77..0e684ee4213 100644 --- a/src/game/ObjectMgr.cpp +++ b/src/game/ObjectMgr.cpp @@ -559,15 +559,15 @@ void ObjectMgr::LoadCreatureTemplates()                  continue;              } -            if(cInfo->classNum != heroicInfo->classNum) +            if(cInfo->trainer_class != heroicInfo->trainer_class)              { -                sLog.outErrorDb("Creature (Entry: %u) listed in `creature_template_substitution` has different `classNum` in heroic mode.",i); +                sLog.outErrorDb("Creature (Entry: %u) has different `trainer_class` in heroic mode (Entry: %u).",i,cInfo->HeroicEntry);                  continue;              } -            if(cInfo->race != heroicInfo->race) +            if(cInfo->trainer_race != heroicInfo->trainer_race)              { -                sLog.outErrorDb("Creature (Entry: %u) listed in `creature_template_substitution` has different `race` in heroic mode.",i); +                sLog.outErrorDb("Creature (Entry: %u) has different `trainer_race` in heroic mode (Entry: %u).",i,cInfo->HeroicEntry);                  continue;              } | 
