forked from mikebryant/ac-nh-turnip-prices
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
294 lines (259 loc) · 10.2 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
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Animal Crossing - Turnip Prophet</title>
<meta name="description" content="Animal Crossing - Turnip Prophet">
<meta name="author" content="Mike Bryant">
<link rel="stylesheet" href="css/styles.css">
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-162470902-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'UA-162470902-1');
</script>
</head>
<body>
<div class="dialog-box">
<h2 class="dialog-box__name">Daisy Mae</h2>
<p>Hello, and welcome to the <b>Turnip Prophet</b> app on your Nook Phone.</p>
<p>This app lets you track your island's turnip prices daily, but you'll have to put the prices in yourself!
</p>
<p>After that, the Turnip Prophet app will <b>magically</b> predict the turnip prices you'll have for the rest of
the week.
</p>
</div>
<div class="nook-phone">
<h1>Turnip Prophet</h1>
<div>
<svg class="waves" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 24 150 28" preserveAspectRatio="none" shape-rendering="auto">
<defs>
<path id="gentle-wave" d="M-160 44c30 0 58-18 88-18s 58 18 88 18 58-18 88-18 58 18 88 18 v44h-352z" />
</defs>
<g class="parallax">
<use xlink:href="#gentle-wave" x="48" y="0" fill="rgba(255,255,255,0.6" />
<use xlink:href="#gentle-wave" x="48" y="3" fill="rgba(255,255,255,0.4)" />
<use xlink:href="#gentle-wave" x="48" y="5" fill="rgba(255,255,255,0.2)" />
<use xlink:href="#gentle-wave" x="48" y="7" fill="#fff" />
</g>
</svg>
</div>
<div class="nook-phone-center">
<form class="input__form">
<div class="form__row">
<h6>First-Time Buyer</h6>
<div class="input__group">
<label>Is this your first time buying turnips from Daisy Mae on your island?<i>(This affects your
pattern)</i></label>
<div class="input__radio-buttons">
<input type="radio" id="first-time-radio-no" name="first-time" value="false" checked>
<label for="first-time-radio-no">No</label>
<input type="radio" id="first-time-radio-yes" name="first-time" value="true">
<label for="first-time-radio-yes">Yes</label>
</div>
</div>
</div>
<div class="form__row">
<h6>Previous Pattern</h6>
<div class="input__group">
<label for="">What was last week's turnip price pattern?<i>(This affects your pattern)</i></label>
<div class="input__radio-buttons">
<input type="radio" id="pattern-radio-unknown" name="pattern" value="-1" checked>
<label for="pattern-radio-unknown">I don't know</label>
<input type="radio" id="pattern-radio-fluctuating" name="pattern" value="0">
<label for="pattern-radio-fluctuating">Fluctuating</label>
<input type="radio" id="pattern-radio-small-spike" name="pattern" value="3">
<label for="pattern-radio-small-spike">Small Spike</label>
<input type="radio" id="pattern-radio-large-spike" name="pattern" value="1">
<label for="pattern-radio-large-spike">Large Spike</label>
<input type="radio" id="pattern-radio-decreasing" name="pattern" value="2">
<label for="pattern-radio-decreasing">Decreasing</label>
</div>
</div>
</div>
<div class="form__row">
<h6>Sunday</h6>
<div class="input__group">
<label>What was the price of turnips this week? <i>(If this is your first time buying turnips, this field
will be disabled)</i></label>
<input type="number" id="buy" placeholder="..." />
</div>
</div>
<i>AM - 8:00 am to 11:59 am</i>
<i>PM - 12:00 pm to 10:00 pm</i>
<div class="form__flex-wrap">
<div class="form__row">
<h6>Monday</h6>
<div class="input__group">
<label for="sell_2">AM</label>
<input type="number" id="sell_2" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_3">PM</label>
<input type="number" id="sell_3" placeholder="..." />
</div>
</div>
<div class="form__row">
<h6>Tuesday</h6>
<div class="input__group">
<label for="sell_4">AM</label>
<input type="number" id="sell_4" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_5">PM</label>
<input type="number" id="sell_5" placeholder="..." />
</div>
</div>
<div class="form__row">
<h6>Wednesday</h6>
<div class="input__group">
<label for="sell_6">AM</label>
<input type="number" id="sell_6" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_7">PM</label>
<input type="number" id="sell_7" placeholder="..." />
</div>
</div>
<div class="form__row">
<h6>Thursday</h6>
<div class="input__group">
<label for="sell_8">AM</label>
<input type="number" id="sell_8" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_9">PM</label>
<input type="number" id="sell_9" placeholder="..." />
</div>
</div>
<div class="form__row">
<h6>Friday</h6>
<div class="input__group">
<label for="sell_10">AM</label>
<input type="number" id="sell_10" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_11">PM</label>
<input type="number" id="sell_11" placeholder="..." />
</div>
</div>
<div class="form__row">
<h6>Saturday</h6>
<div class="input__group">
<label for="sell_12">AM</label>
<input type="number" id="sell_12" placeholder="..." />
</div>
<div class="input__group">
<label for="sell_13">PM</label>
<input type="number" id="sell_13" placeholder="..." />
</div>
</div>
</div>
<button id="reset" class="reset-button" name="action">
Reset Turnip Prophet
</button>
</form>
<h2>Output</h2>
<div class="table-wrapper">
<table id="turnipTable">
<thead>
<tr>
<th valign="bottom">Pattern</th>
<th valign="bottom">% Chance</th>
<th valign="bottom">Sunday</th>
<th colspan="2">
<div>Monday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</th>
<th colspan="2">
<div>Tuesday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</th>
<th colspan="2">
<div>
<div>Wednesday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</div>
</th>
<th colspan="2">
<div>Thursday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</th>
<th colspan="2">
<div>Friday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</th>
<th colspan="2">
<div>Saturday</div>
<div>
<span>AM</span>
<span>PM</span>
</div>
</th>
<th valign="bottom">Guaranteed Minimum</th>
<th valign="bottom">Potential Maximum</th>
</tr>
</thead>
<tbody id="output"></tbody>
</table>
</div>
</div>
<div style="transform:rotate(180deg)">
<svg class="waves" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 24 150 28" preserveAspectRatio="none" shape-rendering="auto">
<defs>
<path id="gentle-wave" d="M-160 44c30 0 58-18 88-18s 58 18 88 18 58-18 88-18 58 18 88 18 v44h-352z" />
</defs>
<g class="parallax">
<use xlink:href="#gentle-wave" x="48" y="0" fill="rgba(255,255,255,0.6" />
<use xlink:href="#gentle-wave" x="48" y="3" fill="rgba(255,255,255,0.4)" />
<use xlink:href="#gentle-wave" x="48" y="5" fill="rgba(255,255,255,0.2)" />
<use xlink:href="#gentle-wave" x="48" y="7" fill="#fff" />
</g>
</svg>
</div>
</div>
<div class="dialog-box">
<h2 class="dialog-box__name">Daisy Mae</h2>
<p>After you've listed some turnip prices, the Turnip Prophet will run some numbers and display the different
possible patterns that your island may experience.</p>
<p>This app is still in development, but will improve over time!</p>
</div>
<div class="dialog-box">
<h2 class="dialog-box__name">Daisy Mae</h2>
<p>
None of this would have been possible without <a
href="https://twitter.com/_Ninji/status/1244818665851289602?s=20">Ninji's work</a> figuring out just how Timmy
and Tommy value their turnips.
</p>
<p>
Support, comments and contributions are available through <a
href="https://github.com/mikebryant/ac-nh-turnip-prices/issues">Github</a>
</p>
</div>
<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<script src="js/predictions.js"></script>
<script src="js/scripts.js"></script>
</body>
</html>