This is a basic implementation of the Konami Frogger game, but it's missing a few things intentionally and they're left as further exploration for the reader.
- Lives
- Frogger starts with 6 lives and should lose a life whenever it is hit by a vehicle or lands in the water
- Timer
- The player has 30 seconds to get Frogger to the end bank. Display the timer as a reverse progress bar
- Timer resets when player gets to the end bank or dies
- Score
- Each time Frogger makes it to the end bank it should score points according to a few factors (see https://en.wikipedia.org/wiki/Frogger#Scoring). Use context.fillText() to display the score to the screen
- Every 20,000 should award another life
- Mobile and touchscreen support
- Allow the game to be scaled down to a phone size. See https://codepen.io/straker/pen/VazMaL
- Support touch controls
Important note: I will answer questions about the code but will not add more features or answer questions about adding more features. This series is meant to give a basic outline of the game but nothing more.
(CC0 1.0 Universal) You're free to use this game and code in any project, personal or commercial. There's no need to ask permission before using these. Giving attribution is not required, but appreciated.
- Snake
- Pong
- Breakout
- Tetris
- Bomberman
- Missile Command
- Sokoban
- Doodle Jump
- Puzzle Bobble
- Helicopter
- Block Dude
Basic HTML Games are made possible by users like you. When you become a Patron, you get access to behind the scenes development logs, the ability to vote on which games I work on next, and early access to the next Basic HTML Game.
- Karar Al-Remahy
- UnbrandedTech
- Innkeeper Games