index.html 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <link rel="stylesheet" type="text/css" media="screen" href="./assets/game-C4P66qFB.css" />
  7. <link rel="stylesheet" type="text/css" media="screen and (max-width: 1023px)" href="data:text/css;base64,I2JyZXctcmlnaHQtc2lkZSB7DQogICAgYm90dG9tOiA2MHB4Ow0KICAgIHJpZ2h0OiAwOw0KICAgIHdpZHRoOiBjYWxjKDEwMCUgLSA0MnB4KTsNCiAgICBtYXJnaW46IDE0cHg7DQogICAgbWluLXdpZHRoOiBhdXRvOw0KfQ0KDQojYnJldy1oZWFkZXItY29udGFpbmVyIGgxIHsNCiAgICBtYXJnaW46IDEycHg7DQogICAgZm9udC1zaXplOiAyNHB4Ow0KfQ0KDQojYnJldy1pbmdyZWRpZW50cy1jb250YWluZXIgew0KICAgIGhlaWdodDogODBweDsNCiAgICBtYXJnaW46IDhweCAxNXB4Ow0KICAgIGdhcDogNnB4Ow0KICAgIGp1c3RpZnktY29udGVudDogc3BhY2UtYXJvdW5kOw0KICAgIG1pbi13aWR0aDogYXV0bzsNCiAgICANCn0NCg0KLmluZ3JlZGllbnQtY29udGFpbmVyIHsNCiAgICBib3JkZXI6IDJweCBkYXNoZWQgI2RlYzhhZDsNCiAgICBwYWRkaW5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Q0KDQojcG90aW9uLWljb24gew0KICAgIGJvcmRlci1yYWRpdXM6IDUwcHg7DQp9DQoNCiNwb3Rpb24tZGVzY3JpcHRpb24gaDIgew0KICAgIHRleHQtYWxpZ246IGNlbnRlcjsNCiAgICBmb250LXNpemU6IDIwcHg7DQp9DQoNCnVsI3BvdGlvbi1wcm9wZXJ0aWVzLWxpc3Qgew0KICAgIGxpc3Qtc3R5bGU6IG5vbmU7DQogICAgbWFyZ2luOiA0cHggMDsNCn0NCg0KdWwjcG90aW9uLXByb3BlcnRpZXMtbGlzdCBsaSB7DQogICAgZm9udC1zaXplOiAxNHB4Ow0KfQ0KDQojYnJldy1idXR0b24tY29udGFpbmVyIHsNCiAgICBtYXJnaW4tbGVmdDogYXV0bzsNCiAgICBtYXJnaW4tcmlnaHQ6IGF1dG87DQogICAgd2lkdGg6IDgwJTsNCn0NCg0KI2JyZXctYnV0dG9uLWlubmVyLWNvbnRhaW5lciB7DQogICAgcG9zaXRpb246IHJlbGF0aXZlOw0KICAgIHJpZ2h0OiBhdXRvOw0KICAgIHBhZGRpbmc6IDJweDsNCiAgICBtYXJnaW4tdG9wOiAyNXB4Ow0KICAgIGJvcmRlci1yYWRpdXM6IDMycHg7DQogICAgd2lkdGg6IDEwMCU7DQogICAgYmFja2dyb3VuZC1jb2xvcjogI2E5NGU4MzsNCn0NCg0KI2JyZXctYnV0dG9uLWNvbnRhaW5lciBidXR0b24gew0KICAgIGZvbnQtc2l6ZTogMjBweDsNCiAgICB3aWR0aDogMTAwJTsNCn0=" />
  8. <link rel="stylesheet" type="text/css" href="./index.css" />
  9. <link rel="icon" type="image/icon" href="./favicon.ico">
  10. <title>Spookonomics: The Witch's Brew</title>
  11. <meta property="og:title" content="Spookonomics: The Witch's Brew - Halloween 2024" />
  12. <meta property="og:description"
  13. content="A browser-based game of mysterious potions and spooky capitalism. A humble witch gathers ingredients and brews speciality potions for her supernatural clientele." />
  14. <meta property="og:image" content="https://eyeofmidas.com/spookonomics/og_image.png" />
  15. <meta property="og:url" content="https://eyeofmidas.com/spookonomics" />
  16. <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
  17. <link rel="preconnect" href="https://fonts.googleapis.com">
  18. <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  19. <link href="https://fonts.googleapis.com/css2?family=Alice&family=Quicksand&display=swap" rel="stylesheet">
  20. <script type="module" crossorigin src="./assets/index-csb9Ss07.js"></script>
  21. <link rel="stylesheet" crossorigin href="./assets/index-DbRzRqfP.css">
  22. </head>
  23. <body>
  24. <div id="loading">
  25. <div id="loading-inner"><img src="./loading_ghost.gif" />loading...</div>
  26. </div>
  27. <canvas class="webgl"></canvas>
  28. <div id="main-menu-container">
  29. <div id="main-menu-display">
  30. <div id="main-menu-header-container">
  31. <h1 id="main-menu-title">Spookonomics</h1>
  32. <h2 id="main-menu-subtitle">The Witch's Brew</h2>
  33. </div>
  34. <div id="main-menu-button-list">
  35. <div class="button-inner-container primary">
  36. <button id="play-button" class="primary">Play</button>
  37. </div>
  38. <div class="button-inner-container">
  39. <button id="options-button">Options</button>
  40. </div>
  41. <div class="button-inner-container">
  42. <button id="credits-button">Credits</button>
  43. </div>
  44. <div class="button-inner-container">
  45. <button id="reset-save-button">Delete Save</button>
  46. </div>
  47. </div>
  48. </div>
  49. </div>
  50. <div id="options-container">
  51. <div id="options-panel">
  52. <div id="options-back-button">&laquo;</div>
  53. <div id="options-header-container">
  54. <h1>Options</h1>
  55. </div>
  56. <div id="options-list-container">
  57. <div class="option-container">
  58. <div><label for="master-volume">Master Volume</label></div>
  59. <div><input type="range" min="0" max="100" id="master-volume" /></div>
  60. </div>
  61. <div class="option-container">
  62. <div><label for="music-volume">Music Volume</label></div>
  63. <div><input type="range" min="0" max="100" id="music-volume" /></div>
  64. </div>
  65. </div>
  66. </div>
  67. </div>
  68. <div id="credits-container">
  69. <div id="credits-panel">
  70. <div id="credits-back-button">&laquo;</div>
  71. <div id="credits-text">
  72. <div class="credits-section">
  73. <h1>Spookonomics</h1>
  74. <h2>The Witch's Brew</h2>
  75. <p><a href="https://threejs-journey.com/challenges/014-halloween-2" target="_blank">A Threejs Journey Student Challenge</a></p>
  76. </div>
  77. <div class="credits-section">
  78. <h3>Created By</h3>
  79. <p><a href="https://mastodon.gamedev.place/@eyeofmidas" target="_blank">Justin Gilman</a></p>
  80. <p><a href="https://mastodon.design/@danusha" target="_blank">Danielle Gilman</a></p>
  81. </div>
  82. <div class="credits-section">
  83. <h3>Libraries</h3>
  84. <p><a href="https://threejs.org/" target="_blank">threejs</a></p>
  85. <p><a href="https://gsap.com/" target="_blank">GSAP</a></p>
  86. <p><a href="https://howlerjs.com/" target="_blank">howlerjs</a></p>
  87. <p><a href="https://vite.dev/" target="_blank">vite</a></p>
  88. </div>
  89. <div class="credits-section">
  90. <h3>3D Models</h3>
  91. <p><a href="https://kaylousberg.itch.io/" target="_blank">Kay Lousberg</a></p>
  92. <p><a href="https://assetquest.itch.io/" target="_blank">AssetQuest</a></p>
  93. </div>
  94. <div class="credits-section">
  95. <h3>2D Assets</h3>
  96. <p><a href="https://kenney.itch.io/" target="_blank">Kenney</a></p>
  97. <p><a href="https://polyhaven.com/a/kloppenheim_02_puresky" target="_blank">Greg Zaal & Jarod Guest</a></p>
  98. <p><a href="https://fonts.google.com" target="_blank">Google Fonts</a></p>
  99. </div>
  100. <div class="credits-section">
  101. <h3>Audio & Music</h3>
  102. <p><a href="https://kenney.itch.io/" target="_blank">Kenney</a></p>
  103. <p><a href="https://www.gamesfxpacks.com" target="_blank">Cyberwave Orchestra</a></p>
  104. <p><a href="https://pixabay.com/sound-effects/" target="_blank">Pixabay</a></p>
  105. </div>
  106. <div class="credits-section">
  107. <h3>Special Thanks</h3>
  108. <p><a href="https://bruno-simon.com/" target="_blank">Bruno Simon</a></p>
  109. <p><a href="https://www.youtube.com/@simondev758" target="_blank">SimonDev</a></p>
  110. <p><a href="https://www.udemy.com/user/nicholas-lever-3/" target="_blank">Nik Lever</a></p>
  111. </div>
  112. </div>
  113. </div>
  114. </div>
  115. <div id="room-navigation">
  116. <div id="prev"><svg height="40" width="200"><text xml:space="preserve"
  117. style="font-size:32px;text-align:start;text-anchor:start;" x="44.315765" y="27.265625" id="text1"><tspan sodipodi:role="line" id="prev-text"
  118. style="font-size:32px;text-align:start;text-anchor:start;" x="44.315765" y="27.265625">Shop</tspan></text><path d="M 0,16 41.72141,31.318914 19.128231,16 41.72141,0.681086 Z" id="path1"
  119. sodipodi:nodetypes="ccccc" /></svg>
  120. </div>
  121. <div id="next"><svg height="40" width="200"><text xml:space="preserve"
  122. style="font-size:32px;text-align:end;text-anchor:end;" x="158.06747" y="26.584539" id="text2"><tspan sodipodi:role="line" id="next-text" style="font-size:32px;text-align:end;text-anchor:end;"
  123. x="158.06747" y="26.584539">Market</tspan></text><path d="M 200,16 158.27859,30.637828 180.87177,16 158.27859,0 Z" id="path3"
  124. sodipodi:nodetypes="ccccc" /></svg>
  125. </div>
  126. </div>
  127. <div id="game-status-container">
  128. <div id="game-status-panel">
  129. <div id="currency-meter-container">
  130. <div id="currency-meter-icon"><img src="./images/coin.svg" /></div>
  131. <div class="meter-start">0</div>
  132. <div id="currency-progress"><div id="currency-progress-amount"><span id="currency-amount">100</span></div></div>
  133. <div class="meter-end">1000</div>
  134. </div>
  135. <div id="current-day-container">
  136. <div id="current-day-icon"><img src="./images/day_icon.svg" /></div>
  137. <div id="current-day-text">day 1</div>
  138. </div>
  139. </div>
  140. </div>
  141. <div id="brew-container">
  142. <div id="brew-right-side">
  143. <div id="brew-header-container">
  144. <h1>Brew</h1>
  145. </div>
  146. <div id="brew-ingredients-container">
  147. <div class="ingredient-container" data-ingredient="pumpkin">
  148. <img src="./images/ingredient_pumpkin.png" />
  149. </div>
  150. <div class="ingredient-container" data-ingredient="tomato">
  151. <img src="./images/ingredient_tomato.png" />
  152. </div>
  153. <div class="ingredient-container" data-ingredient="lettuce">
  154. <img src="./images/ingredient_lettuce.png" />
  155. </div>
  156. <div class="ingredient-container" data-ingredient="mushroom">
  157. <img src="./images/ingredient_mushroom.png" />
  158. </div>
  159. </div>
  160. <div id="brew-selected-container">
  161. <div class="ingredient-selected-container disabled">
  162. <div class="disabled-selected-ingredient">None Selected</div>
  163. <div class="active-selected-ingredient">
  164. <div class="selected-ingredient-image">
  165. <img src="./images/ingredient_unknown.png">
  166. </div>
  167. <div class="selected-ingredient-description">
  168. <h2>Unknown</h2>
  169. <p>None Selected</p>
  170. </div>
  171. </div>
  172. </div>
  173. <div class="ingredient-selected-container disabled">
  174. <div class="disabled-selected-ingredient">None Selected</div>
  175. <div class="active-selected-ingredient">
  176. <div class="selected-ingredient-image">
  177. <img src="./images/ingredient_unknown.png">
  178. </div>
  179. <div class="selected-ingredient-description">
  180. <h2>Unknown</h2>
  181. <p>None Selected</p>
  182. </div>
  183. </div>
  184. </div>
  185. </div>
  186. <div id="brew-potion-summary-container">
  187. <div id="potion-icon-container">
  188. <div id="potion-icon"></div>
  189. <div class="potion-inventory-count">1</div>
  190. </div>
  191. <div id="potion-description">
  192. <h2 id="potion-name">Unknown</h2>
  193. <ul id="potion-properties-list"></ul>
  194. </div>
  195. </div>
  196. <div id="brew-button-container">
  197. <div id="brew-button-inner-container">
  198. <button id="start-brew">Brew</button>
  199. </div>
  200. </div>
  201. </div>
  202. </div>
  203. <div id="shop-container">
  204. <div id="shop-panel">
  205. <div id="shop-header-container">
  206. <h1>Shop</h1>
  207. </div>
  208. <div id="shop-sides">
  209. <div id="shop-left-side">
  210. <div id="shop-potions-container">
  211. <div class="potion-container"><img src="./images/potion_unknown.png" />
  212. <div class="potion-inventory-count">1</div>
  213. </div>
  214. <div class="potion-container"><img src="./images/potion_unknown.png" />
  215. <div class="potion-inventory-count">1</div>
  216. </div>
  217. <div class="potion-container"><img src="./images/potion_unknown.png" />
  218. <div class="potion-inventory-count">1</div>
  219. </div>
  220. <div class="potion-container"><img src="./images/potion_unknown.png" />
  221. <div class="potion-inventory-count">1</div>
  222. </div>
  223. <div class="potion-container"><img src="./images/potion_unknown.png" />
  224. <div class="potion-inventory-count">1</div>
  225. </div>
  226. <div class="potion-container"><img src="./images/potion_unknown.png" />
  227. <div class="potion-inventory-count">1</div>
  228. </div>
  229. <div class="potion-container"><img src="./images/potion_unknown.png" />
  230. <div class="potion-inventory-count">1</div>
  231. </div>
  232. <div class="potion-container"><img src="./images/potion_unknown.png" />
  233. <div class="potion-inventory-count">1</div>
  234. </div>
  235. <div class="potion-container"><img src="./images/potion_unknown.png" />
  236. <div class="potion-inventory-count">1</div>
  237. </div>
  238. <div class="potion-container"><img src="./images/potion_unknown.png" />
  239. <div class="potion-inventory-count">1</div>
  240. </div>
  241. <div class="potion-container"><img src="./images/potion_unknown.png" />
  242. <div class="potion-inventory-count">1</div>
  243. </div>
  244. <div class="potion-container"><img src="./images/potion_unknown.png" />
  245. <div class="potion-inventory-count">1</div>
  246. </div>
  247. </div>
  248. </div>
  249. <div id="shop-right-side">
  250. <div id="shop-shelves-container">
  251. <div class="shop-shelf">
  252. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  253. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  254. </div>
  255. <div class="shop-shelf">
  256. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  257. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  258. </div>
  259. <div class="shop-shelf">
  260. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  261. <div class="stocked-potion-container"><img src="./images/potion_unknown.png" /></div>
  262. </div>
  263. </div>
  264. </div>
  265. </div>
  266. <div id="shop-button-container">
  267. <div id="shop-button-inner-container">
  268. <button id="start-selling">Open Shop</button>
  269. </div>
  270. </div>
  271. </div>
  272. </div>
  273. <div id="market-container">
  274. <div id="market-panel">
  275. <div id="market-header-container">
  276. <h1>Ingredients</h1>
  277. </div>
  278. <div id="ingredients-list">
  279. <div class="ingredient-sell-container" data-ingredient="pumpkin">
  280. <div class="ingredient-icon-container">
  281. <img src="./images/ingredient_pumpkin.png" />
  282. <div class="ingredient-inventory-count">5</div>
  283. </div>
  284. <div class="ingredient-description">
  285. <h2>Pumpkin</h2>
  286. <div class="ingredient-price">
  287. <img src="./images/coin.svg" />
  288. <div class="ingredient-price-value">10</div>
  289. </div>
  290. <div class="call-to-action">Click to add to order</div>
  291. </div>
  292. <button class="add-ingredient-button">+</button>
  293. <div class="ingredient-in-cart-container">
  294. <div class="ingredient-in-cart-amount">24</div>
  295. </div>
  296. <button class="remove-ingredient-button">-</button>
  297. </div>
  298. </div>
  299. <div id="total-container">
  300. <div id="total-title">Total</div>
  301. <div id="total-amount">
  302. <div id="total-icon-container">
  303. <img src="./images/coin.svg" />
  304. </div>
  305. <div id="total-amount-value">57</div>
  306. </div>
  307. </div>
  308. <div id="market-button-container">
  309. <div id="market-button-inner-container">
  310. <button id="buy-ingredients">Purchase</button>
  311. </div>
  312. </div>
  313. </div>
  314. </div>
  315. <div id="game-over-container">
  316. <div id="game-over-blackout">
  317. <div id="game-over-panel">
  318. <h1>You Win!</h1>
  319. <p>You made 1000 gold in:</p>
  320. <h2>8 days</h2>
  321. <div id="play-again-button-container">
  322. <div id="play-again-button-inner-container">
  323. <button id="play-again">Play Again?</button>
  324. </div>
  325. </div>
  326. </div>
  327. </div>
  328. </div>
  329. <!-- Google tag (gtag.js) -->
  330. <script async src="https://www.googletagmanager.com/gtag/js?id=G-H4BYTFBKJT"></script>
  331. <script>
  332. window.dataLayer = window.dataLayer || [];
  333. function gtag() { dataLayer.push(arguments); }
  334. gtag('js', new Date());
  335. gtag('config', 'G-H4BYTFBKJT');
  336. </script>
  337. </body>
  338. </html>