StartDrag() is a problem!
- Gimmick
-
Gimmick
- Member since: Aug. 20, 2008
- Offline.
-
- Send Private Message
- Browse All Posts (11,482)
- Block
-
- Forum Stats
- Member
- Level 27
- Programmer
When I want to make a movie clip that you can drag when you release it goes to the second frame and then, BAM! There is some text that you can edit, but it can't edit.
Code is:
on(press){
this.startDrag();
}
on(release, releaseOutside){
gotoAndStop(2);
stopDrag();
}
here is the alternative code. It solves the problem, but it just doesn't want to drag:
//with the variable of box.button
on(press){
startDrag(_root.box.button);
}
on(release, releaseOutside){
stopDrag();
gotoAndStop(2);
}
Can anybody help me?
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies
- Denvish
-
Denvish
- Member since: Apr. 25, 2003
- Offline.
-
- Send Private Message
- Browse All Posts (15,977)
- Block
-
- Forum Stats
- Member
- Level 46
- Blank Slate
At 3/22/09 04:10 PM, sanjeev98 wrote: this.startDrag();
Try startDrag(this); instead
- liam
-
liam
- Member since: Dec. 11, 2004
- Offline.
-
- Send Private Message
- Browse All Posts (14,243)
- Block
-
- Forum Stats
- Member
- Level 22
- Blank Slate
In the first bit of code you had the gotoAndStop before the stopDrag, but in the second you had them the other way around.. so you need to mix the 2.
on(press){
startDrag(this);
}
on(release, releaseOutside){
stopDrag();
_root.gotoAndStop(2);
}
Or.. whatever yours was.
Sup, bitches :)
- Gimmick
-
Gimmick
- Member since: Aug. 20, 2008
- Offline.
-
- Send Private Message
- Browse All Posts (11,482)
- Block
-
- Forum Stats
- Member
- Level 27
- Programmer
At 3/22/09 06:11 PM, liam wrote: In the first bit of code you had the gotoAndStop before the stopDrag, but in the second you had them the other way around.. so you need to mix the 2.
on(press){
startDrag(this);
}
on(release, releaseOutside){
stopDrag();
_root.gotoAndStop(2);
}
Or.. whatever yours was.
Doesn't work. Anyways, now I have a much better knowledge of flash.
Slint approves of me! | "This is Newgrounds.com, not Disney.com" - WadeFulp
"Sit look rub panda" - Alan Davies


