✨ feat(共鸣系统): 添加最强6人推送,不可养成拦截
This commit is contained in:
@@ -3,6 +3,7 @@ import { ArtifactModelType } from "../../db/Artifact";
|
||||
import { AuthorBookType } from "../../db/AuthorBook";
|
||||
import { Connect, EPlace, HeroSkin, HeroType, HeroUpdate, Stone, Talent } from "../../db/Hero";
|
||||
import { JewelType } from "../../db/Jewel";
|
||||
import { ResonanceType } from "../../db/Resonance";
|
||||
import { RoleUpdate, Teraph } from "../../db/Role";
|
||||
import { AttrCell, Attribute, EquipAttr, HeroAttr, RoleCeType, SchoolAttr, ScrollAttr } from "../../db/RoleCe";
|
||||
import { TopHero } from "../../domain/dbGeneral";
|
||||
@@ -137,6 +138,23 @@ export class CalCe {
|
||||
return { topLineup, topLineupCe, hasTopCeChange: topLineupCe == this.originTopHeroCe };
|
||||
}
|
||||
|
||||
public getTopLineupNew(dbResonanceMap: Map<number, ResonanceType>) {
|
||||
let topLineup: TopHero[] = [], topLineupCe = 0;
|
||||
let arr = this.getResultCeArr();
|
||||
for (let obj of arr) {
|
||||
if (topLineup.length >= LINEUP_NUM) break;
|
||||
let { hid, ce } = obj;
|
||||
if (dbResonanceMap.has(hid)) continue;
|
||||
topLineup.push({
|
||||
hid, ce, hero: this.data.heroObjectId.get(hid)
|
||||
});
|
||||
topLineupCe += ce;
|
||||
}
|
||||
|
||||
return { topLineup, topLineupCe, hasTopCeChange: topLineupCe == this.originTopHeroCe };
|
||||
}
|
||||
|
||||
|
||||
// 玩家等级
|
||||
public setRoleLv(lv: number) {
|
||||
this.data.roleLv = lv;
|
||||
|
||||
Reference in New Issue
Block a user