82 lines
2.2 KiB
HTML
82 lines
2.2 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="fr">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Bubble Bobble JS</title>
|
|
<style>
|
|
body {
|
|
margin: 0;
|
|
padding: 20px;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
background-color: #87CEEB;
|
|
font-family: Arial, sans-serif;
|
|
}
|
|
|
|
#gameContainer {
|
|
position: relative;
|
|
border: 3px solid #333;
|
|
background-color: #000;
|
|
}
|
|
|
|
#gameCanvas {
|
|
background-color: #000;
|
|
}
|
|
|
|
#ui {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
width: 800px;
|
|
margin-top: 10px;
|
|
color: white;
|
|
font-size: 20px;
|
|
font-weight: bold;
|
|
}
|
|
|
|
#controls {
|
|
margin-top: 20px;
|
|
color: white;
|
|
text-align: center;
|
|
}
|
|
|
|
button {
|
|
padding: 10px 20px;
|
|
font-size: 16px;
|
|
background-color: #4CAF50;
|
|
color: white;
|
|
border: none;
|
|
border-radius: 5px;
|
|
cursor: pointer;
|
|
margin: 5px;
|
|
}
|
|
|
|
button:hover {
|
|
background-color: #45a049;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<h1 style="color: white;">Bubble Bobble JS</h1>
|
|
|
|
<div id="ui">
|
|
<div>Score: <span id="score">0</span></div>
|
|
<div>Vies: <span id="lives">3</span></div>
|
|
<div>Niveau: <span id="level">1</span></div>
|
|
</div>
|
|
|
|
<div id="gameContainer">
|
|
<canvas id="gameCanvas" width="800" height="600"></canvas>
|
|
</div>
|
|
|
|
<div id="controls">
|
|
<p>Contrôles: Flèches pour déplacer, ESPACE pour sauter, CTRL pour tirer des bulles</p>
|
|
<button onclick="startGame()">Nouvelle Partie</button>
|
|
<button onclick="pauseGame()">Pause</button>
|
|
</div>
|
|
|
|
<script src="game.js"></script>
|
|
</body>
|
|
</html> |