mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-27 14:57:44 +00:00
Merge pull request #851 from Skyliegirl33/ThreePointThree
[3.3] Fix spawn issues, players being invisible, battle state not being removed
This commit is contained in:
commit
11a1b46664
4 changed files with 9 additions and 6 deletions
|
@ -722,8 +722,8 @@ namespace Sapphire::Network::Packets::WorldPackets::Server
|
||||||
uint16_t MpMax;
|
uint16_t MpMax;
|
||||||
uint16_t NormalAI;
|
uint16_t NormalAI;
|
||||||
uint8_t OnlineStatus;
|
uint8_t OnlineStatus;
|
||||||
uint8_t __padding1;
|
|
||||||
uint8_t PermissionInvisibility;
|
uint8_t PermissionInvisibility;
|
||||||
|
uint8_t PermissionInvisibility1; // makes player invisible too
|
||||||
uint8_t FirstAttackType;
|
uint8_t FirstAttackType;
|
||||||
uint64_t FirstAttackId;
|
uint64_t FirstAttackId;
|
||||||
uint8_t LinkReply;
|
uint8_t LinkReply;
|
||||||
|
@ -733,10 +733,10 @@ namespace Sapphire::Network::Packets::WorldPackets::Server
|
||||||
uint8_t LinkFamily;
|
uint8_t LinkFamily;
|
||||||
uint8_t LinkParent;
|
uint8_t LinkParent;
|
||||||
uint8_t PoseEmote;
|
uint8_t PoseEmote;
|
||||||
uint8_t __padding2;
|
uint8_t __padding1;
|
||||||
uint16_t Flag;
|
uint16_t Flag;
|
||||||
|
uint8_t __padding2;
|
||||||
uint8_t __padding3;
|
uint8_t __padding3;
|
||||||
uint8_t __padding4;
|
|
||||||
Common::StatusWork Status[30];
|
Common::StatusWork Status[30];
|
||||||
MountStruct Mount;
|
MountStruct Mount;
|
||||||
uint8_t Name[32];
|
uint8_t Name[32];
|
||||||
|
@ -744,7 +744,7 @@ namespace Sapphire::Network::Packets::WorldPackets::Server
|
||||||
uint32_t Equipment[10];
|
uint32_t Equipment[10];
|
||||||
float Pos[3];
|
float Pos[3];
|
||||||
uint8_t FreeCompanyTag[6];
|
uint8_t FreeCompanyTag[6];
|
||||||
uint8_t PartsState[4];
|
uint8_t PartsState[3];
|
||||||
uint8_t State[3];
|
uint8_t State[3];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1282,14 +1282,14 @@ const std::map< uint32_t, uint8_t >& Player::getActorIdToHateSlotMap()
|
||||||
void Player::onMobAggro( const BNpc& bnpc )
|
void Player::onMobAggro( const BNpc& bnpc )
|
||||||
{
|
{
|
||||||
hateListAdd( bnpc );
|
hateListAdd( bnpc );
|
||||||
queuePacket( makeActorControl( getId(), SetBattle, 1 ) );
|
queuePacket( makeActorControl( getId(), SetBattle, 1, 0, 0 ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
void Player::onMobDeaggro( const BNpc& bnpc )
|
void Player::onMobDeaggro( const BNpc& bnpc )
|
||||||
{
|
{
|
||||||
hateListRemove( bnpc );
|
hateListRemove( bnpc );
|
||||||
if( m_actorIdTohateSlotMap.empty() )
|
if( m_actorIdTohateSlotMap.empty() )
|
||||||
queuePacket( makeActorControl( getId(), SetBattle ) );
|
queuePacket( makeActorControl( getId(), SetBattle, 0, 0, 0 ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Player::isLogin() const
|
bool Player::isLogin() const
|
||||||
|
|
|
@ -81,6 +81,8 @@ void WarpMgr::finishWarp( Entity::Player& player )
|
||||||
auto zoneInPacket = makeActorControlSelf( player.getId(), Appear, warpType, 0, 0, 0 );
|
auto zoneInPacket = makeActorControlSelf( player.getId(), Appear, warpType, 0, 0, 0 );
|
||||||
auto SetStatusPacket = makeActorControl( player.getId(), SetStatus, static_cast< uint8_t >( Common::ActorStatus::Idle ) );
|
auto SetStatusPacket = makeActorControl( player.getId(), SetStatus, static_cast< uint8_t >( Common::ActorStatus::Idle ) );
|
||||||
|
|
||||||
|
player.setZoningType( Common::ZoneingType::None );
|
||||||
|
|
||||||
if( !player.getGmInvis() )
|
if( !player.getGmInvis() )
|
||||||
player.sendToInRangeSet( zoneInPacket );
|
player.sendToInRangeSet( zoneInPacket );
|
||||||
|
|
||||||
|
|
|
@ -85,6 +85,7 @@ namespace Sapphire::Network::Packets::WorldPackets::Server
|
||||||
|
|
||||||
m_data.OnlineStatus = static_cast< uint8_t >( player.getOnlineStatus() );
|
m_data.OnlineStatus = static_cast< uint8_t >( player.getOnlineStatus() );
|
||||||
m_data.PermissionInvisibility = 0;
|
m_data.PermissionInvisibility = 0;
|
||||||
|
m_data.PermissionInvisibility1 = 0;
|
||||||
|
|
||||||
m_data.GrandCompany = player.getGc();
|
m_data.GrandCompany = player.getGc();
|
||||||
if( m_data.GrandCompany > 0 )
|
if( m_data.GrandCompany > 0 )
|
||||||
|
|
Loading…
Add table
Reference in a new issue