Object Editing

From Custom Mario Kart
Jump to: navigation, search

This page is a part of the Custom Track Tutorial. Back to the main tutorial page.

Introduction

This page covers some important, but short and optional Custom Track topics related to KMP Objects. Move on to the KMP Editing tutorial when you're ready.

Porting Objects

For example, if you want to place a Thwomp in a track that's based off from GCN Mario Circuit, you must port the Thwomp model into the level. You can't simply place a dossunc (object for the Thwomp) in the KMP and expect it to work, as that will make the game crash.

You must put the all files needed for that object (usually a just a BRRES, but sometimes KCL, effect and BRASD files are required) into your track's SZS file. Doing this requires either the SZS Explorer or the Wiimms SZS Tools.

SZS Explorer

How to port an object, using the Goomba object as an example.

  • Open both course files (the course with the object you want to move, and the destination course) with two SZS Explorer windows.
  • Export the files for the Goomba from a course that contains Goombas. The required files are kuribo.brres and the kuribo folder (along with the two files contained in the folder) in the BRASD folder. Right-click the files and choose Export.
  • Import the files into the new SZS file. Right-click the root folder and import kuribo.brres into it, and right-click into the BRASD folder and import the kuribo folder into it. The imported files must be in the same places as in the original course. If there isn't a BRASD folder in your new course file, right-click the root and create one.

To use the Goomba in your course, you will need to add a Goomba to your KMP and assign it a route.

  • To make and assign a route, create your route that you want your object to take with any KMP Editor. Make sure it has the correct Y-value. You can use Automated height correction tools to help correct this value. Once done, go to the object and to assign the route, go to the route column and type in your Route number. (i.e: My route is 12. I type in the route section of my object "0012".) (If you have a one-digit route like 9 or 1, type 000X. X stands for the route number.) Make sure that the object is placed at the same X, Y, and Z coordinates as the route. In the "Setting 2" column, set the speed for the object or it will not move. 0020 seems to be a decent value for the Kuribo object. Different objects use different files - some objects use stuff in the effect folder, some use multiple BRRES files, some use KCL files, and some don't have BRRES files, such as fireworks.

Porting skydome models, map models, course models, KCLs and KMPs is the same process: you export it from the original course, and you replace it in the new course. If you are not creating your KCL or map models from scratch, the best KCLs to use are Koopa Cape's and Maple Treeway's and the best map_model.brres to use is Mushroom Gorge's. The KMP to use varies depending on the track you want to make, some people say that the N64 Bowser Castle one it the best.

Wiimms SZS Tools

Assume, we have 2 SZS files called SOURCE.szs and DEST.szs in the current directory. We plan to copy some objects from source to dest:

  1. Extract the files of both SZS files:
    wszst extract SOURCE.szs DEST.szs
    Now we have to new directories: SOURCE.d and DEST.d
  2. Copy the objects from SOURCE.d to DEST.d with a file browser of your choice. Be sure to use the same sub directories.
  3. Create a new destination file:
    If you want to overwrite the old DEST.szs use:
    wszst create DEST.d --overwrite
    If you want to create a new SZS file use:
    wszst create DEST.d --dest NEW.szs
  4. If is possible to compare the SZS files on sub file level:
    wszst diff DEST.szs NEW.szs
References

Editing Objects

Custom Objects can be created by editing an existing object. To change only the object's texturing, you can open the object's BRRES file in either CTools or BrawlBox and import a new texture over the previous one, as explained in the Texturing tutorial. New models can be imported over objects, too, although this can be glitchy in animated objects or objects with certain behaviors. The models can be created in CTools or BrawlBox, as explained in the BRRES Creating section. Note that the name of the MDL0 file inside the object's BRRES (as well as the BRRES itself) must have the same name of the original object, or else the game will crash upon trying to load the object. All files that were previously required by the original object must be present. Not that this also applied to the vrcorn_model.brres, the model of the track's sky (which does not necessarily have to be a sky).

The custom object's behaviour will be exactly the same or similar to the original object's. For example, route following objects will still be able to follow routes, and solid objects will mantain their solidity. Objects containing KCL files for collision also can have their collision files edited, allowing custom objects with custom collision. Examples of all of this are found in the Custom Objects page.