cx-game
Game Prototype
CX game is a new 2D console game.
Table of Contents
Installation
cx-game requires Golang version of 1.13+
Compiling on Linux
Install dependencies with
sudo apt update
sudo apt install -y glade xvfb libxinerama-dev libxcursor-dev libxrandr-dev libgl1-mesa-dev libxi-dev libperl-dev libcairo2-dev libpango1.0-dev libglib2.0-dev libopenal-dev libxxf86vm-dev libasound2-dev make
Install Go
- Go to Go Downloads and download from the featured downloads for linux, something like
go1.16.2.linux-amd64.tar.gz
- Extract the archive and install, you may require root or sudo
For example:
rm -rf /usr/local/go && tar -C /usr/local -xzf go1.16.2.linux-amd64.tar.gz
- Add /usr/local/go/bin to the PATH environment variable.
Or just use this for a quick check
export PATH=$PATH:/usr/local/go/bin
- Verify that you've installed Go by opening a command prompt and typing the following command:
go version
Following this for more.
git
using apt
Install sudo apt update
sudo apt install git
You can use any other code editor, for installing sublime run these commands:
sublime
using apt
Install sudo apt update
sudo apt install sublime-text
Usage
Run the program.
git clone https://github.com/skycoin/cx-game.git
cd cx-game
go mod download
go run main.go
A window should appear, with a cat use a
, s
, d
, w
to move the cat around.
Open source code in editor
cd cx-game
subl ./
Compiling on MacOS
Install Go
- Go to Go Downloads and download from the featured downloads for Apple macOS, something like
go1.16.2.darwin-amd64.pkg
- Open the package file you downloaded and follow the prompts to install Go.
- Verify that you've installed Go by opening a command prompt and typing the following command:
go version
Following this for more.
git
with brew
Install brew install git
sublime
with brew
Install brew install --cask sublime-text
Usage
Run the program.
git clone https://github.com/skycoin/cx-game.git
cd cx-game
go mod download
go run main.go
A window should appear, with a cat use a
, s
, d
, w
to move the cat around.
Open source code in editor
cd cx-game
subl ./
Compiling on Windows
Install Go
- Go to Go Downloads and download from the featured downloads for Microsoft Windows, something like
go1.16.2.windows-amd64.msi
- Open the package file you downloaded and follow the prompts to install Go.
- Verify that you've installed Go by opening a command prompt and typing the following command:
go version
Following this for more.
git
from executable
Install - Download git from git-scm.com
- Open the executable and follow the prompt to install git.
sublime
from executable
Install - Go to sublime downloads page
- Download the executable for windows
- Open the executable and follow the prompts to install sublime.
MinGW
Install - Download MinGW installer from here
- Open the executable and follow the instructions.
- Select Architecture = x86_64 as show in the picture.
- Now go to the installed directory and run mingw-w64.bat to add mingw to PATH.
OpenAL
Install - Download and extract zip archive from openal.org
- Run the installer
Usage
Opening terminal
- Click the Start menu.
- In the menu's search box, type cmd, then press the Enter key.
- In the Command Prompt window that appears, type the following command:
Run the program from terminal
git clone https://github.com/skycoin/cx-game.git
cd cx-game
go mod download
go run main.go
A window should appear, with a cat use a
, s
, d
, w
to move the cat around.
Open source code in editor
- Open sublime text editor
- Drag and drop cx-game folder into sublime text editor
Libraries Used
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.