Question about iTween ,
Is there any way to use “from” value and “to” value in a single iTween call ?
I want to fade a guiTexture (including all its child) from 1 to 0 alpha value whenever gameObject is enabled ,
I’m trying to do it using iTween. FadeFrom/iTween. FadeTo, On first call iTween changes alpha value from 1 to 0 ,
however on second call, iTween changing the value from 0 to 0 …which makes no sense.
Hence , please let me know if I can pass both “from” and “to” values to itween so that everytime it fades from 1 to 0 value.
or let me know if there is any other workaround for this
Thanks in advance 
Add a callback when the process is complete, if you are using an iTweenHash, add the next parameter: “oncomplete”, “MyFunction”.
Then create MyFunction(){
float aux = a;
a = b;
b = aux;
}
That will swap your values
This will help someone if they have the same issue:
//Method below will completely Fade out object from alpha:0 to alpha:1 irrespective of object's current alpha value.
void FadeOut(){
iTween.FadeFrom (gameObject, iTween.Hash(
"alpha",0,
"time" , 1f,
"delay",0.0f,
"oncomplete","OnCompleteFadeTo",
"oncompletetarget",gameObject
));
}
public void OnCompleteFadeTo(){
iTween.FadeTo (gameObject, iTween.Hash(
"alpha",1,
"time" , 1f
));
}