Skip to content

Commit

Permalink
manifest.json added, workbox modules added, null username bug fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
KudahShambare committed Jun 26, 2023
1 parent cfc4b97 commit 5672947
Show file tree
Hide file tree
Showing 13,564 changed files with 968,222 additions and 5 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
5 changes: 5 additions & 0 deletions howto.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="manifest" href="manifest.json">
<link rel="icon" type="image/jpeg" href="./Burger.jpeg">

<title>Game Rules</title>
</head>
<body>
Expand All @@ -20,6 +23,8 @@ <h1>How to play the game</h1>
<li>Every burger eaten results in a time increment of 10 seconds and a point incriment of 10 points as well</li>
<li>If you hit a wall you get a sscore decrement of 0</li>
<li>You can play the game for as long as you wish. If you decide to quit, you can just press the stop button.</li>
<li>For your name to appear in the leaderboard you have to score at least 100 points.</li>
<li> If you did not provide your name at the begining of the game, you will appear as <u>Stranger101</u> in the leader board </li>
</ul>
<h4>Enjoy the game!</h4>
</div>
Expand Down
4 changes: 3 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="style.css">
<link rel="manifest" href="manifest.json">
<link rel="icon" type="image/jpeg" href="./Burger.jpeg">
<title>Daggie</title>


Expand All @@ -23,7 +25,7 @@
<aside>
<a href="howto.html"> <h3>How to play the game</h3></a>


<a href="leaderboard.html"> <h3>Leaderboard</h3></a>
</aside>


Expand Down
13 changes: 12 additions & 1 deletion leaderboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="style.css">
<link rel="manifest" href="manifest.json">
<link rel="icon" type="image/jpeg" href="./Burger.jpeg">


<title>LeaderBoard</title>
</head>
Expand Down Expand Up @@ -35,11 +38,19 @@ <h1> Leaderboard </h1>
console.log(data)
data.map((elem) => {
let player = document.createElement("li");
player.setAttribute("id","playerScore");

if(elem.name == currentUser && elem.score == currentUserScore){
player.setAttribute("class", "my-score");
}
player.innerHTML = elem.name + " _________ " + elem.score;
let name = document.createElement("span");
let score = document.createElement("span");

name.innerHTML = elem.name;
score.innerHTML = elem.score;

player.appendChild(name);
player.appendChild(score);
list.appendChild(player);
})

Expand Down
23 changes: 23 additions & 0 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "Daggie",
"description": "A canvas based maze chase game",
"version": "1.0.0",
"author": "Kuda Shambare",
"homepage_url": "/",
"icons": [
{
"src": "./Burger.jpeg",
"sizes": "192x192",
"type": "image/png"
}
],
"start_url": "index.html",
"display": "standalone",
"theme_color": "#00b4d8",
"background_color": "#00b4d8",
"permissions": [
"geolocation",
"notifications"
],
"manifest_version": 2
}
1 change: 1 addition & 0 deletions node_modules/.bin/acorn

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/browserslist

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/ejs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/is-ci

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/jake

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/jsesc

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/json5

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/parser

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/rc

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/regjsparser

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/resolve

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/rollup

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/semver

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/terser

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/update-browserslist-db

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions node_modules/.bin/workbox

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 5672947

Please sign in to comment.