This site requires JavaScript, please enable it in your browser!
Greenfoot back
KaiPhaz
KaiPhaz wrote ...

2016/6/28

I need help with my actor jumping here is my code:

KaiPhaz KaiPhaz

2016/6/28

#
if (Greenfoot.isKeyDown("Space")){
           setLocation(getX(),getY()-8);
           if(r>=10){
            setLocation(getX(),getY()+count);
           }
        }
        else{
          setLocation(getX(),getY()+count);
               
        }
danpost danpost

2016/6/28

#
The String representation of the key is "space" -- not "Space".
You need to login to post a reply.