Log In  


Cart #planetsgravitysim-2 | 2023-09-20 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
5

Description

This cartridge simulates orbital mechanics using Newton's law of universal gravitation. It is recommended to experiment with the settings, which can be found in the code. The planets are generated randomly, so try reloading the cart to find interesting combinations.

Camera Controls

By default, the camera will follow the average of the planets' positions, giving you a view of all the planets. Use the Z key to lock on to a specific planet, and keep pressing Z to cycle through different planets. Pressing the X key will let you move the camera manually with the arrows or WASD, and pressing it again will go back to the automatic camera.

Credits

Programming by PicoCoder
Distance formula for long distances by TetraPengwin
Inspired by Sebastian Lague's video
Law of universal gravitation by Isaac Newton

Updates

1.1:

  • Added a path tracer (off by default)
  • Added an option to disable the grid
5



[Please log in to post a comment]