There is no way to determine why it is wrong without seeing the class code in its entirety. Also, most helpful would be what error message you are getting, if any.
Don't you need a number parameter in the move call?
One of the reasons I asked that the entire class be shown was to see if there was a 'move' method within the class itself (that 'move' was not trying to call the Actor class method with that name).
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class bee here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class bee extends Actor
{
/**
* Act - do whatever the bee wants to do. This method is called whenever
* the 'Act' or 'Run' button gets pressed in the environment.
*/
public void act()
{
if( atWorldEdge())
{
turn(17);
}
move(3);
}
}
Ok. The 'bee' class extends the 'Actor' class. This means that if what you are showing is the entire 'bee' class, then there is no 'atWorldEdge' method declared anywhere. That method can be found in the 'Animal' class that can be imported by way of the menubar ('Edit'>'Import class ...'). You can either copy/paste the method into your 'bee' class or have the 'bee' class extend the 'Animal' class to make the method available for use in that class.