Merge commit 'dbaf88566be7083408fb8324d7886dc3e0a45cc0' into 4.3.4

Conflicts:
	.gitattributes
	CONTRIBUTING.md
	sql/updates/world/2015_05_11_04_world.sql
	sql/updates/world/2015_05_27_00_world.sql
	sql/updates/world/2015_05_27_01_world.sql
	sql/updates/world/2015_06_06_01_world_335.sql
	src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp
	src/server/game/Entities/Creature/Creature.cpp
	src/server/game/Entities/Creature/Creature.h
	src/server/game/Entities/Object/ObjectGuid.h
	src/server/game/Entities/Player/Player.cpp
	src/server/game/Entities/Player/Player.h
	src/server/game/Entities/Unit/Unit.cpp
	src/server/game/Entities/Unit/Unit.h
	src/server/game/Spells/Auras/SpellAuras.cpp
	src/server/game/Spells/Spell.cpp
	src/server/game/Spells/SpellMgr.cpp
	src/server/scripts/Commands/cs_modify.cpp
	src/server/scripts/Kalimdor/zone_moonglade.cpp
	src/server/scripts/Spells/spell_hunter.cpp
	src/server/scripts/Spells/spell_item.cpp
	src/server/scripts/Spells/spell_rogue.cpp
This commit is contained in:
Carbenium committed 2015-07-22 02:09:32 +02:00
commit 6dfaec3d97
119 files changed
+3776 -2162

No files matched your search

+17 -56
View File
@@ -378,28 +378,13 @@ public:
uint32 lowGuid = atoi((char*)guidStr);
Creature* creature = NULL;
/* FIXME: impossible without entry
if (lowguid)
creature = ObjectAccessor::GetCreature(*handler->GetSession()->GetPlayer(), MAKE_GUID(lowguid, HIGHGUID_UNIT));
*/
// attempt check creature existence by DB data
if (!creature)
CreatureData const* data = sObjectMgr->GetCreatureData(lowGuid);
if (!data)
{
CreatureData const* data = sObjectMgr->GetCreatureData(lowGuid);
if (!data)
{
handler->PSendSysMessage(LANG_COMMAND_CREATGUIDNOTFOUND, lowGuid);
handler->SetSentErrorMessage(true);
return false;
}
}
else
{
// obtain real GUID for DB operations
lowGuid = creature->GetDBTableGUIDLow();
handler->PSendSysMessage(LANG_COMMAND_CREATGUIDNOTFOUND, lowGuid);
handler->SetSentErrorMessage(true);
return false;
}
int wait = waitStr ? atoi(waitStr) : 0;
@@ -415,18 +400,6 @@ public:
WorldDatabase.Execute(stmt);
if (creature && creature->GetWaypointPath())
{
creature->SetDefaultMovementType(WAYPOINT_MOTION_TYPE);
creature->GetMotionMaster()->Initialize();
if (creature->IsAlive()) // dead creature will reset movement generator at respawn
{
creature->setDeathState(JUST_DIED);
creature->Respawn(true);
}
creature->SaveToDB();
}
handler->SendSysMessage(LANG_WAYPOINT_ADDED);
return true;
@@ -840,34 +813,22 @@ public:
lowguid = atoi(cId);
/* FIXME: impossible without entry
if (lowguid)
creature = ObjectAccessor::GetCreature(*handler->GetSession()->GetPlayer(), MAKE_GUID(lowguid, HIGHGUID_UNIT));
*/
// Attempting creature load from DB data
if (!creature)
CreatureData const* data = sObjectMgr->GetCreatureData(lowguid);
if (!data)
{
CreatureData const* data = sObjectMgr->GetCreatureData(lowguid);
if (!data)
{
handler->PSendSysMessage(LANG_COMMAND_CREATGUIDNOTFOUND, lowguid);
handler->SetSentErrorMessage(true);
return false;
}
uint32 map_id = data->mapid;
if (handler->GetSession()->GetPlayer()->GetMapId() != map_id)
{
handler->PSendSysMessage(LANG_COMMAND_CREATUREATSAMEMAP, lowguid);
handler->SetSentErrorMessage(true);
return false;
}
handler->PSendSysMessage(LANG_COMMAND_CREATGUIDNOTFOUND, lowguid);
handler->SetSentErrorMessage(true);
return false;
}
else
uint32 map_id = data->mapid;
if (handler->GetSession()->GetPlayer()->GetMapId() != map_id)
{
lowguid = creature->GetDBTableGUIDLow();
handler->PSendSysMessage(LANG_COMMAND_CREATUREATSAMEMAP, lowguid);
handler->SetSentErrorMessage(true);
return false;
}
}
else