04-22-2017
Snake game challenge in UNIX
Hey Guys,
I have made this basic snake game but it a little bit different from conventional snake game. Learned some basics of Unix. Hope you enjoy playing it.
Please download and run on your machine and suggest any changes i can make. and let me know if someone could score 1000 points
Thanks,
Amit
Last edited by amit14august; 04-29-2017 at 05:18 PM..
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello everyone. I am new to these forums and also new to Unix. And by saying "new to Unix" I mean I have never used it and 10 minutes ago was asked to start learning. So here I am.
I was wondering if anyone could help me find out how long it would take to write code in Unix that will do the... (1 Reply)
Discussion started by: idesaj
1 Replies
2. UNIX for Dummies Questions & Answers
Hi there..
I know this is a kind low question, but do anyone know where I can find some hints and or clues for the "adventure" game on UNIX ?
( /usr/games/adventure ).
I already searched on this forum but didnt find the answer to my question.
Thanks a lot.... (3 Replies)
Discussion started by: TARFU
3 Replies
3. UNIX for Advanced & Expert Users
Hi, there are some servers here at work which issue a Safeword challenge after I login. Can anyone tell me exactly how the challenge/response system works? In particular, how are the valid keys decided? (2 Replies)
Discussion started by: blowtorch
2 Replies
4. Shell Programming and Scripting
I have the following text
Microsoft iSCSI Initiator version 2.0 Build 3497
Targets List:
iqn.2001-05.com.equallogic:0-8a0906-daef43402-138000002a4477ba-grsrv12-extra
iqn.2001-05.com.equallogic:0-8a0906-986f43402-520000002b447951-exchange
... (9 Replies)
Discussion started by: netmedic
9 Replies
5. Shell Programming and Scripting
Here's a regex substitution operation that has stumped me with sed:
How do you convert lines like this:
first.key ?{x.y.z}
second.key ?{xa.ys.zz.s}
third.key ?{xa.k}
to:
first.key ?{x_y_z}
second.key ?{xa_ys_zz_s}
third.key ?{xa_k}
So i'm basically converting all the... (11 Replies)
Discussion started by: neked
11 Replies
6. Shell Programming and Scripting
Ok then i Have a challenge for you :
Give me PS1 so that it always display the least 2 levels of directory
(except if i am above of course)
I want it this way :
so if i go to
/
/home/
/home/user
/home/user/whatever
/home/user/whatever1/whatever2
my PS1 should respectively... (12 Replies)
Discussion started by: ctsgnb
12 Replies
7. UNIX for Dummies Questions & Answers
I've been given a directory full of subdirectories full of logfiles of the same name:
/logfiles/day1/file1/blockednodes.csv
day1-14
file1-48
The above is the actual directory structure for 14 days worth of a logfile that is generated every 30 minutes. It's been done this way to preserve the... (15 Replies)
Discussion started by: Cludgie
15 Replies
8. Shell Programming and Scripting
Hi,
I am designing snake and ladder game in unix. I am writing my script in bash shell in Solaris version.
This game is designed by me for which I would like to give access to two players.
When these players execute the game, there should be communication between the three participants(game... (7 Replies)
Discussion started by: ayarlaga
7 Replies
9. Shell Programming and Scripting
I have searched through google, and this forum to try and find the answer, but alas, nothing quite hits the whole answer.
I am trying to read the last line (or lines) of some log files. I do this often.
The files are named sequentially, using the date as part of the file name, and appending... (18 Replies)
Discussion started by: BatterBits
18 Replies
LEARN ABOUT DEBIAN
snake4
SNAKE4(6) Games Manual SNAKE4(6)
NAME
snake4, snake4scores - Game starring a fruit-eating snake.
SYNOPSIS
snake4 [-hHV] [-M file] [--help] [--highscores] [--version] [--merge-highscores=file]
snake4scores
DESCRIPTION
The snake4 program is my fourth implementation of the snake game, written for Unix and X11. Previous versions were written for MS-DOS.
Move the snake around the screen and eat food. The snake grows in length as you eat. Avoid hitting the fence, eating lethal mushrooms and
rotten food, and biting your own tail.
Now and then a slim-pill will bounce around. If you eat this, you will get shorter, and you will gain bonus points for every length you
loose. The bonus is also given when a round is over.
When food starts blinking, it's about to rot. Rotten food is poisonous, and thus uneatable. As long as it blinks, it can still be eaten.
Oh, yes - I almost forgot: You may be visited by the evil headbanger. Take my advice and run away from him before he hits you in the head!
He won't stay long.
The keys used to control the game are given at startup.
snake4 features a site-wide highscore file. The file contains the top 200 users. Each user may appear once only in the highscore table.
For technical reasons, snake4 connects to the X11 server before parsing options. This makes it impossible to eg. browse the highscore table
using -H if no server is available. To be able to see the scores in such a case, snake4scores produces the same output as snake4 with
option -H, but does no attempt on connecting to the X11 server.
OPTIONS
-h, --help
Print a usage message on standard output, and exit successfully.
-H, --highscores
Dump the highscore list to standard output, and exit successfully. Starting snake4 with the name snake4score does the same thing,
without first connecting to the X11 server. Note that this will possibly print more entries than the 20 or so that will fit within
the game startup screen.
-V, --version
Print version information on standard output, then exit successfully.
-M, --merge-highscores=file
Merge separate highscore file file into the default highscore file, and exit successfully. Displays the new highscore table. This
option is for the game owner or root only.
X11 OPTIONS
In addition to the above mentioned options, snake4 accepts the standard X11 toolkit options.
AUTHOR
Sverre H. Huseby <shh@thathost.com>.
11 October 1996 SNAKE4(6)