mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 22:37:03 +00:00
Merge commit 'origin/master' into 310
Conflicts: src/game/Player.cpp
This commit is contained in:
commit
950a4bf13f
52 changed files with 623 additions and 474 deletions
|
|
@ -601,12 +601,12 @@ void ObjectMgr::LoadCreatureTemplates()
|
|||
sLog.outErrorDb("Creature (Entry: %u) has non-existing PetSpellDataId (%u)", cInfo->Entry, cInfo->PetSpellDataId);
|
||||
}
|
||||
|
||||
for(int i = 0; i < CREATURE_MAX_SPELLS; ++i)
|
||||
for(int j = 0; j < CREATURE_MAX_SPELLS; ++j)
|
||||
{
|
||||
if(cInfo->spells[i] && !sSpellStore.LookupEntry(cInfo->spells[i]))
|
||||
if(cInfo->spells[j] && !sSpellStore.LookupEntry(cInfo->spells[j]))
|
||||
{
|
||||
sLog.outErrorDb("Creature (Entry: %u) has non-existing Spell%d (%u), set to 0", cInfo->Entry, i+1,cInfo->spells[i]);
|
||||
const_cast<CreatureInfo*>(cInfo)->spells[i] = 0;
|
||||
sLog.outErrorDb("Creature (Entry: %u) has non-existing Spell%d (%u), set to 0", cInfo->Entry, j+1,cInfo->spells[j]);
|
||||
const_cast<CreatureInfo*>(cInfo)->spells[j] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1082,7 +1082,15 @@ void ObjectMgr::LoadGameobjects()
|
|||
data.rotation3 = fields[10].GetFloat();
|
||||
data.spawntimesecs = fields[11].GetInt32();
|
||||
data.animprogress = fields[12].GetUInt32();
|
||||
data.go_state = fields[13].GetUInt32();
|
||||
|
||||
uint32 go_state = fields[13].GetUInt32();
|
||||
if (go_state >= MAX_GO_STATE)
|
||||
{
|
||||
sLog.outErrorDb("Table `gameobject` have gameobject (GUID: %u Entry: %u) with invalid `state` (%u) value, skip",guid,data.id,go_state);
|
||||
continue;
|
||||
}
|
||||
data.go_state = GOState(go_state);
|
||||
|
||||
data.spawnMask = fields[14].GetUInt8();
|
||||
data.phaseMask = fields[15].GetUInt16();
|
||||
int16 gameEvent = fields[16].GetInt16();
|
||||
|
|
@ -2687,15 +2695,15 @@ void ObjectMgr::LoadGroups()
|
|||
result = CharacterDatabase.Query("SELECT memberGuid, assistant, subgroup, leaderGuid FROM group_member ORDER BY leaderGuid");
|
||||
if(!result)
|
||||
{
|
||||
barGoLink bar( 1 );
|
||||
bar.step();
|
||||
barGoLink bar2( 1 );
|
||||
bar2.step();
|
||||
}
|
||||
else
|
||||
{
|
||||
barGoLink bar( result->GetRowCount() );
|
||||
barGoLink bar2( result->GetRowCount() );
|
||||
do
|
||||
{
|
||||
bar.step();
|
||||
bar2.step();
|
||||
Field *fields = result->Fetch();
|
||||
count++;
|
||||
leaderGuid = MAKE_NEW_GUID(fields[3].GetUInt32(), 0, HIGHGUID_PLAYER);
|
||||
|
|
@ -2747,15 +2755,15 @@ void ObjectMgr::LoadGroups()
|
|||
|
||||
if(!result)
|
||||
{
|
||||
barGoLink bar( 1 );
|
||||
bar.step();
|
||||
barGoLink bar2( 1 );
|
||||
bar2.step();
|
||||
}
|
||||
else
|
||||
{
|
||||
barGoLink bar( result->GetRowCount() );
|
||||
barGoLink bar2( result->GetRowCount() );
|
||||
do
|
||||
{
|
||||
bar.step();
|
||||
bar2.step();
|
||||
Field *fields = result->Fetch();
|
||||
count++;
|
||||
leaderGuid = MAKE_NEW_GUID(fields[0].GetUInt32(), 0, HIGHGUID_PLAYER);
|
||||
|
|
@ -3142,7 +3150,7 @@ void ObjectMgr::LoadQuests()
|
|||
{
|
||||
sLog.outErrorDb("Quest %u has `ReqSpellCast%d` = %u but spell %u does not exist, quest can't be done.",
|
||||
qinfo->GetQuestId(),j+1,id,id);
|
||||
// no changes, quest can't be done for this requirement
|
||||
continue;
|
||||
}
|
||||
|
||||
if(!qinfo->ReqCreatureOrGOId[j])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue