Here’s some notes from my internal wiki.

How to export .bullet data from a Blender 2.5x scene (awfully close to 2.6 now ‘eh). This might be as of Blender 2.57, and should continue to work well in to 2.6x.

Exporting Bullet Data from Blender

Exporting Bullet Physics data from Blender is a pain in the ass. Plain and Simple. It *SHOULD* be a right click export, but no, it’s complicated.

  1. Switch to Game Engine Mode (In the Title Bar, the default setting is “Blender Render”. Should be “Blender Game”).
  1. Game Engine Mode changes the *Physics* Properties (bouncing ball)
  • Make the Physics Type a “Rigid Body”
  • Enable Collision Bounds, and pick a bounding volume type (boxes, hulls)
  • To make compound objects, you need to treat one object as the parent, and check the compound buttons

* Under the *Object* Properties (tiny cube), Relations Parent can be used to identify oneself as a child of a parent

  • Defining compound objects is required to make overlapping volumes that don’t affect each-other.
  1. Change a pane to a *Logic Editor* (little red-ball joystick)
  1. Add a “Keyboard” sensor, and set the key to the spacebar (for example… we’re binding the spacebar to an action)
  1. Add a “Python” controller
  1. Change a pane to a *Text Editor*
  1. Hit + to create an instance (default name is “text”)
  1. Paste the following script in to the text editor
import bpy;
import PhysicsConstraints;
print( "Exporting..." );
PhysicsConstraints.exportBulletFile( bpy.path.ensure_ext(,".bullet") );
  1. Update the “Python” controller to use this script file
  1. Drag a link between the Keyboard sensor and the python controller (see the little nodes between them)
  1. If you haven’t already, save the .blend file. If you close Blender, then double click on the saved .blend file, it will change the current working directory of Blender. This is important, because the script above (with no path) saves the .bullet file to the working directory.
  1. Finally, to generate the blend file, run the simulation (R key).
  1. To export, while the simulation is running, push the spacebar.
  1. The console will show the “Exporting…” message. If you don’t have a blender console, you can enable it under Help->Toggle Blender Console

Done. That’s the annoying way to export .bullet data from blender.

The reason for the complicated procedure is that the PhysicsConstraints and bge libraries are just not available in standard plugin scope. Right clicking and running the script, just not an option. So we need to enter a game instance, where all these helpful library instances exist (as otherwise you wouldn’t have physics).

Research conducted on October 6th, 2011, using Blender 2.59.