Skip to content

Using the Python Hitbox Generator Tool

SnailPerson edited this page Nov 24, 2025 · 1 revision

Hey, you don't want to suffer by calculating one billion hitboxes and loosing your sanity? Manually? See no further than to use Rainwinds Hitbox Tool!

Step 1:

Install Python, a versatile and beginner-friendly programming language, onto your computer.

Also make sure you have the Blockbench modelling software on your Computer.

Step 2:

Download hitbox-bb-test1.py

This is the script that will do the heavy lifting and run the transformation.

Step 3:

Open your model in Blockbench. Start modelling the collision cubes with normal cubes (not meshes!)

image

Group each bunch of boxes into their respective functions. For example, all block collisions are grouped into the "block" group, all boxes that act as triggers for a hood or door opening into a "hood" and "door" group etc.

Step 4:

Save the project as a .bbmodel in a folder somewhere on your computer. It doesn't matter where, just that you know the filepath.

I suggest having a simple folder on your desktop and putting your .bbmodel in there.

Then take the previously downloaded python script and put it in the same folder. Double-click it to run it.

Step 5:

After you ran the script, the folder can always be used for this method without having to run it again.

To actually get usable stuff with this tool, you need to open IDLE (Windows) / Terminal (MacOS) and paste:

python3.13 /...filepath.../hitbox-bb-test1.py

Or as an example im my case:

python3.13 /Users/[USERNAME]/Desktop/HitboxTool/hitbox-bb-test1.py

Press enter to run.

Step 6:

Once you did that, you'll have the following dialogue:

# Blockbench to MTS Hitbox Exporter - Rainwind
>> Open bbmodel file(don't include file extension): 

Now paste the path to the .bbmodel behind the string. Your dialogue should look something like this:

# Blockbench to MTS Hitbox Exporter - Rainwind
>> Open bbmodel file(don't include file extension): /Users/USERNAME/Desktop/HitboxTool/MODELNAME
Successfully opened /Users/USERNAME/Desktop/HitboxTool/MODELNAME.bbmodel file!
>> Group/bone name for hitboxes: 

Congrats, you opened your model with the tool! Now just type in the name of your group, for example "hood", and press enter!

You will then see the following:

# Blockbench to MTS Hitbox Exporter - Rainwind
>> Open bbmodel file(don't include file extension): /Users/USERNAME/Desktop/blokben/amogus/MODELNAME
Successfully opened /Users/USERNAME/Desktop/blokben/amogus/MODELNAME.bbmodel file!
>> Group/bone name for hitboxes: hood
Group/bone name hood found!
POSITION: [-0.375, 0.65625, 3.125], WIDTH: 0.75, HEIGHT: 0.3125
POSITION: [-0.375, 0.53125, 3.875], WIDTH: 0.75, HEIGHT: 0.3125
POSITION: [0.375, 0.65625, 3.125], WIDTH: 0.75, HEIGHT: 0.3125
POSITION: [0.375, 0.53125, 3.875], WIDTH: 0.75, HEIGHT: 0.3125
POSITION: [0.0, 0.4375, 4.0], WIDTH: 0.625, HEIGHT: 0.625
>> Export Options: View(1) / Save(2) / Exit(Any other key): 

You now have multiple options.

  • View (1) - Pressing one gives you the code for pasting directly in the terminal
  • Save (2) - Saves the code as a .json file on your computer.
  • Exit (x) - Press any key to quit the process, enter works too.

Usually pressing one (1) will do the trick. Select the code and paste it into your vehicle json! Congrats!


Credits to rain_wind/rain_flight for programming this tool.

Clone this wiki locally