炼器堂

This commit is contained in:
mamengke01
2021-01-26 16:50:14 +08:00
parent d8cc01f036
commit fb56dd00ec
19 changed files with 338 additions and 60 deletions

View File

@@ -4,6 +4,7 @@ import { RoleModel } from "../db/Role";
import { resResult } from "../pubUtils/util";
import { STATUS, FUNC_OPT_TYPE } from "../consts";
import { eventOnPlayerLvUp } from '../services/playerEventService';
import { checkesetTrain } from '../services/guildTrainService';
// 开启功能
export async function switchOnFunc(roleId: string, type: number, param: number, session: (BackendSession|FrontendSession)) {
@@ -33,4 +34,5 @@ export async function switchOnFunc(roleId: string, type: number, param: number,
export async function chackFunOpenWhenLogin(role: any, session: BackendSession|FrontendSession) {
await switchOnFunc(role.roleId, FUNC_OPT_TYPE.LEVEL_UP, role.lv, session);
await checkesetTrain(role.roleId, role.serverId);
}