装备:淬火

This commit is contained in:
luying
2021-07-29 14:21:51 +08:00
parent dc832da60a
commit 972abb7d07
19 changed files with 805 additions and 68 deletions
+2 -2
View File
@@ -196,7 +196,7 @@ export async function addItems(roleId: string, roleName: string, sid: string, go
return showItems;
}
function sortItems(goods: Array<ItemInter>, bags: Array<BagInter>, skins: Array<number>, figures: Array<number>, currencysMap: any, equips: Array<EquipInter>, showItems: Array<ItemInter>) {
function sortItems(goods: Array<ItemInter>, bags: Array<BagInter>, skins: Array<number>, figures: Array<number>, currencysMap: any, equips: EquipInter[], showItems: Array<ItemInter>) {
for (let good of goods) {
let goodInfo = gameData.goods.get(good.id);
// 道具不存在时先跳过
@@ -208,7 +208,7 @@ function sortItems(goods: Array<ItemInter>, bags: Array<BagInter>, skins: Array<
let { type, table, isCurrency } = ITID.get(goodInfo.itid);
if (table == ITEM_TABLE.EQUIP) {
for (let i = 0; i < good.count; i++) {
equips.push({ id: good.id, ...goodInfo });
equips.push({ id: good.id });
}
} else if (table == ITEM_TABLE.ITEM) {