UISetting.ts 559 B

1234567891011121314151617181920212223242526
  1. import { GameMng } from "../GameMng";
  2. import { UIButton } from "./UIButton";
  3. import GBaseUI from "./GBaseUI";
  4. import { UIManager } from "./UIManager";
  5. import { _decorator,Node } from "cc";
  6. const {ccclass, property} = _decorator;
  7. @ccclass
  8. export default class UISetting extends GBaseUI {
  9. @property(Node)
  10. btnClose: Node = null;
  11. static Show(parent?:any){
  12. UIManager.AddPrefab(GameMng.Instance.uisetting,parent);
  13. }
  14. start () {
  15. UIButton.BindClick(this.btnClose,()=>{
  16. this.closeUI();
  17. },this);
  18. }
  19. }