提交上阵

This commit is contained in:
PC-20230316NUNE\Administrator
2023-11-15 18:38:00 +08:00
parent d1783204ad
commit 391ce959cb
38 changed files with 3875 additions and 121 deletions

View File

@@ -6,6 +6,7 @@ import { Node } from "cc";
import { instantiate } from "cc";
import { app } from "../App";
import { JNFrameInfo, JNSyncFrameEvent } from "../../../extensions/ngame/assets/ngame/sync/frame/JNSyncFrame";
import { CCObject } from "cc";
export enum BattleMode{
//无尽模式
@@ -60,8 +61,6 @@ export default class GBattleModeManager extends Singleton {
//打开指定模式
async Open(mode:BattleMode,isAuto:boolean = false){
await this.Close();
this.current = mode;
this.setAuto(isAuto);
@@ -75,7 +74,6 @@ export default class GBattleModeManager extends Singleton {
//主动调用场景销毁
app.sync.onReset();
this.clear();
this.current = null;
}
@@ -94,6 +92,7 @@ export default class GBattleModeManager extends Singleton {
//创建当前模式
private create(){
if(!this.isInit || this.current == null) return;
let mode = instantiate(this.modes[this.current]);
mode.getComponent(GBaseMode).camera = this.camera;