Skip to content

RohanBhattacharyya/oSBW

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2,017 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenStarbound Web Fork

What is this?

tl;dr: OpenStarbound is a mod of the latest version of Starbound, 1.4.4. It fixes many bugs, adds many new features and improves performance. This is the web version, so that users can run the Starbound engine on modern browsers.

See openstarbound.

Building

Note: Some of these texts are just tooltips rather than links.

Web builds are documented in doc/web.

template sbinit.config for dist/ after build
{
  "assetDirectories" : [
    "../assets/",
    "./mods/"
  ],

  "storageDirectory" : "./",
  "logDirectory" : "./logs/"
}
Web (Emscripten)
  • Install and activate the Emscripten SDK.
  • Ensure CMake 3.23+ and Ninja are installed.
  • Build from the source/ directory:
    • Single-threaded:
      • cmake --preset=emscripten-release
      • cmake --build --preset=emscripten-release
    • PThreads (requires COOP/COEP headers):
      • cmake --preset=emscripten-pthreads-release
      • cmake --build --preset=emscripten-pthreads-release

Output is written to:

  • build/emscripten-release/ or
  • build/emscripten-pthreads-release/

Deploy all generated files together (starbound.html/js/wasm/data + preload.config).

Hosting

PThreads builds require cross-origin isolation headers:

  • Cross-Origin-Opener-Policy: same-origin
  • Cross-Origin-Embedder-Policy: require-corp

For local testing with the correct headers, use:

  • python3 web/serve_dist_with_headers.py --dir /path/to/build/emscripten-release
  • or python3 web/serve_dist_with_headers.py --pthreads

More details: doc/web/hosting.md

About

oSBW (OpenStarbound Web)

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors