Vanilla JavaScript refinery simulator built to explain job to my kids
Details
- External ID
- 47224637
- Source
- HN
- Company
- —
- Product
- I built a refinery simulator game to explain job to my kids
- Website domain
- fuelingcuriosity.com
- Launched
- March 2, 2026
- Cohort
- —
- Upvotes
- 7
- Upvotes percentile
- 0.4108241082410824
- Tags
- —
- Fetched at
- Sept. 7, 2026, 9:26 p.m.
- Updated at
- Sept. 7, 2026, 9:26 p.m.
Description
Hi HN, I’m a chemical engineer and I manage logistics at a refinery down in Texas. Whenever I try to explain downstream operations to people outside the industry (including my kids), I usually get blank stares. I wanted to build something that visualizes the concepts and chemistry of a plant without completely dumbing down the science, so I put together this 5-minute browser game.I am not a software developer by trade, so I relied heavily on LLMs (Claude, Copilot, Gemini) to help write the code. What started as a simple concept turned into a 9,000-line single-page app built with vanilla HTML, CSS, and JavaScript. I used Matter.js for the 2D physics minigames.A few technical takeaways from building this as a non-dev: * Managing the LLM workflow: Once the script.js file got large, letting the models output full file rewrites was a disaster (truncations, hallucinations, invisible curly-quote replacements that broke the JS). I started forcing them to act like patch files, strictly outputting "Find this exact block" and "Replace with this exact block." This was the only way to maintain improvements without breaking existing logic.* Mapping physics to CSS: I wanted the minigames to visually sit inside circular CSS containers (border-radius: 50%). Matter.js doesn't natively care about your CSS. Getting the rigid body physics to respect a dynamic, responsive DOM boundary across different screen sizes required running an elliptical boundary equation (dx * dx) / (rx * rx) + (dy * dy) / (ry * ry) > 1 on every single frame. Maybe this was overkill to try to handle the resizing between phones and PCs.* Mobile browser events: Forcing iOS Safari to ignore its default behaviors (double-tap zoom, swipe-to-scroll) while still allowing the user to tap and drag Matter.js objects required a ridiculous amount of custom event listener management and CSS (touch-action: manipulation; user-select: none;). I also learned that these actions very easily kill the mouse scroll making it very frustrating for PC users. I am hoping I hit a good middle ground.* State management: Since I didn't use React or any frameworks, I had to rely on a global state object. Because the game jumps between different phases/minigames, I ran into massive memory leaks from old setInterval loops and Matter.js bodies stacking up. I had to build strict teardown functions to wipe the slate clean on every map transition.The game walks through electrostatic desalting, fractional distillation, hydrotreating, catalytic cracking, and gasoline blending (hitting specific Octane and RVP specs).It’s completely free, runs client-side, and has zero ads or sign-ups. I'd appreciate any feedback on the mechanics, or let me know if you manage to break the physics engine. Happy to answer any questions about the chemical engineering side of things as well.For some reason the URL box is not getting recognized, maybe someone can help me feel less dumb there too. https://fuelingcuriosity.com/game
Enrichment
- Theme
- interactive simulations and creative experiments
- Vertical
- Education
- Function
- Content generation
- Audience
- B2C
- AI stance
- Not AI
- Project type
- Hobby / open-source project
- Normalized one-liner
- interactive simulator explaining industrial processes
- Manually corrected
- False
Could you build this?
Yes This is a lightweight educational browser game written in vanilla JavaScript with simple mini-games explaining chemical plant stages, which AI assistants can generate rapidly.
Discussion
10 comments analyzed.
Concerns raised: Difficulty removing square in Phase 3: The Cooker, Title is confusing, URL not clickable in title, Hydropipe angle obstructed
Feature requests: Add more levels teaching mechanical aspects of refinery, Improve hydropipe positioning for better angle access
Competitors
Other products that read as similar to this one — 214 launches clear the similarity bar, closest 8 shown.
Attention rank: #143 of 215 (itself plus its competitors, highest first — normalized so YC and Product Hunt are compared fairly).
Launched 122 days after the earliest competitor.
- I vibe-coded a custom WebGPU engine for my MMO · hn · 2026-02-23 · 5 upvotes · similarity 0.52
- Nectar, a Rust-like React that compiles to WebAssembly · hn · 2026-07-06 · 29 upvotes · similarity 0.51
- A WebGPU-based browser engine with "Blam "-style physics · hn · 2026-01-15 · 5 upvotes · similarity 0.49
- Coi · hn · 2026-01-20 · 225 upvotes · similarity 0.49
- MicroState · hn · 2026-01-21 · 8 upvotes · similarity 0.46
- Foundry: a Markdown-first CMS written in Go · hn · 2026-03-27 · 31 upvotes · similarity 0.44
- I made a Mario Galaxy game with Claude Code and Three.js in 53 days · hn · 2026-04-01 · 7 upvotes · similarity 0.44
- React Three.js 3D Particle Engine · ph · 2026-09-11 · 1 upvotes · similarity 0.44
Other launches for this product
Same idea, different domain
Nobody's really built a content generation tool for Government yet.