1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-04-26 22:37:45 +00:00

Merge remote-tracking branch 'upstream/develop' into develop

This commit is contained in:
NotAdam 2018-07-08 19:45:37 +10:00
commit ae895ccfc0
9 changed files with 29 additions and 27 deletions

View file

@ -203,7 +203,7 @@ namespace Common {
Walking = 0x02,
Strafing = 0x04,
Jumping = 0x10,
BackWalk = Walking | Strafing,
BackWalk = 0x06,
};
enum MoveState : uint8_t

View file

@ -10,6 +10,7 @@
#include <boost/make_shared.hpp>
#include <string.h>
#include <memory>
#include <Util/Util.h>
#include "CommonNetwork.h"
#include "PacketDef/Ipcs.h"
@ -238,6 +239,7 @@ protected:
// The IPC type itself.
m_ipcHdr.type = static_cast< ServerZoneIpcType >( m_data._ServerIpcType );
m_ipcHdr.timestamp = Util::getTimeSeconds();
m_segHdr.size = sizeof( T ) + sizeof( FFXIVARR_IPC_HEADER ) + sizeof( FFXIVARR_PACKET_SEGMENT_HEADER );
};

View file

@ -91,7 +91,7 @@ struct FFXIVIpcCharList : FFXIVIpcBasePacket<LobbyCharList>
char nameChara[32];
char nameServer[32];
char nameServer1[32];
char charDetailJson[1030];
char charDetailJson[1028];
} charaDetails[2];
};

View file

@ -624,18 +624,20 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket<InitUI>
unsigned short pvpWolfFoldWeeklyMatches;
unsigned short pvpWolfFoldWeeklyVictories;
unsigned short pvpStats[6];
unsigned short playerCommendations;
unsigned short unknown74;
unsigned short pvpStats1;
unsigned char frontlineCampaigns[4];
unsigned short frontlineCampaignsWeekly;
unsigned char currentRelic;
unsigned char currentBook;
unsigned char masterCrafterMask;
unsigned char unknown69;
unsigned char unknown6A;
unsigned char unknown6B;
unsigned char unknown6C[4];
unsigned char unknown70[34];
unsigned char unknown81;
unsigned char unknown82;
unsigned char unknown83;
unsigned char unknown84[4];
unsigned char unknown88[10];
unsigned short playerCommendations;
unsigned char unknown94[22];
unsigned short unknown18;
unsigned char maxLevel;
unsigned char expansion;

View file

@ -191,7 +191,6 @@ void Core::Network::GameConnection::getCharList( FFXIVARR_PACKET_RAW& packet, ui
charListPacket->data().counter = ( i * 4 ) + 1;
charListPacket->data().unknown4 = 128;
}
Packets::LobbyPacketContainer pRP( m_encKey );
pRP.addPacket( charListPacket );
sendPacket( pRP );

View file

@ -34,7 +34,8 @@ using namespace Core::Network::Packets::Server;
using namespace Core::Network::ActorControl;
Core::Entity::Chara::Chara( ObjKind type ) :
Actor( type )
Actor( type ),
m_targetId( INVALID_GAME_OBJECT_ID )
{
// initialize the free slot queue
for( uint8_t i = 0; i < MAX_STATUS_EFFECTS; i++ )

View file

@ -68,8 +68,7 @@ Core::Entity::Player::Player() :
m_markedForRemoval( false ),
m_mount( 0 ),
m_directorInitialized( false ),
m_onEnterEventDone( false ),
m_bJumping( false )
m_onEnterEventDone( false )
{
m_id = 0;
m_currentStance = Stance::Passive;

View file

@ -595,13 +595,10 @@ public:
/*! checks if a spawn index is valid */
bool isObjSpawnIndexValid( uint8_t index );
uint64_t m_lastMoveTime;
uint8_t m_lastMoveflag;
bool m_bJumping;
private:
uint32_t m_lastWrite;
uint32_t m_lastPing;

View file

@ -190,13 +190,21 @@ void Core::Network::GameConnection::updatePositionHandler( const Core::Network::
//pLog->debug( std::to_string( moveState ) + " -- moveState " );
//pLog->debug( std::to_string( moveType ) + " -- moveType " );
if( moveType & MoveType::Running )
{
unk1 = 0x7F;
unk2 = 0x00;
unk4 = 0x3C;
}
if( moveType & MoveType::Strafing )
{
unk2 = 0x40;
if( IPC_OP_019A.strafeRight == 1 )
unk1 = 0xbf;
else
unk1 = 0x5f;
unk1 = 0x7F;
//if( IPC_OP_019A.strafeRight == 1 )
// unk1 = 0xbf;
//else
// unk1 = 0x5f;
unk4 = 0x3C;
}
@ -205,22 +213,16 @@ void Core::Network::GameConnection::updatePositionHandler( const Core::Network::
unk1 = 0x7F;
unk2 = 0x02;
unk3 = 0x00;
unk4 = 0x0518;
unk4 = 0x18;
}
if( moveType & MoveType::BackWalk )
if( moveType & MoveType::Walking && moveType & MoveType::Strafing )
{
unk2 = 0x06;
unk1 = 0xFF;
unk4 = 0x18;
}
if( moveType & MoveType::Running )
{
unk1 = 0x7F;
unk4 = 0x3C;
}
if( moveType & MoveType::Jumping )
{