Skip to content

bniladridas/takashi-samurai-duel-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Takashi: The Samurai Duel Game

Welcome to Takashi: The Samurai Duel Game! This is a web-based game where two players (or one player against AI) take turns to place their symbols on a 3x3 grid. The first player to align three symbols horizontally, vertically, or diagonally wins the game.

Table of Contents

Overview

This game is built using HTML, CSS, and JavaScript. It includes features such as AI opponent, different difficulty levels, and background selection.

Features

  • Two-player mode
  • Play against AI with different difficulty levels
  • Background selection before starting the game
  • Scoreboard to keep track of wins
  • Sound effects for win, lose, and draw
  • Feedback submission form

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/niladrridas/takashi-samurai-duel-game.git
    cd takashi-samurai-duel-game
  2. Open the project in your preferred code editor (e.g., Visual Studio Code):

code .
  1. Open index.html in your web browser to start the game.

Usage

  1. When you open the game, a modal will appear with game rules and instructions.
  2. Select a background image by clicking on "Background 1" or "Background 2".
  3. Click "OK" to start the game.
  4. Use the controls to reset the game or toggle AI mode.
  5. Choose the difficulty level for AI from the dropdown menu.
  6. Enter your research interest, game strategy, and feedback in the provided form and submit it.

Project Structure

project-root/
│
├── img/
│   ├── game.png
│   └── image1.jpg
│
├── css/
│   └── styles.css
│
├── js/
│   └── script.js
│
├── sounds/
│   ├── win-tune.mp3
│   ├── lose-tune.mp3
│   └── draw-tune.mp3
│
└── [index.html]

Main Files

  • index.html: The main HTML file that contains the structure of the game.
  • css/styles.css: The CSS file that styles the game.
  • js/script.js: The JavaScript file that contains the game logic.
  • img/: Directory containing background images.
  • sounds/: Directory containing sound effects.

Contributing

Contributions are welcome! Please follow these steps to contribute:

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature-branch).
  3. Make your changes.
  4. Commit your changes (git commit -m 'Add some feature').
  5. Push to the branch (git push origin feature-branch).
  6. Open a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Explanation

  • Overview: Provides a brief description of the game.
  • Features: Lists the main features of the game.
  • Setup Instructions: Step-by-step instructions to set up the project locally.
  • Usage: Instructions on how to use the game.
  • Project Structure: Describes the directory structure and main files.
  • Contributing: Guidelines for contributing to the project.
  • License: Information about the project's license.