forked from opengaming/osgameclones
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
171 lines (151 loc) · 6.16 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="author" content="Vsevolod Solovyov">
<meta name="keywords" content="open source, game, clone, remake, remakes">
<meta name="description" content="List of open source clones of popular old-school games.">
<meta name="application-name" content="OS Game Clones">
<meta name="application-url" content="http://osgameclones.com/">
<link rel="stylesheet" href="static/main.css">
<title>Open Source Game Clones</title>
</head>
<body>
<header><h1>Open Source Game Clones</h1></header>
<article>
<p>
This site tries to gather open-source reimplementations of great old games
in one place. If you think that some information is missing or have any
suggestions - send a pull request
via <a href="http://github.com/piranha/osgameclones/">Github</a> or a mail to
<a href="mailto:alexander@solovyov.net">me</a>.
</p>
<p>
Since all these projects are open-source you can help them and make this
world a better place. Or at least you can play something to appreciate the
effort people put in them.
</p>
<p>
Similar resources: check
out <a href="http://www.liberatedgames.com/">Liberated Games</a>, which
specializes on commercial games, which were made free,
and <a href="http://freegamer.blogspot.com/">Free Gamer</a>, a blog
dedicated to open source game news.
</p>
<p class="new">All games that were added in last month are highlighted like this.</p>
</article>
<div>
<input id="filter" type="text" placeholder="Type to filter by name or information">
</div>
{% macro render(names, items, mode) %}
{% for name in names %}
{%- if name|length == 2 -%}
{% set name, wiki = name %}
{%- else -%}
{% set wiki = name %}
{%- endif -%}
<dt {% if not loop.index0 %}id="{{ name }}-{{ mode }}"{% endif -%} class="searchable">
<a href="http://en.wikipedia.org/wiki/{{ wiki }}">{{ name }}</a>
{% if not loop.index0 %}<a href="#{{ name }}-{{ mode }}" class="hash">#</a>{% endif %}
</dt>
{% endfor %}
{% for game in items %}
<dd class="searchable {% if game.new %}new{% endif %}"
data-index="{{ names|join(' ')|lower|e }}
{{ game['name']|lower|e }}
{{ game['info']|lower|e }}">
<span class="{% if 'media' in game %}toggler{% else %}notoggler{% endif %}">▶</span>
<a href="{{ game['url'] }}">{{ game['name'] }}</a> - {{ game['info'] }}
{%- if 'repo' in game %} (<a href="{{ game['repo'] }}">repository</a>){% endif %}.
<script type="text/screenshots">
{% for item in game.get('media', []) %}
{% if 'raw' in item %}{{ item['raw'] }}{% endif %}
{% if 'image' in item -%}
<a {%- if 'url' in item %} href="{{ item['url'] }}" {%- endif %}><img src="{{ item['image'] }}"></a>
{%- endif %}
{% endfor %}
</script>
</dd>
{% endfor %}
{% endmacro %}
<h2>List of complete clones</h2>
<article>Some of these games aren't reimplementations but evolution of original ones, which were eventually open sourced.</article>
<dl>
{% for names, items in site.clones %}
{{ render(names, items, 'clones') }}
{% endfor %}
</dl>
<h2>Inspired by original game series</h2>
<dl>
{% for names, items in site.reimplementations %}
{{ render(names, items, 'inspired') }}
{% endfor %}
</dl>
<footer>© 2011-2013
<a href="mailto:vsevolod.solovyov@gmail.com">Vsevolod Solovyov</a>,
<a href="mailto:alexander@solovyov.net">Alexander Solovyov</a>
</footer>
<style id="filter-style">
</style>
<script type="text/javascript">
// screenshot handling
(function() {
var onclick = function() {
var screenshots = this.parentNode.getElementsByTagName("script");
if (screenshots.length) {
var innerHTML = '<div class="screenshots" style="display: none">' +
screenshots[0].innerHTML + '</div>';
this.parentNode.insertAdjacentHTML('beforeend', innerHTML);
this.parentNode.removeChild(screenshots[0]);
}
screenshots = this.parentNode.getElementsByClassName("screenshots")[0];
var show_now = screenshots.style.display == "none";
this.innerHTML = show_now ? "▼" : "▶";
screenshots.style.display = show_now ? "block" : "none";
}
var els = document.getElementsByClassName("toggler");
for (var i = 0, l = els.length; i < l; i++) {
els[i].addEventListener("click", onclick);
}
})();
// search handling
(function() {
// collect indexes on dt
var nodes = document.getElementsByTagName('dt');
for (var i = 0, l = nodes.length; i < l; i++) {
var el = nodes[i], next = el, index = [];
while ((next = next.nextElementSibling) && !next.id) {
if (next.tagName != 'DD')
continue;
index.push(next.getAttribute('data-index'));
}
el.setAttribute('data-index', index.join(' '));
};
var getfilter = function(term) {
return !term ? "" :
'[data-index*="' + term.toLowerCase().replace('"', '') + '"]';
}
var style = document.getElementById('filter-style');
document.getElementById('filter').addEventListener('input', function() {
if (!this.value) {
style.innerHTML = "";
return;
}
style.innerHTML =
".searchable {display: none} .searchable" +
this.value.split(' ').map(getfilter).join('') +
"{display: block}";
});
})();
</script>
<script type="text/javascript">
var _gaq = [['_setAccount', 'UA-23716824-1'], ['_trackPageview']];
setTimeout("_gaq.push(['_trackEvent', '15_seconds', 'read'])", 15000);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
</body>
</html>