lord_of_uo
03-24-2006, 01:07 PM
look here to see the problem:
www.zeldavideos.4t.com/link_test.swf (http://www.zeldavideos.4t.com/link_test.swf)
hold the arrow keys down for more than a second and link has a seizure!!!!!
heres the code i put for it:
onClipEvent(enterFrame)
{
if(Key.isDown(Key.RIGHT)){
this._x +=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.LEFT)){
this._x -=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.UP)){
this._y -=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.DOWN)){
this._y +=5;
}
}
on(keyPress "<Right>")
{
gotoAndPlay("walk_right");
}
on(keyPress "<Left>"){
gotoAndPlay("walk_left");
}
on(keyPress "<Up>"){
gotoAndPlay("walk_forward");
}
on(keyPress "<Down>"){
gotoAndPlay("walk_backward");
}
i put in the main character clip all the clips for walking in all directions and put a stop command after each clip
and on each clip.
what did i do wrong?
how do i correct this problem?
www.zeldavideos.4t.com/link_test.swf (http://www.zeldavideos.4t.com/link_test.swf)
hold the arrow keys down for more than a second and link has a seizure!!!!!
heres the code i put for it:
onClipEvent(enterFrame)
{
if(Key.isDown(Key.RIGHT)){
this._x +=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.LEFT)){
this._x -=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.UP)){
this._y -=5;
}
}
onClipEvent(enterFrame)
{
if(Key.isDown(Key.DOWN)){
this._y +=5;
}
}
on(keyPress "<Right>")
{
gotoAndPlay("walk_right");
}
on(keyPress "<Left>"){
gotoAndPlay("walk_left");
}
on(keyPress "<Up>"){
gotoAndPlay("walk_forward");
}
on(keyPress "<Down>"){
gotoAndPlay("walk_backward");
}
i put in the main character clip all the clips for walking in all directions and put a stop command after each clip
and on each clip.
what did i do wrong?
how do i correct this problem?