-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
48 lines (47 loc) · 1.52 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>PowderRS</title>
<style>
body {
margin: 0;
font-family: sans-serif;
}
canvas {
margin: auto;
background-color: black;
}
</style>
</head>
<body>
<script type="module">
import init from "./pkg/powder_rs.js";
init().then(() => {
console.log("WASM Loaded");
setTimeout(() => {
document.getElementsByTagName("canvas")[0].oncontextmenu = () => {
return false;
}
}, 1000);
});
</script>
<div id="powderrs">
</div>
<p>
<h2> ⌨️ Controls </h2> <br/>
<b>LMB</b> - Place sand <br/>
<b>RMB</b> - Erase <br/>
<b>Space</b> - Pause game <br/>
<b>F</b> - Advance by one frame when paused <br/>
<b>Scroll</b> - Change brush size <br/>
<b>Shift + Scroll</b> - Change brush size faster <br/>
<b>Ctrl + Scroll</b> - Zoom <br/>
<b>MMB + Move Mouse</b> - Move the camera <br/>
<b>G + Scroll</b> - Change grid size <br/>
<b>L</b> - Reset Camera <br/>
</p>
</body>
</html>