function Wiggle(){
object._x++;
object._x--;
}
It does both actually. You're just not seeing it because of
how Flash
works - the function happens in between frame cycles, so the
object moves
forward a pixel, then back a pixel, then the frame is redrawn
- so the
object does not appear to move. You can fix by doing one or
the other,
dependent on a simple flag:
var flag = 0;
function Wiggle(){
flag++;
if(flag % 2){
object._x++;
}else{
object._x--;
}
}
everytime you call wiggle you increment flag. If it's now an
even number
increment x, otherwise decrement.
HTH
--
Dave -
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/