FullOutputMediator.ts 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. import { _decorator, Component, Node } from 'cc';
  2. import { GUIManager } from '../../../engines/gui/GUIManager';
  3. import { GUIMediator } from '../../../engines/gui/GUIMediator';
  4. import { SceneManager } from '../../../engines/scenes/SceneManager';
  5. import { PlatformManager } from '../../../Platform/PlatformManager';
  6. import { UIConst } from '../UIConst';
  7. const { ccclass, property } = _decorator;
  8. @ccclass('FullOutputMediator')
  9. export class FullOutputMediator extends GUIMediator {
  10. start () {
  11. // Your initialization goes here.
  12. }
  13. OnShow(data?:any):void{
  14. PlatformManager.hideBanner();
  15. this.data=data;
  16. }
  17. OnHide():void{
  18. }
  19. /**
  20. * 返回主界面
  21. */
  22. BackToMain():void{
  23. SceneManager.single.Swicth("PrepareScene");
  24. this.HideSelf();
  25. }
  26. ContinueGame():void{
  27. GUIManager.single.Show(UIConst.FIGHTING_UI);
  28. this.HideSelf();
  29. }
  30. // update (deltaTime: number) {
  31. // // Your update function goes here.
  32. // }
  33. }