iTween FadeTo

I’m going crazy… I will do fade between 3 group of object (3 object that have 3 child each). I’m using iTween. It is work only for the first fade. After the first fade script must be deactivate the first group of object, but It doesn’t… I don’t understand…

var OBJFirst : GameObject;
var OBJSecond : GameObject;
var SingleTouch : boolean = true;
var DoubleTap : boolean = false;
var Swipe : boolean = false;
var AlphaHigh : float = 1.0;
var AlphaLow : float = 0.0;
var velocity : float = 1.0;
var TimeDelay : float = 0.0;

private var var_Fade : boolean = false;
private var GoTouch : boolean = true;

function Awake () {
}


function Start () {
}

function Update () {

if (var_Fade){
fun_Fade();
}
}

function fun_Fade(){
     
     iTween.FadeTo(OBJFirst,{"a":AlphaLow, "time":velocity, "delay":TimeDelay, "onComplete":"fun_FadeFalse", "onCompleteTarget": OBJFirst});
     iTween.FadeTo(OBJSecond,{"a":AlphaHigh, "time":velocity, "delay":TimeDelay, "onComplete":"fun_FadeFalse", "onCompleteTarget": OBJSecond});
     }
  
	
function fun_FadeFalse() {     // this must be deactivate first group and all child
var_Fade = false;
Manager.GoTouch = true;
OBJFirst.SetActiveRecursively(false);
}


function On_TouchStart(gesture:Gesture){
if (Manager.GoTouch){
if (SingleTouch){
Manager.GoTouch = false;
OBJSecond.SetActiveRecursively(true);
var_Fade = true;
}
}
}

Help.

It’s because in fun_FadeFalse(), you only specify OBJFirst, and you never specify OBJSecond to turn false anywhere.

I may not have understood your question though, so it could also be that you need to specify the “ontargetcomplete” to gameObject since your functions are within this script, and not attached to those other objects.