Skip to content

Systems Bullet Physics engine

Andrea Catania edited this page Apr 8, 2021 · 5 revisions

⚠️ 🔥 DISCLAIMER 🔥 ⚠️

This is a work in progress feature that was published to give the possibility to early test it. Any feedback / bug report is welcome but keep in mind that this is subject to changes according to the received feedbacks.

As any other mechanism in Godex, you need to add the proper Systems to make it work. If you are already familiar with Physics System Dispatcher understand how to setup the following Systems is easy.

Screenshot from 2021-04-08 08-31-29

BtBodyConfig

BtBodyConfig is the first System you have to add, inside the Physics sub pipeline.

This System is responsible for the Rigid Body lifetime:

In short, it make sure the Rigid Body + Rigid Shape behave like expected.

BtAreaConfig

BtAreaConfig is the second System you have to add, inside the Physics sub pipeline.

This System is responsible for the Area lifetime:

  • It add the Area inside the Physical Space.
  • Removes it when you remove the Area or the Shape component.
  • Reload it when some properties change.

In short, it make sure the Area + Rigid Shape behave like expected.

BtApplyForces

BtApplyForces is the third System to add inside the Physics sub pipeline.

This System is responsible to handle the Forces & Impulses. When you add one of those two components, this system will take care to properly impress the force or the impulse to the body.

BtSpacesStep

BtSpacesStep is the forth System to add inside the Physics sub pipeline.

This System is simply responsible to process the Physical Spaces.

BtOverlapCheck

BtOverlapCheck is the fifth System to add inside the Physics sub pipeline.

This System is responsible to handle the Area overlap check and event propagation.

BtBodySync

BtBodySync is the final System to add inside the Physics sub pipeline.

It's responsible to sync the Transform and propagate the contacts events.

Sample projects

With these information you are able to setup a Physics Scene in Godex. Remember that you can always download a sample project from here: https://github.com/GodotECS/godex/wiki/Bullet-Physics-engine#sample-projects