"use strict";
var __reflect = (this && this.__reflect) || function (p, c, t) {
    p.__class__ = c, t ? t.push(c) : t = [c], p.__types__ = p.__types__ ? t.concat(p.__types__) : t;
};
var __extends = this && this.__extends || function __extends(t, e) { 
 function r() { 
 this.constructor = t;
}
for (var i in e) e.hasOwnProperty(i) && (t[i] = e[i]);
r.prototype = e.prototype, t.prototype = new r();
};
Object.defineProperty(exports, "__esModule", { value: true });
/**
 * 树叶动画
 */
var LeavesAni = (function (_super) {
    __extends(LeavesAni, _super);
    function LeavesAni() {
        var _this = _super.call(this) || this;
        _this.leafLeft = new egret.Bitmap(RES.getRes("leafLeft_png"));
        _this.leafLeft.x = 0;
        _this.leafLeft.y = 119;
        _this.leafLeft.alpha = 0;
        _this.addChild(_this.leafLeft);
        _this.leafRight = new egret.Bitmap(RES.getRes("leafRight_png"));
        _this.leafRight.x = 673;
        _this.leafRight.y = 141;
        _this.leafRight.alpha = 0;
        _this.addChild(_this.leafRight);
        return _this;
    }
    LeavesAni.prototype.play = function () {
        egret.Tween.get(this.leafLeft, { loop: true })
            .set({ x: 0, y: 119 })
            .to({ x: 82, y: 161 + 119 }, 2000);
        egret.Tween.get(this.leafLeft, { loop: true })
            .set({ rotation: 0, alpha: 0 })
            .to({ alpha: 1 }, 300)
            .wait(250)
            .to({ rotation: -58 }, 950)
            .to({ rotation: -90, alpha: 0 }, 500);
        egret.Tween.get(this.leafRight, { loop: true })
            .set({ x: 673, y: 141 })
            .to({ x: 642, y: 193 }, 2000);
        egret.Tween.get(this.leafRight, { loop: true })
            .set({ alpha: 0 })
            .to({ alpha: 1 }, 200)
            .wait(300)
            .to({ alpha: 0 }, 1500);
    };
    return LeavesAni;
}(egret.DisplayObjectContainer));
exports.LeavesAni = LeavesAni;
__reflect(LeavesAni.prototype, "\"/Users/zuopeng/DBGitLab/db-game-template/egret/src/panels/LeavesAni\".LeavesAni");
//# sourceMappingURL=LeavesAni.js.map