I need help with animating Pacman. It seems as though it is animating too fast, as in moving it's mouth too quickly ( it's like on drugs :D )
What should i do?
private void moving() { if ( !treeFront() ) { Movement(); } if ( Greenfoot.isKeyDown("up") ) { Direction(UP) ; } if ( Greenfoot.isKeyDown("down") ) { Direction(DOWN) ; } if ( Greenfoot.isKeyDown("left") ) { Direction(LEFT) ; } if ( Greenfoot.isKeyDown("right") ) { Direction(RIGHT) ; } void Movement() { if ( !frontWall() && !ghostWallFront() ) { move(3); animate(); } }