示例#1
0
    private void moveTarget(Vector3 dest)
    {
        SpringPosition sp = SpringPosition.Begin(target.gameObject, dest, 5f);

        sp.ignoreTimeScale = true;
        sp.worldSpace      = false;
        DragXPostion xData = new DragXPostion();

        xData.moved = true;
        xData.x     = dest.x;
        target.SendMessage(x_postion_notify_name, xData, SendMessageOptions.DontRequireReceiver);
    }
示例#2
0
    private void stopTarget()
    {
        SpringPosition sp = target.GetComponent <SpringPosition>();

        if (sp != null)
        {
            sp.enabled = false;
        }
        DragXPostion xData = new DragXPostion();

        xData.moved = false;
        target.SendMessage(x_postion_notify_name, xData, SendMessageOptions.DontRequireReceiver);
    }
示例#3
0
 // page Start LastMoveX
 void OnDragLastMoveX(DragXPostion xData)
 {
     moveStart    = xData.moved;
     lastPostionX = xData.x;
 }