mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-05-01 16:37:45 +00:00
huhuhu
This commit is contained in:
parent
530cf8a37a
commit
bea3cae216
1 changed files with 7 additions and 13 deletions
|
@ -770,17 +770,14 @@ void Core::DebugCommandHandler::instance( char* data, Entity::Player &player, bo
|
||||||
}
|
}
|
||||||
else if( subCommand == "objupdate" )
|
else if( subCommand == "objupdate" )
|
||||||
{
|
{
|
||||||
uint32_t instanceId;
|
|
||||||
uint32_t objId;
|
uint32_t objId;
|
||||||
|
|
||||||
sscanf( params.c_str(), "%d %d", &instanceId, &objId );
|
sscanf( params.c_str(), "%d", &objId );
|
||||||
|
|
||||||
auto pInstance = g_territoryMgr.getInstanceZonePtr( instanceId );
|
auto instance = boost::dynamic_pointer_cast< InstanceContent >( player.getCurrentZone() );
|
||||||
if( !pInstance )
|
if( !instance )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
auto instance = boost::dynamic_pointer_cast< InstanceContent >( pInstance );
|
|
||||||
|
|
||||||
auto obj = instance->getInstanceObject( objId );
|
auto obj = instance->getInstanceObject( objId );
|
||||||
if( !obj )
|
if( !obj )
|
||||||
return;
|
return;
|
||||||
|
@ -789,18 +786,15 @@ void Core::DebugCommandHandler::instance( char* data, Entity::Player &player, bo
|
||||||
}
|
}
|
||||||
else if( subCommand == "objstate" )
|
else if( subCommand == "objstate" )
|
||||||
{
|
{
|
||||||
uint32_t instanceId;
|
|
||||||
uint32_t objId;
|
uint32_t objId;
|
||||||
uint32_t state;
|
uint8_t state;
|
||||||
|
|
||||||
sscanf( params.c_str(), "%d %d %d", &instanceId, &objId, &state );
|
sscanf( params.c_str(), "%d %hhu", &objId, &state );
|
||||||
|
|
||||||
auto pInstance = g_territoryMgr.getInstanceZonePtr( instanceId );
|
auto instance = boost::dynamic_pointer_cast< InstanceContent >( player.getCurrentZone() );
|
||||||
if( !pInstance )
|
if( !instance )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
auto instance = boost::dynamic_pointer_cast< InstanceContent >( pInstance );
|
|
||||||
|
|
||||||
auto obj = instance->getInstanceObject( objId );
|
auto obj = instance->getInstanceObject( objId );
|
||||||
if( !obj )
|
if( !obj )
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Reference in a new issue