GameAnimation.ts 375 B

1234567891011121314
  1. import { GameLogicMgr } from "./logic";
  2. import { GameLogic } from "./GameLogic";
  3. export class GameAnimation extends cc.Animation {
  4. protected update(dt: number): void {
  5. if(GameLogicMgr.inst.isGamePause) {
  6. if(this.enabled) this.enabled = false;
  7. }
  8. else{
  9. if(!this.enabled) this.enabled = true;
  10. }
  11. }
  12. }