-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
162 lines (156 loc) · 6.93 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
---
title: 8-bit Nintendo Science
---
<section class="header">
<div class="left">
<img src="assets/images/nes.gif">
</div>
<div class="title">
<h1>An Exhaustive and Definitive Ranking of All Nintendo Entertainment System Games Released in North America, Where We Determine Which Games Are the Absolute Pinnacle of 8-Bit Excellence and Which Ones Make You Question Life Choices, Ranked from Best to Worst</h1>
</div>
<div class="right">
<a id="random" title="Watch a random game">
<img src="assets/images/dancing-baby.gif">
</a>
</div>
</section>
<section class="the-list">
<table id="ranking" border="1">
<thead>
<tr>
<th class="rank" data-sort-method='number' data-sort-default>#</th>
<th class="title">Game</th>
<th class="year" data-sort-method='dotsep'>Year</th>
<th class="dev">Developer(s)</th>
<th class="license" data-sort-method='dotsep'><img class="seal" src="assets/images/licensed.png"></th>
<th class="ep" data-sort-method='dotsep'>Ep<span>isode</span></th>
<th class="timestamp" data-sort-method='dotsep'>Time</th>
</tr>
</thead>
<tbody>
{% for item in site.data.list %}
{% assign wiki_data = nil %}
{% assign screenshot = nil %}
{% assign licensed = true %}
{% if item.wiki_line %}
{% assign line = item.wiki_line | split: "_" %}
{% assign i = line[1] | to_integer %}
{% if line[0] == "l" %}
{% assign wiki_data = site.data.licensed_games[i] %}
{% else %}
{% assign wiki_data = site.data.unlicensed_games[i] %}
{% if wiki_data %}{% assign licensed = false %}{% endif %}
{% endif %}
{% endif %}
{% unless wiki_data %}
{% assign wiki_data = site.data.licensed_games | where: "title", item.game | first %}
{% endunless %}
{% unless wiki_data %}
{% assign wiki_data = site.data.unlicensed_games | where: "title", item.game | first %}
{% if wiki_data %}{% assign licensed = false %}{% endif %}
{% endunless %}
{% unless wiki_data %}
{% assign wiki_data = site.data.licensed_games | where_exp: "game", "game.title contains item.game" | first %}
{% endunless %}
{% unless wiki_data %}
{% assign wiki_data = site.data.unlicensed_games | where_exp: "game", "game.title contains item.game" | first %}
{% if wiki_data %}{% assign licensed = false %}{% endif %}
{% endunless %}
{% assign dev = wiki_data.developer %}
{% unless dev %}
{% assign dev = wiki_data.publisher %}
{% endunless %}
{% if item.screenshot %}
{% assign screenshot = item.screenshot %}
{% else %}
{% assign search = item.game | replace: ":", " -" %}
{% assign libretro_file = site.data.libretro | where_exp: "i", "i.filename contains search" | first %}
{% if libretro_file %}
{% assign screenshot = libretro_file.filename %}
{% endif %}
{% endif %}
<tr>
<td class="rank" data-sort="{{ forloop.index }}">
{% if forloop.index == 1 %}
<img class="medal" src="assets/images/gold.gif">
{% elsif forloop.index == 2 %}
<img class="medal" src="assets/images/silver.gif">
{% elsif forloop.index == 3 %}
<img class="medal" src="assets/images/bronze.gif">
{% else %}
{{ forloop.index }}
{% endif %}
</td>
<td class="title">
<div class="title-wrapper">
{% if screenshot %}
<img class="screenshot titlescreen" loading="lazy" data-action="zoom"
src="https://wsrv.nl/?h=240&output=png&url=raw.githubusercontent.com/libretro-thumbnails/Nintendo_-_Nintendo_Entertainment_System/refs/heads/master/Named_Titles/{{ screenshot }}"
><img class="screenshot" loading="lazy" data-action="zoom"
src="https://wsrv.nl/?h=240&output=png&url=raw.githubusercontent.com/libretro-thumbnails/Nintendo_-_Nintendo_Entertainment_System/refs/heads/master/Named_Snaps/{{ screenshot }}"
>
{% endif %}
<div class="name" title="{{ wiki_data.title }}">
{{ item.game }}
</div>
</div>
</td>
<td class="year" data-sort="{{ wiki_data.year }}.{{ forloop.index }}">
{{ wiki_data.year }}
</td>
<td class="dev">
{% if dev %}
{% assign companies = dev | newline_to_br | split: "<br />" %}
<ul>
{% for company in companies %}
<li>{{company}}</li>
{% endfor %}
</ul>
{% endif %}
</td>
<td class="license" data-sort="{{ licensed | to_integer }}.{{ forloop.index }}">
{% if licensed %}
<img class="seal" src="assets/images/licensed.png">
{% endif %}
</td>
<td class="ep" data-sort="{{ item.ep }}.0.{{ forloop.index }}">
{% if item.ytid %}
<a href="https://www.youtube.com/watch?v={{ item.ytid }}">
<img class="thumbnail" loading="lazy"
src="https://wsrv.nl/?url=i.ytimg.com/vi/{{ item.ytid }}/default.jpg"
>{{ item.ep | replace: ".", "-" }}
</a>
{% else %}
{{ item.ep | replace: ".", "-" }}
{% endif %}
</td>
<td class="timestamp" data-sort="{{ item.ep }}.0.{{ item.seconds }}">
{% if item.ytid and item.seconds %}
<a href="https://www.youtube.com/watch?v={{ item.ytid }}&t={{ item.seconds }}s">
{{ item.seconds | date: "%H:%M:%S"}}
</a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
<img class="garfield" src="assets/images/garfield.png">
</section>
<img class="divider" src="assets/images/electricbar.gif">
<center>
<a class="test-link" href="/test.html"><img src="assets/images/test.gif"></a>
</center>
<section class="about">
<h2>The list is
<img src="assets/images/under-construction.gif" width="120">.
See the <a href="./remaining.html">remaining</a> games.
</h2>
<p>
This page is maintained by fans and is updated as Dr. Jeff Gerstmann, Man of Science, proceeds in his work of <code>#BuildingTheList</code>. You can watch science in action live on <a href="https://www.twitch.tv/jeffgerstmann">twitch.tv/jeffgerstmann</a> or check out previous episodes on <a href="https://www.youtube.com/playlist?list=PLDKeuvgV0sxZ_xs4zUvQcMEV-LTjSf-Ok">youtube.com/TheJeffGerstmannShow</a>.
</p>
<p>If any information is missing or incorrect, consider submiting a fix to our <a href="https://github.com/vNakamura/8bitnintendo-science">GitHub repository</a>.
</p>
<p>
Game details (developer, release date, ...) from <a href="https://en.wikipedia.org/wiki/List_of_Nintendo_Entertainment_System_games">Wikipedia</a>. Game images from <a href="https://github.com/libretro-thumbnails/libretro-thumbnails">Libretro</a>.
</section>