master
*anna* 4 years ago
parent d65aec5dfe
commit d8809e92a3

@ -73,11 +73,11 @@
<script>
//get player avatar from local storage
console.log (localStorage.myavatar)
/*console.log (localStorage.myavatar)
var img = document.createElement("img");
img.src = localStorage.myavatar;
var player_img = document.querySelector("#player_img");
player_img.appendChild(img);
player_img.appendChild(img);*/
//store that you've been in the park

Binary file not shown.

@ -113,10 +113,16 @@ you can press
<script>
//clear local storage when back on the landing page
/*
window.onload = function() {
window.localStorage.clear();
}
}*/
document.addEventListener("DOMContentLoaded", function () {
window.localStorage.clear();
console.log("loaded");
updateAvatar();
});
</script>

@ -29,7 +29,6 @@ function updateAvatar () {
var avatar=fd.get("player_avatar")
console.log("avatar", avatar);
localStorage.myavatar=avatar;
}
// store username in local storage + make sure the player added their preferences, if yes it redirect to the following page

@ -144,20 +144,23 @@ span.button_text{
padding-bottom: 5px;
font-family: sinistre;
background-color: white;
border: 0.11vw black solid;
border: 1px black solid;
border-radius: 25vw;
color:black;
cursor:pointer;
font-size: 1.4vw;
}
.glass_appear{
animation-name: appear;
animation-duration: 0.2s;
}
@keyframes appear {
0% {top: 80px;}
25% {top: 90px;}
25% {top: 85px;}
50% {top: 80px;}
75% {top: 90px;}
75% {top: 95px;}
100% {top: 80px;}
}
@ -302,7 +305,7 @@ span.button_text{
}
.bubble1 {
right: 24%;
top:18%;
bottom:54%;
position: absolute;
background: #ffffff;
color: #000000;
@ -345,7 +348,7 @@ span.button_text{
.bubble2 {
right: 24%;
top:18%;
bottom:54%;
position: absolute;
background: #ffffff;
color: #000000;

@ -165,7 +165,7 @@ $(document).keydown(function(e) {
break;
}
//check the offset and prevent the character to exceed the screen dimension
//check the offset and prevent the character from exceeding screen dimension
if (offset.left < 80) {
offset.left = 80;
}
@ -179,6 +179,7 @@ $(document).keydown(function(e) {
$('.bubble1').show();
setTimeout( function() {
$('.glasses_bar').show();
$('.glasses_bar').addClass("glass_appear");
}, 3000);
}, 2000);
}

Loading…
Cancel
Save