mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
*Allow use gm command to set value for gobjects.
--HG-- branch : trunk
This commit is contained in:
@@ -200,15 +200,10 @@ bool ChatHandler::HandleDebugSendOpcodeCommand(const char* /*args*/)
|
||||
}
|
||||
else if(type == "appgoguid")
|
||||
{
|
||||
uint32 lowguid;
|
||||
ifs >> lowguid;
|
||||
GameObject *obj = NULL;
|
||||
if (GameObjectData const* go_data = objmgr.GetGOData(lowguid))
|
||||
obj = GetObjectGlobalyWithGuidOrNearWithDbGuid(lowguid,go_data->id);
|
||||
|
||||
GameObject *obj = GetNearbyGameObject();
|
||||
if(!obj)
|
||||
{
|
||||
PSendSysMessage(LANG_COMMAND_OBJNOTFOUND, lowguid);
|
||||
PSendSysMessage(LANG_COMMAND_OBJNOTFOUND, 0);
|
||||
SetSentErrorMessage(true);
|
||||
ifs.close();
|
||||
return false;
|
||||
@@ -217,15 +212,10 @@ bool ChatHandler::HandleDebugSendOpcodeCommand(const char* /*args*/)
|
||||
}
|
||||
else if(type == "goguid")
|
||||
{
|
||||
uint32 lowguid;
|
||||
ifs >> lowguid;
|
||||
GameObject *obj = NULL;
|
||||
if (GameObjectData const* go_data = objmgr.GetGOData(lowguid))
|
||||
obj = GetObjectGlobalyWithGuidOrNearWithDbGuid(lowguid,go_data->id);
|
||||
|
||||
GameObject *obj = GetNearbyGameObject();
|
||||
if(!obj)
|
||||
{
|
||||
PSendSysMessage(LANG_COMMAND_OBJNOTFOUND, lowguid);
|
||||
PSendSysMessage(LANG_COMMAND_OBJNOTFOUND, 0);
|
||||
SetSentErrorMessage(true);
|
||||
ifs.close();
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user