✨ feat(gvg): 概览
This commit is contained in:
@@ -84,7 +84,10 @@ export default class GVGTeam extends BaseModel {
|
||||
startMoveTime: number;
|
||||
|
||||
@prop({ required: true, default: 0 })
|
||||
stopMoveTime: number; // 移动冷却时间
|
||||
moveCdTime: number; // 移动冷却时间
|
||||
|
||||
@prop({ required: true, default: 0 })
|
||||
stopMoveTime: number; // 移动时间
|
||||
|
||||
@prop({ required: true, default: 0 })
|
||||
defenseTime: number; // 防守保护时间
|
||||
@@ -164,7 +167,7 @@ export default class GVGTeam extends BaseModel {
|
||||
|
||||
// 移动
|
||||
public static async startMove(teamCode: string, areaId: number, fromAreaId: number) {
|
||||
const res: GVGTeamType = await GVGTeamModel.findOneAndUpdate({ teamCode }, { $set: { areaId, fromAreaId, stopMoveTime: nowSeconds() + GVG.GVG_DEFAULT_MOVE_CD } }, { new: true }).lean();
|
||||
const res: GVGTeamType = await GVGTeamModel.findOneAndUpdate({ teamCode }, { $set: { areaId, fromAreaId, stopMoveTime: nowSeconds() + GVG.GVG_DEFAULT_MOVE_CD, moveCdTime: nowSeconds() + GVG.GVG_DEFAULT_MOVE_CD } }, { new: true }).lean();
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user