-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
62 lines (58 loc) · 1.88 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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<script src="https://cdn.jsdelivr.net/npm/p5@1.4.1/lib/p5.js"></script>
<script src="build/scripts/main.js" type="text/javascript"></script>
<script src="build/scripts/classes.js" type="text/javascript"></script>
<link rel="stylesheet" href="build/css/styles.css" />
</head>
<body>
<div class="grid-container">
<div id="description">
<h1>Ant colony simulation</h1>
<p>
Ants scavenge for food resources. Once they find it, they return back
to the nest following the best path they were able to find.
</p>
<p>Cells become darker as ants step on them.</p>
<p>
<a href="https://github.com/fabrizzio-gz/ant_colony_simulation"
>Source code</a
>
</p>
</div>
<div id="canvas-container"></div>
<div id="legend">
<h2>Legend</h2>
<ul>
<li>
<div class="color-box nest"></div>
Nest
</li>
<li>
<div class="color-box ants"></div>
Ants
</li>
<li>
<div class="color-box food"></div>
Food
</li>
<li>
<div class="color-box obstacles"></div>
Obstacles
</li>
</ul>
</div>
<div class="button-container">
<button id="slow-button" onclick="slow()">slow</button>
<button id="normal-button" onclick="normalSpeed()">normal</button>
<button id="fast-button" onclick="fast()">fast</button>
<button id="reset-button" onclick="resetSimulation()">reset</button>
<button id="toggle-button" onclick="toggle()">toggle</button>
<button id="ff-button" onclick="ff()">ff</button>
<button id="step-button" onclick="step()">step</button>
</div>
</div>
</body>
</html>