Exemplo n.º 1
0
    public override void execute()
    {
        Transformable obj = mReceiver as Transformable;
        TransformableComponentScalePath component = obj.getComponent(out component);

        // 停止其他移动组件
        obj.breakComponent <IComponentModifyScale>(component.GetType());
        component.setTremblingCallback(mDoingCallBack);
        component.setTrembleDoneCallback(mDoneCallBack);
        component.setActive(true);
        component.setValueKeyFrame(mValueKeyFrame);
        component.setSpeed(mSpeed);
        component.setValueOffset(mValueOffset);
        component.setOffsetBlendAdd(false);
        component.play(mLoop, mOffset, mFullOnce);
    }
Exemplo n.º 2
0
    public override void execute()
    {
        Transformable obj = mReceiver as Transformable;
        TransformableComponentScalePath component = obj.getComponent(out component);

        // 停止其他移动组件
        obj.breakComponent <IComponentModifyScale>(component.GetType());
        component.setTremblingCallback(mDoingCallBack);
        component.setTrembleDoneCallback(mDoneCallBack);
        component.setActive(true);
        component.setValueKeyFrame(mValueKeyFrame);
        component.setSpeed(mSpeed);
        component.setValueOffset(mValueOffset);
        component.setOffsetBlendAdd(false);
        component.play(mLoop, mOffset, mFullOnce);
        if (component.getState() == PLAY_STATE.PS_PLAY)
        {
            // 需要启用组件更新时,则开启组件拥有者的更新,后续也不会再关闭
            obj.setEnable(true);
        }
    }