Hungry Snake

推荐的级别级别
5+
A long serpentine creature slithers across a limited field, obeying the player's orders (moving right, left, down, and up). And there's no way to stop it from moving. Just don't touch the boundaries or you'll die! And don't bite yourself or... well, you get the idea. Along the way, the creature encounters food that makes it even longer. As it grows, it gets more and more cramped... Stop the madness! You probably recognize this comedic storyline from the famous game "Snake". This game originated in the 1970s. That's when it first appeared on arcade machines. In the 21st century, it was popularized by Nokia, which pre-installed Snake on almost all their mobile phones. Between these two milestones, there were versions for the Commodore VIC-20, MS-DOS, ZX Spectrum, Windows, Mac OS? If you go to Google Play or the App Store, you'll probably find a couple dozen different versions of Snake. It's hard to imagine a platform that doesn't have its own version of Snake. Why? On the one hand, it's an interesting game that is perfect for passing the time. On the other hand, Snake is simple enough to create on your own. See for yourself! Use Java to write your own version of this game about the adventures of a growing reptile. On CodeGym, we've already described every step, which will help a novice player handle this task without problems. Carry on!
评论 (114)
  • 受欢迎
你必须先登录才能发表评论
Shivam yadav Android Developer
2 四月, 06:47
package com.codegym.games.snake; import com.codegym.engine.cell.*; public class SnakeGame extends Game { public static final int WIDTH = 15; public static final int HEIGHT = 15; @Override public void initialize() { setScreenSize(WIDTH, HEIGHT); } }
Guest
级别 1 ,India
2 四月, 06:19
i love you arti
Anonymous #11623460
级别 0 ,Friedrichshafen,Germany
12 二月, 08:55
😮
Anonymous #11623460
级别 0 ,Friedrichshafen,Germany
12 二月, 08:54
😎
Anonymous #11606130
级别 0 ,Heidelberg,Germany
20 十二月 2024, 08:48
O, du Fröhliche!
Anonymous #11606130
级别 0 ,Heidelberg,Germany
20 十二月 2024, 08:49
bester mann
Morel
级别 0 ,France
13 七月 2024, 16:44
tete de neuille frrrrrrrrr
Anonymous #11516985
级别 2 ,-,France
16 五月 2024, 09:28
thanks
Anonymous #11502613
级别 1 ,Spain
14 四月 2024, 09:14
🖕
Anonymous #11502613
级别 1 ,Spain
14 四月 2024, 09:06
Fuck you
Anonymous #11594043
级别 1 ,San Antonio,United States
15 十一月 2024, 16:12
you tell em
Fohli
级别 2 ,Germany,Germany
6 三月 2024, 10:11
Dauernd 'falsch' weil Rechtschreibung verkehrt xD Und ich noch was aber die Methode hab ich doch 🤣