https://github.com/naturalclar/battleship-node
A Simple Battleship Game made with Node.js
https://github.com/naturalclar/battleship-node
Last synced: over 1 year ago
JSON representation
A Simple Battleship Game made with Node.js
- Host: GitHub
- URL: https://github.com/naturalclar/battleship-node
- Owner: Naturalclar
- License: mit
- Created: 2018-02-16T00:01:18.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-10-16T03:23:04.000Z (almost 8 years ago)
- Last Synced: 2025-02-16T09:27:19.226Z (over 1 year ago)
- Language: JavaScript
- Size: 103 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HTML Battle Ship
A Simple In-Browser Battleship Game.
This application is made with HTML, CSS, JS, without use of other frameworks or external libraries.
NodeJS is used to serve the application, however, most of the functions are done on the client's side.
You can see the demo app running [here](https://nc-simple-battleship.now.sh).
## Getting Started
### Prerequisite
You will need to have [Node.js](https://nodejs.org/) installed on your computer.
### Clone the repository
`git clone https://github.com/Naturalclar/battleship-node.git`
### Running the App
You can run the application by entering the following command.
`npm start`
The application will be running at `localhost:3000`.
## Flow of the App
This game is a simple game of battleship, designed for 2 players.
Each players will set up 5 different battleships on their grid.
Players will then take turns hitting each other's grid to try to sink their battleships.
When one person sinks all of opponent's battleships, that player will be victorious.
This game has 4 main states:
- Initial Screen
- Where you will enter the name of participants
- SetUp Screen
- Where each players will set up their battleships
- As of current state, this game is meant to be played on a single window. You will need to kindly ask the other player to not look at your screen while setting up the board.
- Battle Screen
- Where each players will take turns trying to hit the opponent's battleships.
- Win Screen
- Where the winner is displayed, and you can chose to restart the game.
Enjoy!