F
Forrest Smith
forrestthewoods.com · Personal blog · on HN since 2012
Forrest Smith, a game programmer, writes about game engine tech, performance, algorithms, and visualizations, in hand-written HTML.
What HN saysHN links it for his Simpson's Paradox explainer and technical posts on game networking and performance; he also describes his hand-coded HTML site in comments.
57HN people shared it
16linked it in comments
85stories submitted
2.2Kstory points
5 months agolast shared
2012people per year2026
Most-shared posts
- 1Learning Jai via Advent of Code8 people · 11 points · first shared 2023 · discussion on HN
- 2Memory Bandwidth Napkin Math6 people · 322 points · first shared 2020 · 54 comments on HN
- 3Simpson’s Paradox (2016)5 people · 371 points · first shared 2019 · 82 comments on HN
- 4Reverse Engineering Sublime Text's Fuzzy Match Algorithm5 people · 32 points · first shared 2016 · 1 comments on HN
- 5The Tech of Planetary Annihilation: ChronoCam (2013)4 people · 95 points · first shared 2020 · 38 comments on HN
- 6My Favorite Paradox: Simpson’s Paradox4 people · 31 points · first shared 2016 · 1 comments on HN
- 7Visualizing Commute Times4 people · 6 points · first shared 2017 · discussion on HN
- 8Proving Immediate Mode GUIs Are Performant3 people · 20 points · first shared 2024 · 8 comments on HN
- 9Using Jai's Unique and Powerful Compiler for Typesafe Units3 people · 15 points · first shared 2024 · 1 comments on HN
- 10Measuring the Perception of Latency with a Haptic Glove3 people · 7 points · first shared 2019 · 1 comments on HN
- 11Why Your Keyboard Is Bad for Your Body3 people · 5 points · first shared 2016 · discussion on HN
- 12Reverse Engineering Sublime Text’s Fuzzy Match3 people · 3 points · first shared 2022 · 1 comments on HN
- 13Should small Rust structs be passed by-copy or by-borrow?2 people · 265 points · first shared 2019 · 107 comments on HN
- 14Failing to Learn Zig via Advent of Code2 people · 253 points · first shared 2022 · 329 comments on HN
- 15Benchmarking Malloc with Doom 32 people · 76 points · first shared 2022 · 30 comments on HN
What HN people wrote when they linked it
forrestthewoods · 2020-11-29
Oh no. I'm the "weird dude who writes raw html".
Artisanally hand-crafted HTML + CSS + JS. Hosted on Netlify. A+++ would recommend. My content works locally just by double-clicking a .html file. I can publish or edit live content by pushing to my private Git repro. Super easy.
Static site generators suck balls and are 10x more trouble than they're worth. I always know exactly what I want my blog posts to look like. Static generators can make it extremely difficult to generate the precise output html I know I want. It's radically simpler to just add some extra padding if it is more aesthetically pleasing for that specific content.
If you'd like to judge for yourself: https://www.forrestthewoods.com/
oxfeed65261 · 2021-11-28
For more on Simpson’s Paradox, see https://www.forrestthewoods.com/blog/my_favorite_paradox/, which I happened to reread this week, and which essentially serves as a spoiler for this article.
Kiro · 2021-09-22
Thank you! It was impossible to find anything on Google since any variant of "youtube", "latency" etc showed results for problems with YouTube or actual YouTube videos talking about latency.
The trick was to use HN search: "youtube latency" and select Comments. First result was a comment on https://www.forrestthewoods.com/blog/my_favorite_paradox/ which links the story in the "Bonus!" section.
oarabbus_ · 2019-03-04
Reminiscent of Simpson's Paradox, the most famous example being a gender discrimination lawsuit alleging UC Berkeley discriminated against women in admissions (57% men vs. 43% women).
It turned out there WAS bias - in favor of the women!
"The lawsuit triggered a study. The study results showed that not only were women not discriminated against, but that women had a statistically significant advantage!
Here’s what happened. Some departments had high acceptance rates and some had low acceptance rates. Women applied to more competitive departments. Men applied to more accessible departments. Taken on the whole men had an advantage. When broken down per department it was women who were more favored."
https://www.forrestthewoods.com/blog/my_favorite_paradox/
SXX · 2018-07-18
Same thing already done in spiritual successor for Supreme Commander/Total Annihilation called Planetary Annihilation. Basically there is authoritative server that work exactly that way.
Only downside of this is that when you have few thousand units on screen game will use abysmal about of bandwidth like 8Mbps for each client. So when there is 10 players in-game server-side must have these 80Mbps.
Oh and it's also used as replay / save system. Amazing tech:
https://blog.forrestthewoods.com/the-tech-of-planetary-annihilation-ch…
EQmapbox · 2018-05-04
I'd love to make this work, Forrest - drop my name in a note to [email protected] and let's see if we can get you setup with the Isochrone plugin (https://blog.mapbox.com/add-isochrones-to-your-next-application-e9e84a… which sits on top of the Mapbox Matrix API. https://blog.forrestthewoods.com/visualizing-commute-times-378009330ff… is awesome!
slightlygrilled · 2026-04-19
Yeah they used determinism, few bit can be read about here:
https://gafferongames.com/post/floating_point_determinism/
https://www.forrestthewoods.com/blog/synchronous_rts_engines_and_a_tal…
WithinReason · 2022-02-27
Check the first chart:
https://www.forrestthewoods.com/blog/memory-bandwidth-napkin-math/
NortySpock · 2021-10-16
Total Annihilation was asynchronous, Supreme Commander was synchronous lockstep (sending user interactions only), Planetary Annihilation said they were client-server, with the server only sending updates for units a player could see.
Still a Total Annihilation fanboy at heart.
https://www.pcgamer.com/planetary-annihilation-interview/2/
https://www.forrestthewoods.com/blog/tech_of_planetary_annihilation_ch…
antiuniverse · 2020-10-03
You might also enjoy “Memory Bandwidth Napkin Math”:
https://www.forrestthewoods.com/blog/memory-bandwidth-napkin-math/
ultimape · 2020-09-28
I wonder if there is a way to describe change sets as a mathematical curve and achieve something like the rewind-ability within Planetary Annihilation https://www.forrestthewoods.com/blog/tech_of_planetary_annihilation_ch… which seems to be an smoother alternative to dead-reckoning that bakes the history into it a bit better.
nemetroid · 2019-08-26
Maybe I'm missing something, but it looks like about a third of the functions in by_ref.cpp take their parameters by value:
https://www.forrestthewoods.com/blog/should-small-rust-structs-be-pass…
bob1029 · 2017-10-26
To clarify - In many cases you are actually running your physics or game loop at a different rate from the render loop. For instance, in CS:GO you can have a frame rate of well beyond 300, but the game loop (physics/ai/net/logic/etc.) is ticking at 60 (by default) due to the client-server architecture. This type of non-synchronous engine architecture is very complex to build reliably, so unless there is a hard requirement for it (e.g. client-server multiplayer model w/ advanced latency compensation) you will usually find a simpler synchronous approach used unless the underlying engine comes with the async architecture OOTB (UE4).
Some additional reading on the topic:
https://developer.valvesoftware.com/wiki/Source_Multiplayer_Networking
https://blog.forrestthewoods.com/synchronous-rts-engines-and-a-tale-of…
https://gafferongames.com/post/fix_your_timestep/
joezydeco · 2017-04-17
The Eighth Dirty Word - "Just"
https://blog.forrestthewoods.com/the-eighth-dirty-word-just-2d2386850c…
sillysaurus3 · 2016-04-17
If the HN front page consisted of your content alone, I would be very happy. https://news.ycombinator.com/submitted?id=forrestthewoods
https://blog.forrestthewoods.com/reverse-engineering-sublime-text-s-fu…
https://gamedevdaily.io/four-ways-to-create-a-mesh-for-a-sphere-d7956b…
https://gamedevdaily.io/advanced-behavior-tree-structures-4b9dc0516f92…
Speaking purely for myself, I hope to see them resubmitted. The post about reverse engineering Sublime's fuzzy matching algorithm is an overlooked gem, I think.
hajile · 2022-08-01
I implemented a fuzzy search a few years ago and here's some things to look into.
Damerau-Levenshtein is a significant upgrade from the default Levenshtein algorithm used as it also picks up the very common transposition error much more efficiently for not a lot of extra code.
https://en.wikipedia.org/wiki/Damerau%E2%80%93Levenshtein_distance
Typed arrays would also probable speed thing up quite a bit.
Tokenizing may not be faster. Set the first row of weights to ZERO. When you're done, look for the lowest value in the final array. This also saves the trouble of trying to tokenize properly for every language as it's only concerned with the bytes themselves.
https://stackoverflow.com/questions/8139958/algorithm-to-find-edit-dis…
Performance of that algorithm also suffers a LOT with very long strings. For those, we went with one more like the fuzzy search used in Sublime text. Basically, you iterate the string one time and look for the search characters to appear in order. To go more advanced add a weight to each match type. Stuff like consecutive characters that match, cases match, or immediately transposed characters next to each other give higher weights to the resulting string.
https://www.forrestthewoods.com/blog/reverse_engineering_sublime_texts… (this looks like a decent overview of sublime fuzzy search).