All checks were successful
DEPLOY / deploy (push) Successful in 7s
- Create TP3.html to provide the game interface with two game modes. - Implement TP3.js to handle game logic, including number generation and user interactions.
34 lines
1.3 KiB
HTML
34 lines
1.3 KiB
HTML
<head>
|
|
<meta name="Acceuil">
|
|
<meta charset="UTF-8">
|
|
<link rel="stylesheet" href="static/style.css">
|
|
</head>
|
|
<body>
|
|
<div id="main">
|
|
<div id="game_selection">
|
|
<button type="" onclick="setup_game_one()">Game 1 : You guess</button>
|
|
<button type="" onclick="setup_game_two()">Game 2 : The computer guesses</button>
|
|
</div>
|
|
<div id="game_one" class="hidden">
|
|
<h3> Which number am i thinking about ? :)</h3>
|
|
<p id="message1"></p>
|
|
<input type="text" id="player_input" placeholder="type here">
|
|
<button type="button" onclick="process_guess()" >Try guess</button>
|
|
<button type="button" onclick="setup_game_one()">Retry game</button>
|
|
<button type="button" onclick="back()">Back to game selection</button>
|
|
</div>
|
|
<div id="game_two" class="hidden">
|
|
<h3> Which number are you thinking about ? :)</h3>
|
|
<p id="message2">is it big placeholder</p>
|
|
<button type="button" onclick="lower()">Lower</button>
|
|
<button type="button" onclick="greater()">Greater</button>
|
|
<button type="button" onclick="found()">Found</button>
|
|
<button type="button" onclick="setup_game_two()">Retry game</button>
|
|
<button type="button" onclick="back()">Back to game selection</button>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
|
|
|
|
<script src="static/js/TP3.js" defer></script>
|