[HN Gopher] Improving the foundation of our falling sand simulator
___________________________________________________________________
Improving the foundation of our falling sand simulator
Author : jasonjmcghee
Score : 37 points
Date : 2022-05-16 02:07 UTC (1 days ago)
(HTM) web link (jason.today)
(TXT) w3m dump (jason.today)
| Bellend wrote:
| This is really awesome!
|
| Anyone remember Sony-J5 Mobile? I first seen falling sand there.
| Jason's version is a ultra fast version (and cool!).
|
| https://www.sony.ee/electronics/support/res/manuals/3227/322...
| sokoloff wrote:
| Fun!
|
| Small bug: if you two finger touch on iOS (or hit clear all), the
| screen clears to a different color background, lighter than the
| new sand dispenser, so now the sky becomes darker as you drag
| around.
| jakear wrote:
| Love the gravity addition, that's a clever trick for dealing with
| fractional velocity. Pausing rendering when there are no changes
| is also a nice touch.
|
| I notice on my machine the background is initially white and only
| acquires the grey background color after a sand has fallen past a
| given pixel. I encountered the same bug when building my own
| version off of this from your last post, my fix was to initialize
| the dirty set to be the full set of indexes for the first frame.
| Also, some of the buttons are pure white, the text is invisible.
| (I suspect both of these are light mode only bugs)
| jasonjmcghee wrote:
| Oh no! I clearly have a bug. I develop in dark mode and
| apparently broke something during this post and didn't verify
| light mode. I will look into it now!
| jasonjmcghee wrote:
| The light mode bugs should now be fixed. Apologies for that.
| jakear wrote:
| Works great!
| d4a wrote:
| The acceleration was my main gripe with the previous iteration.
| Thanks for adding it!
|
| I want to stay up to date on this blog. Is there an RSS feed
| anywhere?
| jasonjmcghee wrote:
| I'm glad you are enjoying the posts!
|
| I'm hosting on Github Pages, which seems to have a feed plugin
| for RSS, so I'll investigate that! Right now I've just been
| posting to Twitter (so far it's the only thing I've used it
| for) and HN.
| ajmurmann wrote:
| On Safari and Chrome I get `TypeError: p.before is not a
| function. (In 'p.before()', 'p.before' is undefined)` from
| falling-improved:171
|
| Nothing gets rendered.
| [deleted]
| jasonjmcghee wrote:
| This is what happens when you try to fix a bug while your post
| is on the front page. Yikes. Should be fixed.
|
| You might need to force refresh.
| dang wrote:
| Recent and related:
|
| _Making a falling sand simulator_ -
| https://news.ycombinator.com/item?id=31309616 - May 2022 (65
| comments)
___________________________________________________________________
(page generated 2022-05-17 23:00 UTC)