Hey guys,
Sky from Germany here :) I have a little big problem with my projekt i'm doing for school at the moment.
It's a little jump 'n' run with the character "Pinguin" and he wants to jump but the animation looks awefull :/
Can u help me to get a jump like this http://www.greenfoot.org/scenarios/7091 ?
Thats my code:
EXTRA QUESTION:
is there an alternativ for Greenfoot.delay() that just delays one class and not the whole Program ?
if (pressSpace()) //jump { if(!objectAbove()&&(objectBelow())) //just jump if Pinguin stands on something and nothing is above him. { for (int i = 1; i<=300; i++) //thats my Problem { { if(!objectAbove()) { setLocation( getX(), getY() -1); } } } }