48 lines
1.4 KiB
TypeScript
48 lines
1.4 KiB
TypeScript
import { Facade } from "./PureMVC";
|
|
import { RemoveMVC_CMD } from "./RemoveMVC_CMD";
|
|
|
|
export default class GameFacade extends Facade {
|
|
static NAME:string = "GameFacade";
|
|
constructor() {
|
|
super();
|
|
}
|
|
|
|
initializeFacade() {
|
|
super.initializeFacade();
|
|
}
|
|
|
|
initializeModel() {
|
|
super.initializeModel();
|
|
/* this.registerProxy(new PokerModel());
|
|
this.registerProxy(new DdzGameModel()); */
|
|
}
|
|
|
|
initializeController() {
|
|
super.initializeController();
|
|
this.registerCommand(RemoveMVC_CMD.NAME, RemoveMVC_CMD);
|
|
/* this.registerCommand(BackInGameCMD.NAME, BackInGameCMD); */
|
|
|
|
}
|
|
|
|
initializeView() {
|
|
super.initializeView();
|
|
/* this.registerMediator(new OutPokerListMediator(DdzFacade.sRootView.getComponent(DdzGameScene).outPokerListArr));
|
|
this.registerMediator(new HandPokerListMediator(DdzFacade.sRootView.getComponent(DdzGameScene).handPokerList));
|
|
this.registerMediator(new RevealPokerListMediator(DdzFacade.sRootView.getComponent(DdzGameScene).revealPokerListArr));
|
|
this.registerMediator(new DdzGameMediator(DdzFacade.sRootView)); */
|
|
}
|
|
|
|
|
|
// static sRootView: cc.Node;
|
|
static init(view: cc.Node = null) {
|
|
if (!Facade.instance) {
|
|
// this.sRootView = view;
|
|
Facade.instance = new GameFacade();
|
|
}
|
|
}
|
|
|
|
static get ins(): GameFacade {
|
|
return <GameFacade>GameFacade.getInstance();
|
|
}
|
|
|
|
} |