Compare commits

...

1 Commits

Author SHA1 Message Date
aleos
60cff8aa0c Fixes an issue with weapon swapping and statuses
* Resolves statuses ending early when swapping weapons of the same type.
* Removes a duplicate check.
Thanks to @Aristeus09!
2022-09-27 11:24:12 -04:00

View File

@ -11720,8 +11720,6 @@ static void pc_unequipitem_sub(struct map_session_data *sd, int n, int flag) {
pc_deleteautobonus( sd->autobonus3, sd->inventory.u.items_inventory[n].equip ); pc_deleteautobonus( sd->autobonus3, sd->inventory.u.items_inventory[n].equip );
sd->inventory.u.items_inventory[n].equip = 0; sd->inventory.u.items_inventory[n].equip = 0;
if (!(flag & 4))
pc_checkallowskill(sd);
iflag = sd->npc_item_flag; iflag = sd->npc_item_flag;
// Check for combos (MUST be before status_calc_pc) // Check for combos (MUST be before status_calc_pc)
@ -11751,6 +11749,7 @@ static void pc_unequipitem_sub(struct map_session_data *sd, int n, int flag) {
} }
if (flag & 1 || status_calc) { if (flag & 1 || status_calc) {
if (!(flag & 4))
pc_checkallowskill(sd); pc_checkallowskill(sd);
status_calc_pc(sd, SCO_FORCE); status_calc_pc(sd, SCO_FORCE);
} }