actionscript 2
Hey everyone. I have a movie clip that I am dragging onto another movie clip and i want it to stay put. But once I add in another 'OR' statement in the if statement, it freaks out and doesn't work. Why is this?
This code works:
Code:
btn1.onRelease=function(){
stopDrag();
if(eval(this._droptarget) != btn1Hold) {
this._x=this.startX;
this._y=this.startY;
}
else{
//CODE
}
}
This code DOES NOT work:
Code:
btn1.onRelease=function(){
stopDrag();
if( (eval(this._droptarget) != btn1Hold) || (eval(this._droptarget) != btn2Hold) ) {//CHANGED LINE
this._x=this.startX;
this._y=this.startY;
}
else{
//CODE
}
}
For whatever reason it doesn't like the extra 'OR' in the if statement! why!?
Thanks in advance!