Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

407 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Symplectica

Symplectica Hero Image

Live Demo

Symplectica is a multiplayer N-body space simulator focused on scientific accuracy, visual fidelity and realistic orbital mechanics.

Whether you're a physics enthusiast simulating star systems and astroid belts, a student learning about orbital mechanics and numerical methods, or a player exploring the universe with your friends, Symplectica handles it all.

Built with Rust + WebAssembly on the backend and TypeScript + Three.js on the frontend.

Gallery

inner_solar_system.webm

Traveling between the inner solar system bodies.

earth_TIMEWARP.webm

Earth and other bodies at various time warp rates.
ganymede_SURFACE.webm

Jupiter and Io as seen from Ganymede's surface
Symplectica Showcase Image
A wide closeup of Jupiter with its storm.
mimas_SCALE.webm

Zooming out of Mimas into Saturn's rings.
Showcase Image 1
A close up of Earth showing Africa in the center.
Showcase Image 2
A close up of Earth showing atmospheric glow.

Key Features

Some of Symplectica's capabilities include:

  • Realistic physical properties for stars, planets and moons:
    • Stars: surface temperature, luminosity, mass, and solar flares.
    • Planets: axial tilt, oblateness, rings, and atmospheres.
    • Moons: inclination, eccentricity, orbital resonances, and eclipses.
  • Atmospheric scattering with multi-light source, penumbra shadow effects.
  • Realistic system presets with to-scale distances and sizes:
    • Our Solar System with real ephemeris data for planets, moons, and other major bodies (sourced from NASA JPL HORIZONS).
    • The Proxima Centauri system.
    • The TRAPPIST-1 system.
  • High-performance N-body simulation with Pairwise, Barnes-Hut and FMM force methods.
  • Hybrid integrator switching in close encounters to avoid energy drift:
    • Default integrator: Symplectic Velocity Verlet.
    • Close-encounter: Adaptive RK45 or 5th-Order Gauss-Radau.
  • Time-warp and teleportation options.
  • Multiplayer universe builder with real-time system editing.

See FEATURES.md for a comprehensive list of implemented, in-progress, and planned features.

Installation & Setup

Prerequisites

  • Node.js 18+
  • Rust 1.70+
  • wasm-pack

Development

  1. Clone and install:

    git clone https://github.com/ali-albdaer/Symplectica.git
    cd Symplectica
    npm install
  2. Build the wasm bundle:

    npm run wasm:build
  3. Start development:

    npm run dev
  4. Open localhost:3000 in your browser.

Data & Assets Scripts (Optional)

The repository includes helper scripts to fetch production assets and real-world ephemeris data.

  1. High-Res Textures
    To download 2K high-resolution textures (from Solar System Scope) for planets, moons, and Saturn's rings, run:

    node scripts/download_textures.js

    This will place the textures into src/client/public/local/textures/planets/ for use when the "Use High-Res Textures" toggle is enabled in the Options panel.

  2. HORIZONS Ephemeris Data
    To fetch high-precision state vectors and orbital elements from NASA JPL HORIZONS (for creating or updating presets), use the Python script:

    # Install dependencies first
    pip install requests
    
    # Fetch data for a specific epoch
    python scripts/fetch_horizons.py --epoch 2026-01-01

    This script outputs structured JSON data to scripts/fetched/ which can be translated into Symplectica physics presets.

Sources

All sources consulted for physics, celestial mechanics, numerical methods and rendering techniques are listed in SOURCES.md

License

Symplectica is licensed under the MIT LICENSE.

About

Multiplayer N-body space simulator focusing on scientific accuracy, visual fidelity, and realistic orbital mechanics.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Used by

Contributors

Languages