I want to drag a button to a rectangle and when i drop it, it’ll go to sene 2 i attached this fla so you get an idea of what i want ant tell me what did I do wrong.
and if you could fixed and attach the fla to see what you did that way I’ll learn more
Well in this case, you can try this one.
Considering the instance names you used, place this code in your “circle_mc” clip:
[AS] onClipEvent (mouseDown) {
if (this, hitTest(_root._xmouse, _root._ymouse)) {
startDrag(this);
}
}
onClipEvent (mouseUp) {
stopDrag();
}
onClipEvent (enterFrame) {
if (this, hitTest(_parent.rec_mc)) {
_parent.doWhatever();
}
}
[/AS]
Havent tested it but that should work. If in case not, try using “_root” instead of “_parent”.
ok… change your code function to:
[AS]function doWhatever() {
if (armSelected == 1) {
//gotoAndPlay your Destination.
}
if (armSelected == 2) {
//gotoAndPlay your Destination.
}
if (armSelected == 3) {
//gotoAndPlay your Destination.
}
}
[/AS]
… and once again… add this to your onClipEvent(mouseDown):
[SIZE=4]You just know it!!! Hurray!!! You are the boss!![/SIZE]
thanks a lot I finally got it thanks to you and I was wondering if I could put you in my buddy list if you don’t mind?