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

fix crash on HW+ skills related; aligned action struct a tiny bit more;

This commit is contained in:
Alice Ogeda 2025-01-03 05:08:22 -03:00
parent f2805e951c
commit 62fa2a4a04
2 changed files with 6 additions and 4 deletions

View file

@ -391,10 +391,10 @@ namespace Excel
uint8_t EffectWidth;
uint8_t CostType;
uint8_t Cond;
uint8_t Element;
uint8_t ProcStatus;
uint8_t ClassJobCategory;
uint8_t RecastGroup;
uint8_t ProcStatus;
uint8_t Unknown1; // todo: possibly cost type? tp etc?
uint8_t ClassJobCategory; // recastgroup
uint8_t Init;
uint8_t Omen;
uint8_t Learn;

View file

@ -346,6 +346,8 @@ void PlayerMgr::onGainExp( Entity::Player& player, uint32_t exp )
{
uint32_t currentExp = player.getCurrentExp();
uint16_t level = player.getLevel();
uint32_t expGained = exp;
auto currentClass = static_cast< uint8_t >( player.getClass() );
if( level >= Common::MAX_PLAYER_LEVEL )
@ -377,7 +379,7 @@ void PlayerMgr::onGainExp( Entity::Player& player, uint32_t exp )
else
player.setCurrentExp( currentExp + exp );
Network::Util::Packet::sendActorControlSelf( player, player.getId(), GainExpMsg, currentClass, exp );
Network::Util::Packet::sendActorControlSelf( player, player.getId(), GainExpMsg, currentClass, expGained );
Network::Util::Packet::sendActorControlSelf( player, player.getId(), UpdateUiExp, currentClass, player.getCurrentExp() );
}