军团活动:诸侯混战城门血量
This commit is contained in:
+4
-4
@@ -37,7 +37,7 @@ export class CeAttrDataRole {
|
||||
}
|
||||
}
|
||||
|
||||
class TopHero {
|
||||
export class TopHero {
|
||||
@prop({ required: true })
|
||||
hid: number; // 武将id
|
||||
@prop({ required: true })
|
||||
@@ -696,12 +696,12 @@ export default class Role extends BaseModel {
|
||||
}
|
||||
|
||||
// 获取战力在中位数的玩家
|
||||
public static async getMedianRole(serverId: number) {
|
||||
public static async getActivePlayers(serverId: number) {
|
||||
let yesterday = <Date>getTimeFunD().getBeforeDayWithHour(1);
|
||||
const roles: RoleType[] = await RoleModel.find({ serverId, updatedAt: { $gte: yesterday } })
|
||||
.select('topLineup')
|
||||
.select('topLineup topLineupCe')
|
||||
.sort({ ce: -1 }).lean();
|
||||
return roles[Math.floor(roles.length / 2)]
|
||||
return roles
|
||||
}
|
||||
|
||||
public static async receiveRankReward(roleId: string, ids: number[]) {
|
||||
|
||||
Reference in New Issue
Block a user