You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 18, 2022. It is now read-only.
Copy file name to clipboardexpand all lines: README.md
+17-14
Original file line number
Diff line number
Diff line change
@@ -2,31 +2,34 @@
2
2
3
3
The classic Snake game, right in your terminal
4
4
5
-
## Manually downloading and installing the game
5
+
## Installation
6
6
7
-
1. Ensure `git` and `node` (`10.x.x` or later) are installed on your system
7
+
Please see the [project page](https://donaldkellett.github.io/csnaketerm) for details.
8
+
9
+
## Installing and running the game from source
10
+
11
+
Note that this option does not install the corresponding `man` pages for this game.
12
+
13
+
### On Unix systems
14
+
15
+
1. Ensure `git` and `node` are installed on your system. This game is known to work with Node 10 and later so older versions of Node may or may not work.
1.`make` - this actually does nothing, so feel free to skip this step
11
18
1.`sudo make install`
12
19
13
20
You should then be able to run the game by invoking `csnaketerm` in your terminal.
14
21
15
22
To uninstall: `cd` to the root of this repo and run `sudo make uninstall`.
16
23
17
-
If you are uncomfortable installing the game system-wide using `sudo`, skip the last two steps and invoke the game as `./csnaketerm` instead. Delete your clone of this repo once done.
24
+
If you are uncomfortable installing the game system-wide using `sudo`, skip the last step and invoke the game as `./csnaketerm` instead. Delete your clone of this repo once done.
25
+
26
+
### On Windows
27
+
28
+
TODO
18
29
19
-
## Wishlist
30
+
## Contributing
20
31
21
-
-[x] Create packages for latest stable Debian and its downstream distributions
22
-
-[x] Create packages for CentOS Stream 8 ~~and CentOS Linux 7~~
23
-
-[x] Create package for openSUSE
24
-
-[ ] Add functionality to save per-user highscores
25
-
-[x] Create packages for Arch and downstream distributions (?)
26
-
-[ ] Create Nix package for NixOS (?)
27
-
-[ ] Package for Windows 10 (?)
28
-
-[ ] Create Homebrew formula for macOS (?)
29
-
-[ ] Create a server to track all-time highscores and add functionality to upload user scores to server (opt-in) (???)
32
+
Feel free to open issues and pull requests as you see fit, though the final decision on addressing which issues and accepting which pull requests is reserved for the author of this game. Of course, if there are issues or pull requests you'd like to incorporate that end up rejected by the author, you are free to fork this project and create your own variant of this game subject to the terms of the GPL (see the License section for details).
thrownewError(`Fatal error: The user data located at ${highScoresFilePath} appears to be corrupted. Deleting the file and restarting the game is the simplest solution, but note that you will lose all in-game progress.`)
187
+
highScores=highScores.split`,`.map(n=>+n)
188
+
highScores={
189
+
'Unconfined': {
190
+
'Easy': highScores[0],
191
+
'Medium': highScores[1],
192
+
'Hard': highScores[2],
193
+
'Insane': highScores[3]
194
+
},
195
+
'Walled': {
196
+
'Easy': highScores[4],
197
+
'Medium': highScores[5],
198
+
'Hard': highScores[6],
199
+
'Insane': highScores[7]
200
+
},
201
+
'Labyrinth': {
202
+
'Easy': highScores[8],
203
+
'Medium': highScores[9],
204
+
'Hard': highScores[10],
205
+
'Insane': highScores[11]
206
+
}
207
+
}
208
+
}catch(err){
209
+
console.error(err)
210
+
process.exit(1)
211
+
}
212
+
}
213
+
mainMenu()
214
+
}
215
+
145
216
asyncfunctionmainMenu(){
146
217
console.clear()
147
218
console.log(`csnaketerm, v${VERSION}`)
148
219
console.log('The classic Snake game, right in your terminal')
149
220
console.log('Choose an action by pressing the corresponding key:\n')
Copy file name to clipboardexpand all lines: csnaketerm.6
+2-2
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
.TH csnaketerm 6 "January 2021" "0.1.0"
1
+
.TH csnaketerm 6 "January 2021" "0.2.0"
2
2
.SH NAME
3
3
csnaketerm - The classic Snake game, right in your terminal
4
4
.SH SYNOPSIS
@@ -21,4 +21,4 @@ Display the current version
21
21
.SH NOTES
22
22
This is a standalone program designed to be invoked directly, and as such, its behavior when standard input/output is redirected or piped to or from the program is unspecified.
0 commit comments