1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-04-23 13:17:45 +00:00

Merge pull request #344 from NotAdam/develop

fixed inter-instance gm calling
This commit is contained in:
Mordred 2018-07-10 12:26:05 +02:00 committed by GitHub
commit ae38f300e0

View file

@ -551,8 +551,14 @@ void Core::Network::GameConnection::gm2Handler( const Packets::FFXIVARR_PACKET_R
}
case GmCommand::Call:
{
if( targetPlayer->getZoneId() != player.getZoneId() )
targetPlayer->setZone( player.getZoneId() );
// We shouldn't be able to call a player into an instance, only call them out of one
if( player.getCurrentInstance() )
{
player.sendUrgent( "You are unable to call a player while bound to a battle instance." );
return;
}
targetPlayer->setInstance( player.getCurrentZone() );
targetPlayer->changePosition( player.getPos().x, player.getPos().y, player.getPos().z, player.getRot() );
player.sendNotice( "Calling " + targetPlayer->getName() );