Begin() static public method

Start the tweening operation.
static public Begin ( GameObject go, float duration, float to ) : TweenOrthoSize,
go GameObject
duration float
to float
return TweenOrthoSize,
Beispiel #1
0
    void OnMapBackgroundScrolled(GameObject go, float delta)
    {
        UIStretch theStretch = background.GetComponent <UIStretch>();

        if (delta > 0)
        {
            if (zoomLevel > -numZoomLevels && !isZooming)
            {
                zoomLevel--;
                isZooming = true;
                float          orthoSize = Mathf.Pow(zoomFactor, zoomLevel);
                TweenOrthoSize tos       = TweenOrthoSize.Begin(UICamera.currentCamera.gameObject, zoomSpeed, orthoSize);
                theStretch.relativeSize.x = orthoSize;
                theStretch.relativeSize.y = orthoSize;
                tos.callWhenFinished      = "endZooming";
                tos.eventReceiver         = this.gameObject;
            }
        }
        else
        {
            if (zoomLevel < numZoomLevels && !isZooming)
            {
                zoomLevel++;
                isZooming = true;
                float          orthoSize = Mathf.Pow(zoomFactor, zoomLevel);
                TweenOrthoSize tos       = TweenOrthoSize.Begin(UICamera.currentCamera.gameObject, zoomSpeed, orthoSize);
                tos.callWhenFinished = "endZoomUpdateBackground";
                tos.eventReceiver    = this.gameObject;
            }
        }
    }
 static public int Begin_s(IntPtr l)
 {
     try {
         UnityEngine.GameObject a1;
         checkType(l, 1, out a1);
         System.Single a2;
         checkType(l, 2, out a2);
         System.Single a3;
         checkType(l, 3, out a3);
         var ret = TweenOrthoSize.Begin(a1, a2, a3);
         pushValue(l, true);
         pushValue(l, ret);
         return(2);
     }
     catch (Exception e) {
         return(error(l, e));
     }
 }
Beispiel #3
0
 public unsafe static long $Invoke0(long instance, long *args)
 {
     return(GCHandledObjects.ObjectToGCHandle(TweenOrthoSize.Begin((GameObject)GCHandledObjects.GCHandleToObject(*args), *(float *)(args + 1), *(float *)(args + 2))));
 }