well I'm using this code to shoot out a cherries form a pie but the cherries just stays on the pie and it doesn't move like it is meant to do.
Please help
public void fireOnCommand()
{
if(Greenfoot.isKeyDown("f"))
{
World myWorld = getWorld();
myWorld.addObject(cherries, 0, 0);
cherries.setLocation(getX(), getY());
cherries.setRotation(getRotation());
}
}

