mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-28 23:27:45 +00:00
Merge pull request #347 from NotAdam/develop
fix emotes that unholster weapons and sit animations work now
This commit is contained in:
commit
dedc81bc9d
5 changed files with 11 additions and 3 deletions
|
@ -1427,6 +1427,7 @@ Core::Data::Emote::Emote( uint32_t row_id, Core::Data::ExdDataGenerated* exdData
|
|||
emoteCategory = exdData->getField< uint8_t >( row, 11 );
|
||||
emoteMode = exdData->getField< uint8_t >( row, 12 );
|
||||
hasCancelEmote = exdData->getField< bool >( row, 15 );
|
||||
drawsWeapon = exdData->getField< bool >( row, 16 );
|
||||
textCommand = exdData->getField< int32_t >( row, 18 );
|
||||
icon = exdData->getField< uint16_t >( row, 19 );
|
||||
logMessageTargeted = exdData->getField< uint16_t >( row, 20 );
|
||||
|
|
|
@ -1605,6 +1605,7 @@ struct Emote
|
|||
uint16_t logMessageUntargeted;
|
||||
uint8_t emoteMode;
|
||||
bool hasCancelEmote;
|
||||
bool drawsWeapon;
|
||||
|
||||
Emote( uint32_t row_id, Core::Data::ExdDataGenerated* exdData );
|
||||
};
|
||||
|
|
|
@ -17,7 +17,7 @@ namespace Core {
|
|||
|
||||
enum ActorControlType : uint16_t
|
||||
{
|
||||
ToggleWeapon = 0x01,
|
||||
ToggleWeapon = 0x00,
|
||||
SetStatus = 0x02,
|
||||
CastStart = 0x03,
|
||||
ToggleAggro = 0x04,
|
||||
|
|
|
@ -257,7 +257,7 @@ void Core::Entity::Chara::setStance( Stance stance )
|
|||
{
|
||||
m_currentStance = stance;
|
||||
|
||||
FFXIVPacketBasePtr packet = boost::make_shared< ActorControlPacket142 >( m_id, ToggleAggro, stance, 1 );
|
||||
FFXIVPacketBasePtr packet = boost::make_shared< ActorControlPacket142 >( m_id, ToggleWeapon, stance, 0 );
|
||||
sendToInRangeSet( packet );
|
||||
}
|
||||
|
||||
|
|
|
@ -150,6 +150,8 @@ void Core::Network::GameConnection::clientTriggerHandler( const Packets::FFXIVAR
|
|||
if( !emoteData )
|
||||
return;
|
||||
|
||||
player.emote( emoteId, targetId, isSilent );
|
||||
|
||||
bool isPersistent = emoteData->emoteMode != 0;
|
||||
|
||||
if( isPersistent )
|
||||
|
@ -164,7 +166,11 @@ void Core::Network::GameConnection::clientTriggerHandler( const Packets::FFXIVAR
|
|||
static_cast< uint8_t >( Entity::Chara::ActorStatus::EmoteMode ), emoteData->hasCancelEmote ? 1 : 0 ), true );
|
||||
}
|
||||
|
||||
player.emote( emoteId, targetId, isSilent );
|
||||
if( emoteData->drawsWeapon )
|
||||
{
|
||||
player.setStance( Entity::Chara::Stance::Active );
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case ClientTriggerType::EmoteCancel: // emote
|
||||
|
|
Loading…
Add table
Reference in a new issue