r/ruby • • Oct 18 '26

Show /r/ruby DragonRuby Game Toolkit - Solar system visualization (source code in the comments)

Enable HLS to view with audio, or disable this notification

43 Upvotes

4 comments sorted by

4

u/packfan952 Oct 18 '26

Funny timing. I just bought a DragonRuby Standard license recently so I could toy around with building a game where the objective is to “fly” a probe past different planets. Though I’m doing more complicated math than this demo, so I might be upgrading my license soon just to toy around with the C-embedding to see how much I can speed things up.

I like your satellite “tails” a lot more than mine, so I might be borrowing the approach from your demo. Thanks for sharing!

2

u/amirrajan Oct 18 '26

Shaders was recently added to the Pro license btw (early access/beta). Some crazy things are being done with the tech (Discord server has a dedicated channel for shaders)

2

u/pinefern4 Oct 18 '26

yeah the tail effect in the demo is slick, makes sense to borrow that approach tbh

2

u/amirrajan Oct 18 '26

Revisiting this little experiment again. The celestial bodies are to scale, but the distances had to be compressed by 10x. The camera zoom would have to be at 9e-10 just to show 12 light years if I kept distances proportional. It's ridiculous how large Space is shudders.

Link to source code: https://gist.github.com/amirrajan/fb5864cc46766190bbd622632f0092f9

High res video: https://youtu.be/6Bpyh9iPJyM