A List of Awesome Linux Command Line Text Based Games

commandline gamesThe Linux command line is a powerful console which lets you interact with the entire Linux environment at a more intimate level. Though Linux isn't well known for gaming like Windows is, you can do a whole lot more with Linux - including playing games in the command line.

Linux terminal games are very interesting and fun to play. As a Linux user, you're going to spend a lot of time mastering the command line. Occasionally, when you run out of things to do in the terminal, you can keep yourself entertained with some Linux terminal games.

In this article, we'll take you through a number of the countless Linux terminal based games. Try them out and suggest some more at the end of the article.

1) Nethack

Nethack is a cross-platform dungeons and dragons inspired game. In Nethack, you discover the details of a dungeon but not to kill all things in sight, like other dungeon-like games.

Installing Nethack

Type this command in your terminal to install Nethack

$ sudo apt-get install nethack-console

You can play Nethack in the terminal by typing the command nethack. To quit the game press q, or :q.

2) Tetris

Who never enjoyed playing Tetris? Vitetris is a cross-platform multiplayer Tetris game for the terminal. Vitetris offers you multiple levels and heights. You can also determine options like colors, background and much more.

Installing Vitetris

Grab the source file from the official website. Using your terminal, cd into the Downloads folder and run the following commands.

$ sudo ./configure
$ sudo make
$ sudo make install

Run vetris in the command line by simple typing tetris.

3) Tron

Want to play some action game? You can play tron in multiplayer mode right in your terminal. You don't need to install or compile anything. You can only play this game with other players online and use the WASD keys for control.

Installing Tron

Run this command in your terminal.

$ ssh sshtron.zachlatta.com

4) Cgames

Do you want to play some minesweeper, sliding-block puzzles or sokoban? Muppetlabs brings you all these games right in your terminal.  This version of these games has better font and mouse support.

Installing mines, blocks and sokoban

We'll clone this game from its Github repo and install it with these commands:

$ git clone https://github.com/BR903/cgames.git
$ cd cgames
$ sudo ./configure --disable-mouse
$ sudo make
$ sudo make install

You can run these games by typing csokokan, cmines or cblocks.

5) Pacman4Consle

Feel too old already? Pacman is the king of arcade. You can play Pacman4console right from your Linux terminal and set high scores.

Installing Pacman

Type the following command in your terminal to install Pacman4console

$ sudo apt-get install pacman4console

Type pacman4console in your terminal to launch the game or press q to quit the application.

6) Alienwave

Alienwave is a great variant of the famous space invaders game. Opponents have various shapes and the difficulty level is high.

Installing Alienwave

Download the source from here, cd into your Downloads folder and type these commands.

$ sudo apt-get install libncurses5-dev libncursesw5-dev
$ sudo make
$ sudo make install
$ sudo cp alienwave /usr/games

You can Alienwave by typing alienwave in the terminal or exiting by pressing ctrl + c.

7) GNU Chess

We can't get to this place and still not mention chess. Gnu Chess already suggests this is Chess for *nux. You can play chess against the computer or use it as a chess engine for graphical chess frontends such as XBoard.

Installing GNU Chess

You can install GNU Chess by simply typing this command

$ sudo apt install gnuchess

8) You Only Live Once

Yes, you only live once. This is a Seven Day Roguelike game which concentrates on telling a simple story and engaging the user in simple tactical combat. You're engaged in a very quick to complete tactical combat with heavy plot and characterization.

Installing YOLO

Get the most recent version from here, cd into your Downloads folder and run these commands.

$ tar xvf liveonce005.tar.gz
$ cd linux
$ ./liveonce

You may be required to play game with your console set your console to the 80×30 and have some dependencies installed.

9) Nettoe

netToe terminal-based Tic Tac Toe game playable over the Internet. You get 3 play options when you're playing the game: Player vs CPU, Player vs Player, and Two players over network.

Installing Nettoe

Installing netToe is quite easy.

$ git clone https://github.com/RobertBerger/nettoe.git
$ cd nettoe
$ sudo ./configure
$ sudo make
$ sudo make install

Type nettoe to launch the game.

10) BSD Games

BSD Games is a collection of the classic text-based games distributed with some BSDs like FreeBSD and NetBSD. You'll find a number of games here including air traffic controller, hangman, robots and morse.

Installing BSD Games

Simply type:

$ sudo apt-get install bsdgames

You can play all 40 games included in this package by typing their respective names, eg hangman, quiz, robots, etc.

11) Ascii-rain

How about some cool rain in your console? Ascii-rain is a C-based 'game' written with Ncurses, which displays rainfall inside your terminal. There's no interaction with this game - just make it rain.

Installing Ascii-rain

Ascii-rain is available from its GitHub repo. You'll need a ncurses library in order to make it rain. This guide will show you how to install ncurses for Ubuntu.

$ sudo apt install libncurses-dev ncurses-dev -y
$ git clone https://github.com/nkleemann/ascii-rain.git 
$ cd ascii-rain 
$ gcc rain.c -o rain -lncurses

Now you can run rain from the current directory by typing ./rain . If you want to run it from anywhere in your terminal enter the following command:

# cp rain /usr/local/bin/rain

In this article, discovered a myriad of terminal-based games and how to get them installed. Which are your favorite picks? Let us know in the comments if you find more interesting games.

About Eyram Amedzor

Kwaku Eyram has been a working with computers and software for more than 10 years. He's an all-round geek and very fluid with Linux, Android and Windows operating systems. Asides being a tech enthusiast, Kwaku doubles as a tech support personnel and a tech writer. He currently has interest in IoT, web development and information security.

Author Archive Page

Have anything to say?

Your email address will not be published. Required fields are marked *

All comments are subject to moderation.

1 Comment