Files
wasm-pong/www/index.html
2022-05-02 13:15:21 +02:00

41 lines
1.0 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Hello wasm-pack!</title>
<style>
body {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
overflow: hidden;
}
</style>
</head>
<body>
<noscript>This page contains webassembly and javascript content, please enable javascript in your browser.</noscript>
<div>
<button id="pause-btn" onclick="WASM_PONG.pauseGame()">
Pause
</button>
<button id="resume-btn" onclick="WASM_PONG.resumeGame()" disabled>
Resume
</button>
<button id="tick-btn" onclick="WASM_PONG.oneTick()" disabled>
Tick
</button>
<button id="debug-btn" onclick="WASM_PONG.toggleDebug()">
Debug
</button>
</div>
<canvas id="wasm-app-canvas"></canvas>
<script src="./bootstrap.js"></script>
</body>
</html>