background

This commit is contained in:
pbg2h23akl 2024-09-03 11:20:32 +02:00
parent 02bfc04ef6
commit 60d36f4a7a
4 changed files with 19 additions and 5 deletions

View File

@ -7,9 +7,9 @@ body{
} }
#spielRaum{ #spielRaum{
width: 1000px; width: 1000px;
height: 700px; height: 800px;
margin: auto; margin: auto;
background-color: yellow; background-image: url("../pics/background.jpg");
position: relative; position: relative;
} }
body{ body{
@ -45,6 +45,13 @@ body{
} }
#enemyZahl{ #enemyZahl{
text-align: center; text-align: center;
color: white;
text-shadow:
2px 2px 2px black,
-2px 2px 2px black,
2px -2px 2px black,
-2px -2px 2dvi black;
font-weight: bold;
} }
.flexbox{ .flexbox{
display: flex; display: flex;
@ -79,9 +86,16 @@ body{
} }
#fuchsZahl{ #fuchsZahl{
padding-left: 100px; padding-left: 100px;
font-size: 30px; font-size: 40px;
font-weight: bold;
width: 10%; width: 10%;
z-index: 59; z-index: 59;
color: white;
text-shadow:
2px 2px 2px black,
-2px 2px 2px black,
2px -2px 2px black,
-2px -2px 2dvi black;
} }
#hitbox1, #hitbox2{ #hitbox1, #hitbox2{
width: 50px; width: 50px;

View File

@ -5,7 +5,7 @@ let enemyAnim = [];
//player //player
let playerAnimState = 0; let playerAnimState = 0;
let runDirection = 0; let runDirection = 0;
let runSpeed = 12; let runSpeed = 20;
let animationSpeed = 50; let animationSpeed = 50;
let currentPosition = 0; let currentPosition = 0;
let player = document.querySelector("#fuchs"); let player = document.querySelector("#fuchs");

View File

@ -6,7 +6,7 @@ let rechnungenTop = rechnungenTopStart;
rechnungen.style.top = rechnungenTop + "px"; rechnungen.style.top = rechnungenTop + "px";
//speed der Rechnungen, wie schnell sie fallen //speed der Rechnungen, wie schnell sie fallen
const speedRechnungen = 0.2; const speedRechnungen = 0.5;
//maximale pixel Tiefe bis sie respawnen //maximale pixel Tiefe bis sie respawnen
const maxTiefeRechunngen = 750; const maxTiefeRechunngen = 750;

BIN
pics/background.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 763 KiB