← Thu, Nov 5 digest

Lemmings CSS Animation

read article ↗ hn thread ↗

A web demonstration features animated Lemmings-style walkers that interact with DOM elements, ride surfaces, and respond to window resizing.

summary is enough The project is a fun, interactive web toy that is best experienced directly in the browser.

summary

Mark Blah created a web experiment featuring animated characters that walk across standard HTML elements like text lines, buttons, and borders. Users can drag, throw, and watch the characters adapt to reflowing DOM structures and window resizing. Commenters fondly reminisce about the original 1990s Lemmings game, compare browser performance, and share historical web experiments like DHTML Lemmings.

key points

  1. Walkers treat standard DOM elements such as text lines, buttons, and borders as solid collision surfaces.
  2. Users can directly drag and throw the characters, which react dynamically to window resizing and page reflows.
  3. The comment section highlights nostalgic memories of the original game and shares various retro ports and historical DHTML clones.

who should read it

Web developers and retro gaming enthusiasts looking for a creative browser-based experiment.

discussion warm

consensus

Commenters are overwhelmingly nostalgic, praising the charming implementation and sharing links to classic Lemmings ports and older DHTML browser experiments.

pushback

A few participants note that lacking core mechanics like digging and building means it resembles a physics toy rather than actual Lemmings gameplay.

best comment by pwagland ↗

Interesting experiments and differences between the browsers.

Using the test: (async () => { const sleep = (ms) => new Promise((r) => setTimeout(r, ms)); for (let i = 0; i < 200; i++) { __walker.add(); await sleep(10); } })();

From the JavaScript console, on both Chrome and Safari.

The animation is _way_ smoother on Chrome, but scrolling on that page becomes really painful.

Safari, on the other hand, uses a lot more CPU to do the animation, and the FP of that animation drops dramatically as you change the number of lemmings from 10 -> 50 -> 100 -> 200. However scrolling the page remains …

It details distinct performance and scrolling trade-offs between Chrome and Safari when handling a large number of animated walkers.

Generated by an LLM from the article and thread. Check the sources before relying on it.