GithubHelp home page GithubHelp logo

yethranayeh / battleship Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 590 KB

Battleship is a web implementation of the traditional two-player strategy game.

Home Page: https://yethranayeh.github.io/battleship

JavaScript 71.56% CSS 28.44%
battleship theodinproject the-odin-project progressive-web-app battleship-game battleships-game battleshipgame

battleship's Introduction

Battleship

Battleship is a web implementation of the traditional two-player strategy game. Since it is a Progressive Web Application it can be installed to home screens on mobile devices and can be played offline once it is installed.

How to Play

  • The player places 5 ships on their board.
    • The ships available to the player have the following unit sizes: 5, 4, 3, 3, 2
  • After the player places their ships on the board, they take turns with computer to attack each other.
  • The goal is to sink all of the opponent's ships before they sink yours.

App Limitations

  • In its current state, page needs to be refreshed to start a new game
  • Computer attack is deliberately slowed down to respond after 0.35 - 0.8 seconds to make it seem more natural instead of getting an instant attack after player plays their turn.
    • The times are defined as minResponseTime and maxResponseTime attribute of computer object, which can be changed in the index.js.

Credits

battleship's People

Contributors

imgbotapp avatar yethranayeh avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.