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AErB;QADC,QAAQ;iDACY;IAGrB;QADC,QAAQ;qDACgB;IAVR,WAAW;QAD/B,OAAO;OACa,WAAW,CAqC/B;IAAD,kBAAC;KAAA;kBArCoB,WAAW","file":"","sourceRoot":"/","sourcesContent":["\nconst { ccclass, property } = cc._decorator;\n\n@ccclass\nexport default class ScaleAction extends cc.Component {\n\n @property\n speed: number = 1;\n @property\n scaleMax: number = 2;\n @property\n scaleMin: number = 0;\n\n @property\n defalutScale: number = 1;\n\n private readonly _baseTime: number = 1;\n\n onLoad() { }\n\n start() {\n\n }\n\n onEnable() {\n this.node.scale = this.defalutScale;\n let actTime: number = this._baseTime / this.speed;\n let maxAct = cc.scaleTo(actTime, this.scaleMax);\n let minAct = cc.scaleTo(actTime, this.scaleMin);\n this.node.stopAllActions();\n this.node.runAction(cc.repeatForever(cc.sequence(maxAct, minAct)));\n }\n\n onDisable() {\n this.node.stopAllActions();\n this.node.scale = 1;\n }\n\n\n\n update(dt) { }\n}\n"]}