2017-08-08 13:53:47 +02:00
|
|
|
#ifndef _MODELEQUIPPACKET_H
|
|
|
|
#define _MODELEQUIPPACKET_H
|
|
|
|
|
2017-08-19 00:18:40 +02:00
|
|
|
#include <src/servers/Server_Common/Network/GamePacketNew.h>
|
2017-08-18 17:16:15 +02:00
|
|
|
#include "src/servers/Server_Zone/Actor/Player.h"
|
|
|
|
#include "src/servers/Server_Zone/Forwards.h"
|
2017-08-08 13:53:47 +02:00
|
|
|
|
|
|
|
namespace Core {
|
|
|
|
namespace Network {
|
|
|
|
namespace Packets {
|
|
|
|
namespace Server {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief The update model packet.
|
|
|
|
*/
|
|
|
|
class ModelEquipPacket :
|
2017-08-20 22:31:23 +02:00
|
|
|
public GamePacketNew< FFXIVIpcModelEquip, ServerZoneIpcType >
|
2017-08-08 13:53:47 +02:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
ModelEquipPacket( Entity::PlayerPtr player ) :
|
2017-08-20 22:31:23 +02:00
|
|
|
GamePacketNew< FFXIVIpcModelEquip, ServerZoneIpcType >( player->getId(), player->getId() )
|
2017-08-08 13:53:47 +02:00
|
|
|
{
|
|
|
|
initialize( player );
|
|
|
|
};
|
|
|
|
|
|
|
|
private:
|
|
|
|
void initialize( Entity::PlayerPtr player )
|
|
|
|
{
|
|
|
|
m_data.mainWeapon = player->getModelMainWeapon();
|
|
|
|
m_data.offWeapon = player->getModelSubWeapon();
|
|
|
|
m_data.models[0] = player->getModelForSlot( Inventory::EquipSlot::Head );
|
|
|
|
m_data.models[1] = player->getModelForSlot( Inventory::EquipSlot::Body );
|
|
|
|
m_data.models[2] = player->getModelForSlot( Inventory::EquipSlot::Hands );
|
|
|
|
m_data.models[3] = player->getModelForSlot( Inventory::EquipSlot::Legs );
|
|
|
|
m_data.models[4] = player->getModelForSlot( Inventory::EquipSlot::Feet );
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif /*_MODELEQUIPPACKET_H*/
|