index.html 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Fourteen Screws Engine</title>
  6. <style>
  7. body {
  8. position: absolute;
  9. top: 0;
  10. left: 0;
  11. margin: 0;
  12. width: 100%;
  13. height: 100%;
  14. display: flex;
  15. flex-direction: column;
  16. align-items: center;
  17. justify-content: center;
  18. }
  19. #canvas {
  20. width: 1280px;
  21. aspect-ratio: 8/5;
  22. }
  23. </style>
  24. <!-- Google tag (gtag.js) -->
  25. <script async src="https://www.googletagmanager.com/gtag/js?id=G-RY4PV833S2"></script>
  26. <script>
  27. window.dataLayer = window.dataLayer || [];
  28. function gtag(){dataLayer.push(arguments);}
  29. gtag('js', new Date());
  30. gtag('config', 'G-RY4PV833S2');
  31. </script>
  32. </head>
  33. <body style="text-align: center">
  34. <noscript>This page contains webassembly and javascript content, please enable javascript in your browser.</noscript>
  35. <div id="controls">w, s, a, d = forward, back, strafe left, strafe right | &uarr;, &darr;, &larr;, &rarr; = look up, look down, turn left, turn right</div>
  36. <div id="fps"></div>
  37. <canvas id="canvas" width="320" height="200"></canvas>
  38. <div id="joystick-left" style="width: 30%; aspect-ratio: 1; position: fixed; bottom: 0px; left: 0px; z-index: 99999"></div>
  39. <div id="joystick-right" style="width: 30%; aspect-ratio: 1; position: fixed; bottom: 0px; right: 0px; z-index: 99999"></div>
  40. <script src="./bootstrap.js"></script>
  41. <script src="./vendor/JoyStick/joy.min.js"></script>
  42. </body>
  43. </html>