Game_InitLoad_Flow.ts 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. import BasicTreeBehaviorNode from "../../Engine/Basic/BasicTreeBehaviorNode";
  2. import EventManager from "../../Engine/Event/EventManager";
  3. import Tool from "../../Engine/Tool/Tool";
  4. import GameEventName from "../Event/GameEventName";
  5. import ExplainView from "../Game/View/ExplainView/ExplainView";
  6. import InitLoadView from "../View/InitLoadView/InitLoadView";
  7. /**
  8. * 启动控制节点 - 逻辑层
  9. */
  10. export default class Game_InitLoad_Flow extends BasicTreeBehaviorNode {
  11. public _enter (...args: any): void {
  12. EventManager.sendEvent(GameEventName.View.View_DestroyView, null);
  13. EventManager.sendEvent(GameEventName.View.View_ShowView, InitLoadView);
  14. }
  15. protected _leave (): void {
  16. Tool.log("正式进入游戏");
  17. EventManager.sendEvent(GameEventName.View.View_ShowView, ExplainView);
  18. // EventManager.sendEvent(GameEventName.View.View_DestroyView, InitLoadView);
  19. }
  20. protected _enterFail (): void {
  21. }
  22. protected _enterAgain (): void {
  23. }
  24. }