Create collision for a BMD/BDL model

Contents


  1. Required tools
  2. Quick Intro
  3. Steps


Required tools


Go to Resources for download links.



Quick Intro


Making models is epik, but, what if we want Mario to interact with them? Well, the easiest way would be to add collision to your model. For this we use a very nice tool called NeoKCLCreate which purpose is exactly what we need, to be able to create collision for our custom model to be imported on Super Mario Galaxy.

When we refer to collision in SMG we refer to the KCL and PA files that are inside an ARC file for a BMD/BDL file. In general, I will refer to these files as collision files or just collision so I am not repeating KCL and PA all the time.


NOTE 0: I really don't know yet why 2 files are needed for collision instead of one >:]


Collision is basically a non-visible but interactable 3D model. So if a model (BMD/BDL) is shaped in a way, we can add as collision any other type of shape needed. For example (as shown in Fig. 0), we can add a cube shaped collision to an sphere model and get away with it.

Image could not be loaded.

(Fig. 0 - Cube shaped collision for a sphere model - Mario is confused)


However, this is not always the case (if it is your case then you are probably making a troll level) and we would like to make the collision as similar as posible as our custom model.



Steps


Open Blender where your model exists, triangulate it, and export it as an OBJ file.


NOTE 1: Blender 2.79 by default exports OBJ models with the upper axis being the Y axiss so you don't have to worry about rotating the model manually to get the right angle on game (check your export settings regardless).

NOTE 2: triangulation is done so the actual collision "manifests" in game. In other words, no triangulation means no/incomplete collision.


After that, open NeoKCLCreate, go to File > New and search for the OBJ file just exported from your custom model (Fig. 1). After openning the OBJ file, it will be shown something as in Fig. 2.

Image could not be loaded.

(Fig. 1 - New collision project - NeoKCLCreate)


Image could not be loaded.

(Fig. 2 - OBJ file in NeoKCLCreate)


In this window we have several options (very epik btw):



NOTE 3: If you go to Edit > Presets there are a few collision presets for a material that you might want to test!



After setting your desired preferences, you go to File > Save As and save the output collision files into some directory (Fig. 3).

Image could not be loaded.

(Fig. 3 - KCL and PA files created with NeoKCLCreate)


Then you can add those into an ARC file with your BMD/BDL model (or no model at all, >:]) and import the collision in game. Be sure to name the ARC file, the root folder and the collision files to the same name!



NOTE 4: remember, your collision can be anything you want, it does not need to be exactly the same shape as your custom model.

NOTE 5: NeoKCLCreate also has a very nice feature that allows you to convert the KCL and PA files into an OBJ! Use File > Open to open a KCL file (the PA file must be in the same place as the KCL file) and you will be able to export it as an OBJ by going to File > Export.