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

Report as inappropriate.

Swedishsam
Swedishsam presents ...

2012/5/5

SnakeGame

Still need to add a leveling system which causes the snake to go faster, and also need to make it stop being able to go in the complete opposite direction its going.

4606 views / 8 in the last 7 days

Tags: demo with-source

open in greenfoot
Your browser does not support the canvas tag.
tyson7tyson7

2012/5/5

// checking if hit with wall. if (getX() <=5 || getX() >= getWorld().getWidth() -5) { getWorld().removeObject(this); return; } if (getY() <=5 || getY() >= getWorld().getHeight() -5) { getWorld().removeObject(this); return; }

Want to leave a comment? You must first log in.

Who likes this?

No votes yet.