Skip to content
Notifications You must be signed in to change notification settings

velprakashr08-max/Defence-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

bfd8201 · · Feb 21, 2026

History

18 Commits
Feb 12, 2026
Feb 19, 2026
Feb 21, 2026
Feb 12, 2026
Feb 21, 2026
Feb 21, 2026
Feb 21, 2026
Feb 21, 2026
Feb 21, 2026

Repository files navigation

Defense-Game - 2 Player Fighting Game

I am Building this game to show my physics skills and also i am applying the concepts in js i have learned from past one year i had a keen interest in the simple game building using the programming language i have learnt.

i want all my friends to show love and share some ❤️ and appreciation for this.

i planned almost a month to build this game and i built it in a week working daily for 3+ hours and also i want to mention that i have used freemium tools to build this i want to be frank in this case but all i built was on my idea . i wish everyone likes it and share some love and your heartful votes so that it will be a reward for my hardwork over past few weeks. Finally If anyone loves to work with me post you like so that i can follow and connect to youou

If you want to share any thoughts and feedbacks you can share.

I also mentioned how to play conditions in the the how to play modal box so go through it before you start a game.

I have built a automated bot that fights with you. So i am currently planning to build a screen where you can share your code with your friend and then you and your friend can share a code and then play together.

A full-screen, responsive 2-player fighting game built with vanilla JavaScript!

Features

  • 2-player local multiplayer on the same keyboard
  • 300 health points with strategic combat
  • 30-second battle timer
  • Sound effects for attacks, hits, and victory
  • Responsive full-screen design

Controls

Player 1: A/D (move), W (jump), SPACE (attack) Player 2: Arrow keys (move/jump), DOWN arrow (attack) Special Keys: ESC(Pause/ Resume the game) , M(to view Stats), Q(quit the game), R(Replay).

Author's Note

The hardest part of this project was implementing the CPU opponent — I built an AI controller that lets the enemy play automatically, and I'm proud I figured it out. Completing this project helped me solidify core JavaScript concepts (game loops, canvas rendering, state management, and simple AI). If you try the game, I'd love to hear feedback — thanks for checking it out!out!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published