### ScaleFrom API Source: https://pixelplacement.com/itween/documentation Instantly changes a GameObject's scale then returns it to its starting scale over time. ```APIDOC ## ScaleFrom ### Description Instantly changes a GameObject's scale then returns it to its starting scale over time. ### Method - ScaleFrom(GameObject target, Vector3 scale, float time) - ScaleFrom(GameObject target, Hashtable args) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **name** (string) - Optional - An individual name useful for stopping iTweens by name. - **scale** (Transform or Vector3) - Required - The initial scale. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **time** (float or double) - Optional - The time in seconds the animation will take to complete. - **speed** (float or double) - Optional - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - Optional - The time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - Optional - For the shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - For the type of loop to apply once the animation has completed. - **onstart** (string) - Optional - For the name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Optional - For arguments to be sent to the "onstart" method. - **onupdate** (string) - Optional - For the name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Optional - For arguments to be sent to the "onupdate" method. - **oncomplete** (string) - Optional - For the name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Optional - For arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Optional - Setting this to true will allow the animation to continue independent of the current time. ### Request Example ```json { "target": "gameObject", "scale": {"x": 2, "y": 2, "z": 2}, "time": 1.0, "easetype": "easeInOutSine" } ``` ### Response #### Success Response (200) N/A - This is a procedural function call. #### Response Example N/A ``` -------------------------------- ### Init API Source: https://pixelplacement.com/itween/documentation Prepares a GameObject to prevent initial animation hiccups. It is recommended to run this on every object intended for iTween animations in its Start or Awake method. ```APIDOC ## Init ### Description Sets up a GameObject to avoid hiccups when an initial iTween is added. It's advisable to run this on every object you intend to run iTween on in its Start or Awake. ### Method POST (or equivalent for Unity methods) ### Endpoint N/A (Unity Component Method) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **target** (GameObject) - The GameObject to initialize for iTween. ### Request Example ```csharp iTween.Init(myGameObject); ``` ### Response #### Success Response (200) None (This is a Unity component method that performs an action) #### Response Example None ``` -------------------------------- ### MoveFrom Method Source: https://pixelplacement.com/itween/documentation Instantly changes a GameObject's position to a supplied destination then returns it to its starting position over time. ```APIDOC ## MoveFrom ### Description Instantly changes a GameObject's position to a supplied destination then returns it to its starting position over time. ### Method POST ### Endpoint /websites/pixelplacement_itween/moveFrom ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **target** (GameObject) - Required - The target GameObject to animate. - **position** (Transform or Vector3) - Required - The destination position. - **time** (float or double) - Optional - The time in seconds the animation will take to complete. - **args** (Hashtable) - Optional - A collection of arguments to configure the tween. ### Request Example ```json { "target": "GameObject", "position": {"x": 1.0, "y": 2.0, "z": 3.0}, "time": 1.0, "args": { "name": "moveTween", "easetype": "easeInOut", "looptype": "loop" } } ``` ### Response #### Success Response (200) - **message** (string) - Indicates successful execution of the MoveFrom animation. #### Response Example ```json { "message": "MoveFrom animation started successfully." } ``` ### Additional Properties for 'args' (Hashtable) - **name** (string) - an individual name useful for stopping iTweens by name. - **movetopath** (boolean) - for whether to automatically generate a curve from the GameObject's current position to the beginning of the path. True by default. - **x** (float or double) - for the individual setting of the x axis. - **y** (float or double) - for the individual setting of the y axis. - **z** (float or double) - for the individual setting of the z axis. - **orienttopath** (boolean) - for whether or not the GameObject will orient to its direction of travel. False by default. - **looktarget** (Transform or Vector3) - for a target the GameObject will look at. - **looktime** (float or double) - for the time in seconds the object will take to look at either the "looktarget" or "orienttopath". - **lookahead** (float or double) - for how much of a percentage (from 0 to 1) to look ahead on a path to influence how strict "orienttopath" is and how much the object will anticipate each curve. - **axis** (string) - restricts rotation to the supplied axis only. - **islocal** (boolean) - for whether to animate in world space or relative to the parent. False by default. - **speed** (float or double) - can be used instead of time to allow animation based on speed. - **delay** (float or double) - for the time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - for the shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - for the type of loop to apply once the animation has completed. - **onstart** (string) - for the name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - for a reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - for arguments to be sent to the "onstart" method. - **onupdate** (string) - for the name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - for a reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - for arguments to be sent to the "onupdate" method. - **oncomplete** (string) - for the name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - for a reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - for arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - setting this to true will allow the animation to continue independent of the current time which is helpful for animating menus after a game has been paused by setting Time.timeScale=0. ``` -------------------------------- ### Animate AudioSource Volume and Pitch from Current to Target (C#) Source: https://pixelplacement.com/itween/documentation The AudioFrom function instantly changes an AudioSource's volume and pitch to specified values and then animates it back to its starting values over a set duration. It supports specifying an AudioSource component or using the default one attached to the target GameObject. This function is useful for creating sound effects that return to their original state. ```csharp // Example using AudioFrom with explicit parameters iTween.AudioFrom(myGameObject, 1.0f, 1.5f, 2.0f); // Example using AudioFrom with Hashtable for advanced options Hashtable args = new Hashtable(); args.Add("volume", 0.8f); args.Add("pitch", 1.2f); args.Add("time", 1.5f); args.Add("delay", 0.5f); args.Add("easetype", iTween.EaseType.easeInOutExpo); args.Add("oncomplete", "OnAudioComplete"); iTween.AudioFrom(myGameObject, args); ``` -------------------------------- ### LookFrom API Source: https://pixelplacement.com/itween/documentation Instantly rotates a GameObject to look at the supplied Vector3 then returns it to its starting rotation over time. ```APIDOC ## LookFrom ### Description Instantly rotates a GameObject to look at the supplied Vector3 then returns it to its starting rotation over time. ### Method Multiple Overloads Available ### Endpoint N/A (This is a method within a library) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) None #### Response Example None ### Overloads #### Overload 1: LookFrom(GameObject target, Vector3 looktarget, float time) ##### Parameters - **target** (GameObject) - The GameObject to rotate. - **looktarget** (Vector3) - The target position to look at. - **time** (float) - The duration of the rotation. #### Overload 2: LookFrom(GameObject target, Hashtable args) ##### Parameters - **target** (GameObject) - The GameObject to rotate. - **args** (Hashtable) - A hash table containing various animation properties. ##### Properties within Hashtable `args`: - **name** (string) - An individual name useful for stopping iTweens by name. - **looktarget** (Transform or Vector3) - The target the GameObject will look at. - **axis** (string) - Restricts rotation to the supplied axis only. - **time** (float or double) - The time in seconds the animation will take to complete. - **speed** (float or double) - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - The time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - The shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - The type of loop to apply once the animation has completed. - **onstart** (string) - The name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - A reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Arguments to be sent to the "onstart" method. - **onupdate** (string) - The name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - A reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Arguments to be sent to the "onupdate" method. - **oncomplete** (string) - The name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - A reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Setting this to true will allow the animation to continue independent of the current time. ``` -------------------------------- ### ColorFrom: Animate GameObject color (Unity) Source: https://pixelplacement.com/itween/documentation The ColorFrom function animates a GameObject's color values, starting from a specified color and returning to its original properties over time. It can target Light, GUIText, or GUITexture components. Parameters include the target GameObject, the target color, and the animation time. Advanced options allow for granular control over individual color channels (RGBa), easing, looping, and callbacks. ```csharp iTween.ColorFrom(GameObject target, Hashtable args); iTween.ColorFrom(GameObject target, Color color, float time); ``` -------------------------------- ### CameraFadeTo: Fade camera transparency over time (Unity) Source: https://pixelplacement.com/itween/documentation The CameraFadeTo function changes the transparency of a camera's fade effect over a specified duration. It accepts either a direct amount and time, or a Hashtable for more detailed configuration. Options include setting a name, easing type, loop type, and callback functions for start, update, and complete events. It also supports ignoring the time scale. ```csharp iTween.CameraFadeTo(float amount, float time); iTween.CameraFadeTo(Hashtable args); ``` -------------------------------- ### iTween MoveTo Animation with Hashtable (C#) Source: https://pixelplacement.com/itween/gettingstarted Demonstrates creating and using a Hashtable in C# for iTween.MoveTo animations. It shows how to add properties like target position, time, delay, update callbacks, and loop types. ```C# Hashtable ht = new Hashtable(); void Awake(){ ht.Add("x",3); ht.Add("time",4); ht.Add("delay",1); ht.Add("onupdate","myUpdateFunction"); ht.Add("looptype",iTween.LoopType.pingPong); } void Start(){ iTween.MoveTo(gameObject,ht); } ``` -------------------------------- ### Count: Get iTween Count Source: https://pixelplacement.com/itween/documentation Returns the number of active iTweens. It can count all iTweens in the scene, specific types of iTweens, or iTweens associated with a particular GameObject. ```csharp public static int Count() public static int Count(string type) public static int Count(GameObject target) public static int Count(GameObject target, string type) ``` -------------------------------- ### Hash API Source: https://pixelplacement.com/itween/documentation Provides a universal interface to simplify the creation of Hashtables, particularly useful for C# users. ```APIDOC ## Hash ### Description Universal interface to help in the creation of Hashtables. Especially useful for C# users. ### Method POST (or equivalent for Unity methods) ### Endpoint N/A (Unity Component Method) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **args** (params object[]) - A variable number of arguments to populate the Hashtable. ### Request Example ```csharp Hashtable tweenArgs = iTween.Hash("alpha", 1.0f, "time", 2.0f, "delay", 0.5f); ``` ### Response #### Success Response (200) - **returnValue** (Hashtable) - The created Hashtable. #### Response Example ```json { "returnValue": { "alpha": 1.0, "time": 2.0, "delay": 0.5 } } ``` ``` -------------------------------- ### LoopType Enumeration: Define Animation Looping Behavior (C#) Source: https://pixelplacement.com/itween/documentation Defines the type of loop to apply to an animation once it has completed. This enumeration allows control over how the animation behaves after its initial run, supporting options for no looping, replaying from the start, or ping-ponging back and forth. It is used in conjunction with other iTween methods. ```csharp // Example usage within an iTween call: iTween.MoveBy(gameObject, iTween.Hash("x", 10, "looptype", iTween.LoopType.pingPong, "time", 1.0)); // LoopType values: // none = Do not loop. // loop = Rewind and replay. // pingPong = Ping pong the animation back and forth. ``` -------------------------------- ### ScaleUpdate API Source: https://pixelplacement.com/itween/documentation Similar to ScaleTo but incredibly less expensive for usage inside the Update function or similar looping situations involving a "live" set of changing values. Does not utilize an EaseType. ```APIDOC ## ScaleUpdate ### Description Similar to ScaleTo but incredibly less expensive for usage inside the Update function or similar looping situations involving a "live" set of changing values. Does not utilize an EaseType. ### Method - ScaleUpdate(GameObject target, Vector3 scale, float time) - ScaleUpdate(GameObject target, Hashtable args) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **scale** (Transform or Vector3) - Required - The final scale. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **time** (float or double) - Optional - The time in seconds the animation will take to complete. ### Request Example ```json { "target": "gameObject", "scale": {"x": 3, "y": 3, "z": 3}, "time": 0.5 } ``` ### Response #### Success Response (200) N/A - This is a procedural function call. #### Response Example N/A ``` -------------------------------- ### LookFrom: Rotate GameObject to Look and Return (C#) Source: https://pixelplacement.com/itween/documentation Instantly rotates a GameObject to look at a specified Vector3, then smoothly returns it to its original rotation over a given time. This method is useful for temporary focus effects. It accepts the target GameObject, the look target (Vector3), and the duration of the return animation. ```csharp iTween.LookFrom(gameObject, iTween.Hash("looktarget", lookVector, "time", 1.0f)); ``` -------------------------------- ### MoveAdd Source: https://pixelplacement.com/itween/documentation Translates a GameObject's position over time with various configuration options. ```APIDOC ## POST /websites/pixelplacement_itween/moveadd ### Description Translates a GameObject's position over time. This function allows for fine-grained control over the animation, including easing, looping, and callbacks. ### Method POST ### Endpoint /websites/pixelplacement_itween/moveadd ### Parameters #### Request Body - **target** (GameObject) - Required - The GameObject to translate. - **amount** (Vector3) - Required - The amount to translate the GameObject by. - **time** (float or double) - Optional - The time in seconds the animation will take to complete. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **orienttopath** (boolean) - Optional - Whether or not the GameObject will orient to its direction of travel. Defaults to false. - **looktarget** (Transform or Vector3) - Optional - A target the GameObject will look at during the animation. - **looktime** (float or double) - Optional - The time in seconds the object will take to look at either the "looktarget" or "orienttopath". - **axis** (string) - Optional - Restricts rotation to the supplied axis only. - **space** (Space) - Optional - Applies the transformation in either the world coordinate or local coordinate system. Defaults to local space. - **speed** (float or double) - Optional - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - Optional - The time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - Optional - The shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - The type of loop to apply once the animation has completed. - **onstart** (string) - Optional - The name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - A reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Optional - Arguments to be sent to the "onstart" method. - **onupdate** (string) - Optional - The name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - A reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Optional - Arguments to be sent to the "onupdate" method. - **oncomplete** (string) - Optional - The name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - A reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Optional - Arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Optional - Setting this to true will allow the animation to continue independent of the current time. ### Request Example ```json { "target": "GameObject", "amount": {"x": 1.0, "y": 2.0, "z": 0.0}, "time": 1.0, "easetype": "linear", "oncomplete": "MyCallbackFunction" } ``` ### Response #### Success Response (200) - **status** (string) - Indicates success. #### Response Example ```json { "status": "success" } ``` ``` -------------------------------- ### ScaleAdd API Source: https://pixelplacement.com/itween/documentation Adds to a GameObject's scale over time, providing options for custom easing and callbacks. ```APIDOC ## ScaleAdd API ### Description Adds to a GameObject's scale over time. ### Method This appears to be a function call within a specific framework, not a standard HTTP method. Assuming a C# or similar syntax. ### Endpoint N/A (Internal function) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None **Overloads:** - `ScaleAdd(GameObject target, Vector3 amount, float time)` - `ScaleAdd(GameObject target, Hashtable args)` **Arguments for Hashtable:** - **name** (string) - Optional - An individual name useful for stopping iTweens by name. - **amount** (Vector3) - Required - For the amount to be added to the GameObject's current scale. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **time** (float or double) - Optional - For the time in seconds the animation will take to complete. - **speed** (float or double) - Optional - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - Optional - For the time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - Optional - For the shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - For the type of loop to apply once the animation has completed. - **onstart** (string) - Optional - For the name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Optional - For arguments to be sent to the "onstart" method. - **onupdate** (string) - Optional - For the name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Optional - For arguments to be sent to the "onupdate" method. - **oncomplete** (string) - Optional - For the name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Optional - For arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Optional - Setting this to true will allow the animation to continue independent of the current time which is helpful for animating menus after a game has been paused by setting Time.timeScale=0. ### Request Example ```csharp // Example using Hashtable Hashtable scaleArgs = new Hashtable(); scaleArgs.Add("amount", new Vector3(0.5f, 0.5f, 0.5f)); scaleArgs.Add("time", 2.0f); scaleArgs.Add("easetype", "easeInOutQuad"); scaleArgs.Add("oncomplete", "OnScaleComplete"); iTween.ScaleAdd(myGameObject, scaleArgs); // Example using direct parameters iTween.ScaleAdd(myGameObject, new Vector3(1.2f, 1.2f, 1.2f), 1.0f); ``` ### Response #### Success Response (200) N/A (This is a function call, not an API endpoint returning a response) #### Response Example N/A ``` -------------------------------- ### Animate AudioSource Volume and Pitch to Target (C#) Source: https://pixelplacement.com/itween/documentation The AudioTo function animates an AudioSource's volume and pitch from their current values to specified target values over a set duration. It can utilize the default AudioSource on a GameObject or a provided one. This is ideal for fading sounds in or out, or changing their pitch dynamically during gameplay. ```csharp // Example using AudioTo with explicit parameters iTween.AudioTo(myGameObject, 0.5f, 1.0f, 3.0f); // Example using AudioTo with Hashtable for advanced options Hashtable args = new Hashtable(); args.Add("volume", 1.0f); args.Add("pitch", 0.8f); args.Add("time", 2.0f); args.Add("delay", 1.0f); args.Add("looptype", iTween.LoopType.pingPong); args.Add("onupdate", "OnAudioUpdate"); iTween.AudioTo(myGameObject, args); ``` -------------------------------- ### ScaleTo API Source: https://pixelplacement.com/itween/documentation Changes a GameObject's scale over time. ```APIDOC ## ScaleTo ### Description Changes a GameObject's scale over time. ### Method - ScaleTo(GameObject target, Vector3 scale, float time) - ScaleTo(GameObject target, Hashtable args) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **name** (string) - Optional - An individual name useful for stopping iTweens by name. - **scale** (Transform or Vector3) - Required - The final scale. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **time** (float or double) - Optional - The time in seconds the animation will take to complete. - **speed** (float or double) - Optional - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - Optional - The time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - Optional - For the shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - For the type of loop to apply once the animation has completed. - **onstart** (string) - Optional - For the name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Optional - For arguments to be sent to the "onstart" method. - **onupdate** (string) - Optional - For the name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Optional - For arguments to be sent to the "onupdate" method. - **oncomplete** (string) - Optional - For the name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Optional - For arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Optional - Setting this to true will allow the animation to continue independent of the current time. ### Request Example ```json { "target": "gameObject", "scale": {"x": 5, "y": 5, "z": 5}, "time": 2.0, "looptype": "pingPong" } ``` ### Response #### Success Response (200) N/A - This is a procedural function call. #### Response Example N/A ``` -------------------------------- ### iTween MoveTo Animation with Hash() Method (C#) Source: https://pixelplacement.com/itween/gettingstarted Utilizes iTween's Hash() method in C# for creating animation parameters in a single line. This method provides a consistent way to define parameters across different languages. ```C# iTween.MoveTo(gameObject,iTween.Hash("x",3,"time",4,"delay",1,"onupdate","myUpdateFunction","looptype",iTween.LoopType.pingPong)); ``` -------------------------------- ### FadeUpdate API Source: https://pixelplacement.com/itween/documentation Similar to FadeTo but optimized for use within Update loops or similar real-time changing value scenarios. It does not utilize an EaseType. ```APIDOC ## FadeUpdate ### Description Similar to FadeTo but incredibly less expensive for usage inside the Update function or similar looping situations involving a "live" set of changing values. Does not utilize an EaseType. ### Method POST (or equivalent for Unity methods) ### Endpoint N/A (Unity Component Method) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **target** (GameObject) - The target GameObject to animate. - **args** (Hashtable) - A Hashtable containing animation properties. - **alpha** (float or double) - The target alpha value for the animation. - **time** (float or double) - The duration of the animation in seconds. ### Request Example ```csharp // Example using Hashtable iTween.FadeUpdate(myGameObject, iTween.Hash("alpha", 0.0f, "time", 1.0f)); // Example using direct parameters iTween.FadeUpdate(myGameObject, 0.0f, 1.0f); ``` ### Response #### Success Response (200) None (This is a Unity component method that performs an action) #### Response Example None ``` -------------------------------- ### FadeFrom API Source: https://pixelplacement.com/itween/documentation Instantly changes a GameObject's alpha value and then animates it to a specified target alpha over a duration. It can also target components like Light, GUIText, or GUITexture. ```APIDOC ## FadeFrom ### Description Changes a GameObject's alpha value instantly then returns it to the provided alpha over time. If a Light, GUIText or GUITexture component is attached, it will become the target of the animation. Identical to using ColorFrom and using the "a" parameter. ### Methods * `FadeFrom(GameObject target, Hashtable args)` * `FadeFrom(GameObject target, float alpha, float time)` ### Parameters for Hashtable args #### Optional Parameters - **name** (string) - An individual name useful for stopping iTweens by name. - **alpha** (float or double) - The initial alpha value of the animation. - **amount** (float or double) - The initial alpha value of the animation. - **includechildren** (boolean) - Whether or not to include children of this GameObject. True by default. - **NamedValueColor** (NamedValueColor or string) - Which color of a shader to use. Uses "_Color" by default. - **time** (float or double) - The time in seconds the animation will take to complete. - **delay** (float or double) - The time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - The shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - The type of loop to apply once the animation has completed. - **onstart** (string) - The name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - A reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Arguments to be sent to the "onstart" method. - **onupdate** (string) - The name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - A reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Arguments to be sent to the "onupdate" method. - **oncomplete** (string) - The name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - A reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Setting this to true will allow the animation to continue independent of the current time, which is helpful for animating menus after a game has been paused by setting Time.timeScale=0. ``` -------------------------------- ### MoveBy API Source: https://pixelplacement.com/itween/documentation The MoveBy function animates a GameObject's position by adding a specified amount over a given time. It supports various easing, looping, and callback options. ```APIDOC ## POST /websites/pixelplacement_itween/moveby ### Description Adds the supplied coordinates to a GameObject's position, animating the change over a specified duration. This function allows for fine-grained control over the animation's easing, looping, and callback events. ### Method POST ### Endpoint /websites/pixelplacement_itween/moveby ### Parameters #### Request Body - **target** (GameObject) - Required - The GameObject to animate. - **amount** (Vector3) - Required - The vector representing the displacement to animate. - **time** (float or double) - Optional - The duration in seconds for the animation. Defaults to 1.0. - **x** (float or double) - Optional - Overrides the x component of the `amount`. - **y** (float or double) - Optional - Overrides the y component of the `amount`. - **z** (float or double) - Optional - Overrides the z component of the `amount`. - **orienttopath** (boolean) - Optional - If true, the GameObject will orient to its direction of travel. Defaults to false. - **looktarget** (Transform or Vector3) - Optional - A target the GameObject will look at during the animation. - **looktime** (float or double) - Optional - The time in seconds the object will take to look at the `looktarget` or orient to the path. - **axis** (string) - Optional - Restricts rotation to the supplied axis only. - **space** (Space) - Optional - Applies the transformation in either world or local coordinates. Defaults to local space. - **speed** (float or double) - Optional - Can be used instead of `time` to animate based on speed. - **delay** (float or double) - Optional - The time in seconds to wait before beginning the animation. - **easetype** (EaseType or string) - Optional - The shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - The type of loop to apply once the animation has completed. - **onstart** (string) - Optional - The name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - A reference to the GameObject that holds the `onstart` method. - **onstartparams** (Object) - Optional - Arguments to be sent to the `onstart` method. - **onupdate** (string) - Optional - The name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - A reference to the GameObject that holds the `onupdate` method. - **onupdateparams** (Object) - Optional - Arguments to be sent to the `onupdate` method. - **oncomplete** (string) - Optional - The name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - A reference to the GameObject that holds the `oncomplete` method. - **oncompleteparams** (Object) - Optional - Arguments to be sent to the `oncomplete` method. - **ignoretimescale** (boolean) - Optional - If true, the animation continues independent of Time.timeScale. Defaults to false. ### Request Example ```json { "target": "GameObject", "amount": {"x": 1.0, "y": 2.0, "z": 0.0}, "time": 1.5, "easetype": "easeInOutQuad", "looptype": "loop", "oncomplete": "myCallbackFunction" } ``` ### Response #### Success Response (200) - **message** (string) - Confirmation of successful animation start. #### Response Example ```json { "message": "MoveBy animation started successfully." } ``` ``` -------------------------------- ### CameraTexture: Create fullscreen texture for CameraFade (Unity) Source: https://pixelplacement.com/itween/documentation The CameraTexture function generates a full-screen texture that can be used in conjunction with CameraFade. This function requires a Color value to initialize the texture. This is useful for creating custom fade effects. ```csharp iTween.CameraTexture(Color color); ``` -------------------------------- ### RotateUpdate API Source: https://pixelplacement.com/itween/documentation Efficiently updates the rotation of a GameObject over time, suitable for use within Update loops. ```APIDOC ## RotateUpdate API ### Description Similar to RotateTo but incredibly less expensive for usage inside the Update function or similar looping situations involving a "live" set of changing values. Does not utilize an EaseType. ### Method This appears to be a function call within a specific framework, not a standard HTTP method. Assuming a C# or similar syntax. ### Endpoint N/A (Internal function) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None **Overloads:** - `RotateUpdate(GameObject target, Hashtable args)` - `RotateUpdate(GameObject target, Vector3 rotation, float time)` **Arguments for Hashtable:** - **rotation** (Transform or Vector3) - Required - For the target Euler angles in degrees to rotate to. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **islocal** (boolean) - Optional - For whether to animate in world space or relative to the parent. False by default. - **time** (float or double) - Optional - For the time in seconds the animation will take to complete. ### Request Example ```csharp // Example using Hashtable Hashtable rotationArgs = new Hashtable(); rotationArgs.Add("rotation", new Vector3(0, 90, 0)); rotationArgs.Add("time", 1.0f); iTween.RotateUpdate(myGameObject, rotationArgs); // Example using direct parameters iTween.RotateUpdate(myGameObject, new Vector3(0, 180, 0), 1.5f); ``` ### Response #### Success Response (200) N/A (This is a function call, not an API endpoint returning a response) #### Response Example N/A ``` -------------------------------- ### ScaleBy API Source: https://pixelplacement.com/itween/documentation Multiplies a GameObject's scale over time, offering extensive control over animation properties. ```APIDOC ## ScaleBy API ### Description Multiplies a GameObject's scale over time. ### Method This appears to be a function call within a specific framework, not a standard HTTP method. Assuming a C# or similar syntax. ### Endpoint N/A (Internal function) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None **Overloads:** - `ScaleBy(GameObject target, Vector3 amount, float time)` - `ScaleBy(GameObject target, Hashtable args)` **Arguments for Hashtable:** - **name** (string) - Optional - An individual name useful for stopping iTweens by name. - **amount** (Vector3) - Required - For the amount to be added to the GameObject's current scale. - **x** (float or double) - Optional - For the individual setting of the x axis. - **y** (float or double) - Optional - For the individual setting of the y axis. - **z** (float or double) - Optional - For the individual setting of the z axis. - **time** (float or double) - Optional - For the time in seconds the animation will take to complete. - **speed** (float or double) - Optional - Can be used instead of time to allow animation based on speed. - **delay** (float or double) - Optional - For the time in seconds the animation will wait before beginning. - **easetype** (EaseType or string) - Optional - For the shape of the easing curve applied to the animation. - **looptype** (LoopType or string) - Optional - For the type of loop to apply once the animation has completed. - **onstart** (string) - Optional - For the name of a function to launch at the beginning of the animation. - **onstarttarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onstart" method. - **onstartparams** (Object) - Optional - For arguments to be sent to the "onstart" method. - **onupdate** (string) - Optional - For the name of a function to launch on every step of the animation. - **onupdatetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "onupdate" method. - **onupdateparams** (Object) - Optional - For arguments to be sent to the "onupdate" method. - **oncomplete** (string) - Optional - For the name of a function to launch at the end of the animation. - **oncompletetarget** (GameObject) - Optional - For a reference to the GameObject that holds the "oncomplete" method. - **oncompleteparams** (Object) - Optional - For arguments to be sent to the "oncomplete" method. - **ignoretimescale** (boolean) - Optional - Setting this to true will allow the animation to continue independent of the current time which is helpful for animating menus after a game has been paused by setting Time.timeScale=0. ### Request Example ```csharp // Example using Hashtable Hashtable scaleByArgs = new Hashtable(); scaleByArgs.Add("amount", new Vector3(2.0f, 2.0f, 2.0f)); scaleByArgs.Add("time", 1.5f); scaleByArgs.Add("looptype", "pingPong"); scaleByArgs.Add("onstart", "OnScaleStart"); iTween.ScaleBy(myGameObject, scaleByArgs); // Example using direct parameters iTween.ScaleBy(myGameObject, new Vector3(0.5f, 0.5f, 0.5f), 0.5f); ``` ### Response #### Success Response (200) N/A (This is a function call, not an API endpoint returning a response) #### Response Example N/A ``` -------------------------------- ### LookTo: Rotate GameObject to Look At Target (C#) Source: https://pixelplacement.com/itween/documentation Rotates a GameObject to continuously face a specified Transform or Vector3 over a defined duration. This is ideal for making objects follow or aim at a target. The method takes the target GameObject, the target to look at, and the time it should take to complete the rotation. ```csharp iTween.LookTo(gameObject, iTween.Hash("looktarget", targetTransform, "time", 1.5f)); ``` -------------------------------- ### AudioUpdate Functionality in iTween Source: https://pixelplacement.com/itween/documentation AudioUpdate is designed for frequent updates within a loop, like the Update function. It's more efficient than AudioTo for 'live' data. It does not use EaseType. ```csharp AudioUpdate(GameObject target, float volume, float pitch, float time) AudioUpdate(GameObject target, Hashtable args) ``` -------------------------------- ### FloatUpdate API Source: https://pixelplacement.com/itween/documentation Returns a float that is eased between a current and target value based on the supplied speed. ```APIDOC ## FloatUpdate ### Description Returns a float that is eased between a current and target value by the supplied speed. ### Method GET (or equivalent for Unity methods) ### Endpoint N/A (Unity Component Method) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example ```csharp float easedValue = iTween.FloatUpdate(currentValue, targetValue, speed); ``` ### Response #### Success Response (200) - **returnValue** (float) - The eased float value. #### Response Example ```json { "returnValue": 0.75 } ``` ```