import { _decorator, AnimationClip, Component, Node, Animation } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('PopupScaler')
export class PopupScaler extends Component 
{
    @property({type: Animation})
    m_AnimComp: Animation;

    @property({type: AnimationClip})
    m_ScaleInClip: AnimationClip;

    @property({type: AnimationClip})
    m_ScaleOutClip: AnimationClip;
    
    public PlayScaleIn(): void
    {
        this.m_AnimComp.play(this.m_ScaleInClip.name);
    }
    
    public PlayScaleOut(): void 
    {
        this.m_AnimComp.play(this.m_ScaleOutClip.name);
    }
}

