抽卡:添加抽卡接口

This commit is contained in:
luying
2021-04-23 15:46:04 +08:00
parent 1f6839cafb
commit beadccf778
23 changed files with 591 additions and 85 deletions

View File

@@ -330,12 +330,6 @@ export function getExpeditionById(id: number) {
return expeditionInfo.get(id);
}
export function getRandExpedition(cnt = 1) {
const file = 'dic_expedition';
const data = gamedata['jsons'][file] || [];
return getRandEelm(data, cnt);
}
export function getComBtlSetByQuality(quality: number) {
return comBtlInfo.get(quality);
}
@@ -366,7 +360,7 @@ export function getBossHpByWarId(warId: number) {
let { attribute, dataId, relation, actorId } = hero;
if (relation === 2) {
let attriData = decodeIdCntArrayStr(attribute, 1);
const hp = parseInt(attriData.get('1'));
const hp = attriData.get('1');
if (hp > 0) {
bossHpArr.push({dataId, hp, actorId});
bossHpSum += hp;
@@ -385,7 +379,7 @@ export function getWarIdByBlueprtId(blueprtId: number) {
if (!warId) {
const { specialAttr } = getGoodById(blueprtId);
const attrData = decodeIdCntArrayStr(specialAttr, 1);
warId = parseInt(attrData.get('1'));
warId = attrData.get('1');
blueprtToWar.set(blueprtId, warId);
}
return warId;