AlertToBeContinueImpl.ts
1.04 KB
import { DummyNode } from "../../../../common/CCDummyObjects";
import { UIManager } from "../../../../common/gameplay/managers/UIManager";
import { AnimationUtils } from "../../../../common/utils/AnimationUtils";
import { GameConfig } from "../../../../GameConfig";
import { GameModelManager } from "../../../model/GameModelManager";
const { ccclass, property } = cc._decorator
@ccclass
export class AlertToBeContinueImpl extends cc.Component {
@property(cc.Node)
momentNode: cc.Node = DummyNode;
//#region editor bindings
closeAction() {
// this.node.destroy();
AnimationUtils.hideUIAnim(this.node, this.node.getChildByName("mainNode"), {
callback: () => {
this.node.destroy();
}
}, this.node.getChildByName("BG"))
GameModelManager.checkAutoPopView();
}
//#endregion
}
export async function showToBeContinue() {
if (!GameConfig.showToBeContinue) {
GameConfig.showToBeContinue = true;
await UIManager.showAlert("prefab/ui/ToBeContinue");
}
}