瀏覽代碼

Fixed duplicated skill status check when switching weapons (#4806)

* Thanks to @aleos89
Daegaladh 5 年之前
父節點
當前提交
058ad2c67e
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      src/map/pc.cpp

+ 2 - 1
src/map/pc.cpp

@@ -10551,7 +10551,8 @@ static void pc_unequipitem_sub(struct map_session_data *sd, int n, int flag) {
 		sd->state.autobonus &= ~sd->inventory.u.items_inventory[n].equip; //Check for activated autobonus [Inkfish]
 		sd->state.autobonus &= ~sd->inventory.u.items_inventory[n].equip; //Check for activated autobonus [Inkfish]
 
 
 	sd->inventory.u.items_inventory[n].equip = 0;
 	sd->inventory.u.items_inventory[n].equip = 0;
-	pc_checkallowskill(sd);
+	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) */