generated from nighthawkcoders/student_2025
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
30 lines (27 loc) · 762 Bytes
/
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Game with Text</title>
<style>
canvas {
border: 1px solid black;
}
</style>
</head>
<body>
<header></header>
<canvas id="gameCanvas" width="1038" height="580"></canvas>
<footer></footer>
<script type="module">
import GameEnv from './GameEnv.js';
import NpcAboutPage from './NpcAboutPage.js';
GameEnv.create();
const canvas = document.getElementById('gameCanvas');
const ctx = canvas.getContext('2d');
const npcAboutPage = new NpcAboutPage('');
npcAboutPage.draw(ctx);
</script>
</body>
</html>