forked from arielger/electronic-life-js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
44 lines (42 loc) · 1.11 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
<html>
<head>
<meta charset="UTF-8">
<title>Electronic life</title>
<style>
body, *{
font-family: monospace;
font-size: 16px;
margin-left: 15px;
}
ul{
list-style-type: none;
margin: 0;
padding: 0;
}
</style>
</head>
<body>
<div class="info">
<h1>Electronic life</h1>
<p>Simple project for <a href="http://eloquentjavascript.net/">Eloquent Javascript book</a> - Chapter 7</p>
<p>Made by <a href="https://twitter.com/arigers">@arigers</a></p>
<button onclick="setMapInterval();">Run</button>
<button onclick="clearInterval(int); mapRefreshState = false;">Stop</button>
<button onclick="refreshMap();">Turn</button>
</div>
<pre>
<div id="world"></div>
</pre>
<div>
<ul>
<li># - Wall</li>
<li>o - Plant eater (eat plants)</li>
<li>Ö - Tiger (eat the plant-eaters)</li>
<li>* - Plant (reproduce / give energy)</li>
</ul>
</div>
<script type="text/javascript" src="js/world.js"></script>
<script type="text/javascript" src="js/entities.js"></script>
<script type="text/javascript" src="js/common.js"></script>
</body>
</html>