
/**
 * tips提示
 */
const {ccclass, property} = cc._decorator;

/**
 * 
 * <color=#FFFFFF>获得道具</c><color=#0fffff>服饰卡*1</color>：
 */
@ccclass
export default class Tips extends cc.Component {

    @property(cc.RichText)
    label: cc.RichText = null;

    start () {
        cc.tween(this.node).sequence(
            cc.delayTime(0.3),
            cc.spawn(
                cc.moveBy(2,cc.v2(0,60)).easing(cc.easeSineOut()),
                cc.fadeOut(2),
            ),
            cc.callFunc(()=>{
                this.node.destroy();
            })
        ).start()
    }

    public setLabel(str){
        this.label.string = str;
    }


}
