Skip to content

Lusito/box2d.ts

 
 

Repository files navigation

@box2d Monorepository

All Contributors

Work in Progress of a full Box2D ecosystem for the web.

  • This project is kept in sync with the original Box2D project (using a special tool to easily compare differences to upstream)!
  • You only need to install what you actually want. Don't need particles or 2D lights? Then just install the core.
  • Check out the demos and the benchmarks

Included Libraries:

Quick Start

This monorepo is in it's early stage, so to get started, you'll have to taka a look at the testbed project for now.

Monorepo Commands:

Most important commands to execute from the root folder (you need npm 18 installed):

  • npm ci -> install dependencies
  • npm run build -> build all projects
  • npm run build:libs -> build only the libraries
  • npm run build:testbed -> build the testbed
  • npm run credit "<username>" <type> -> Add user to all contributors list. Use quotes, as otherwise wrong people get added.
  • npm run start -> Run testbed locally
  • npm run bench -> Run the benchmark using node.js
  • npm run bench:web -> Start a webserver for running the benchmarks using a browser,
  • npm run lint -> Run linters, formatters, etc.
  • npm run lint:fix -> Run linters, formatters, etc. and autofix if possible
  • npm run release -> Release one of the libraries

The @box2d Ecosystem

@box2d is a full-blown ecosystem for box2d for the JavaScript/TypeScript world. It can be used both in the browser and in node.js

Check out demos and compare performance here: https://lusito.github.io/box2d.ts/

Fair Warning: The whole @box2d ecosystem is in an early stage, so it will probably change a lot before we release the first stable version (1.0.0).

Other packages included in the ecosystem:

  • Benchmark: Based on bench2d by joelgwebber
  • Controllers: From the LiquidFun project
  • Particles: Also from the LiquidFun project
  • Lights: ported from LibGDX
  • DebugDraw: Debug drawing using a canvas
  • Testbed: A set of demos, partially ports of the original projects, partially new ones.

Contributing

We're looking for contributors to make this the best place to start with box2d on the web. Check out the project page for more information: https://github.com/Lusito/box2d.ts

Contributors ✨

Thanks goes to these wonderful people (emoji key):


Erin Catto

💻

Isaac Burns

💻 📦

Maxime Veber

💻

finscn

💻

lusito

💻 🚧

Daniel Zhang

🤔

This project follows the all-contributors specification. Contributions of any kind welcome!

About

Full blown Box2D Ecosystem for the web, written in TypeScript

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 97.8%
  • JavaScript 1.6%
  • Other 0.6%