is there any method that checks if the the key was released
// field for space key
private boolean spaceDown = false;
// in method
if (spaceDown != Greenfoot.isKeyDown("space")) // change in state?
{
spaceDown = !spaceDown; // record change
if (!spaceDown) // key released? (up after change in state)
{
// what to do when key is released
}
}