Difference between revisions of "Object Editing"

From Custom Mario Kart
Jump to navigation Jump to search
(Moving the Minimap article to a new page.)
Line 77: Line 77:
 
<br>
 
<br>
 
<br>
 
<br>
 +
 +
====Lightning====
 +
 +
[[File:Posteffect blight change.png|200px|thumb|A view of a normal Hex Editor]]
 +
 +
First you have to export the '''[[Blight (File Format)|Posteffect.blight]]''' in the '''posteffect''' folder, because editing on SZS Explorers Hex Editor might be difficult.
 +
Open it with your Hex Editor and search after the magic 'LOBJ'. The first object is the normal road, so search again after the magic. The second object is the shadow. If you need it go to the next 'LOBJ'. Then activate this Object, notice the ID, and Change the RGBA light colour. We choose for example green lightning, so change it to the value 00 FF 00 FF.<br>
 +
In KCL you activate it with choosing the noticed ID. For change it go to [[KCL flag]].
  
 
== Links ==
 
== Links ==
 
{{Custom Track Tutorial}}
 
{{Custom Track Tutorial}}
 
[[category:Tutorials]][[category:Custom Track Tutorial]]
 
[[category:Tutorials]][[category:Custom Track Tutorial]]

Revision as of 09:18, 2 December 2011

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

Creating a Cannon

*KMP Modifier might be required*

Cannons are anything that trigger your vehicle to fly enourmous distances. They are present in Mario Kart games since Mario Kart 64, and in Mario Kart Wii they appear in DK Summit/Snowboard Cross, Maple Treeway, Rainbow Road, N64 DK's Jungle Parkway and GCN DK Mountain. They also appear in a variety of custom tracks; Altough Cannon City is a track dedicated specially for cannons, the one with the biggest number of then is SixKingLabyrinth.

To place one in your track, you first need to add one to your KMP file. To do so, you can use Khacker35000vr's KMP Modifier. The points in the KMP files tell you where you'll land at, at the end of the cannon. The cannon's y-angle must point in the direction that you want the cannon to launch, or else it will mess up and not go to the position you set it to. The value under ? controls the cannon type, which is explained below.

Now, you must add a new polygon to your Solidity model. It's the cannon trigger. As soon as you touch this polygon, the cannon will be activated and you'll appear in the point you've set at the KMP in record speeds (kinda). So make it a square at the edge of the ramp, right at the place where you're probably going to put the DK cannon or the Star Launcher at (those objects are just for decoration, just to let you know that there is a cannon there).

After you've imported your new polygon, generate the KCL. The value for the cannon trigger polygon is 0x11. If you test ingame now, the cannon should work.

Extra Info

  • If you want to place multiple cannons in your track, add more cannon KMP points and more launcher KCL polygons. When generating the KCL, the variation of the flag must be the same as the Point ID you're supposed to get to.
  • The settings for the KMP point are like this: FFFF is straight (like most cannons), 0001 is curved (like N64DKJP), 0003 is slow (unused, goes about 1/10 or 1/15 of the normal speed), 0002 is similar to 0001.

Editing models other than the course's

This is as easy as editing the actual course model. It's actually even easier.

If you want, for example, edit the texture of a goomba, that's an object, you just have to open kuribo.brres (it's the BRRES file for the Goomba) and edit it. It has a model and textures, just like the course. It's the same for the skybox, it's located in vrcorn_model.brres. The itembox is in itembox.brres, obviously. If you don't know what is the BRRES for a spcific object, just look for it. You'll find it soon.

Porting objects between courses

*SZS Explorer or Wiimms SZS Tools required*

This explains you how to port objects between course files. For example, if you want to place a thwomp in a track that's based off from GCN Mario Circuit, you must port a thwomp there. You can't simple place a dossunc (object for the Twhomp) in the KMP and expect it to work.

To do that, you must put the object's files (usually a BRRES, but sometimes includes effect and brasd files as well) in the other track's SZS file. Doing this requires either the SZS Explorer or the Wiimms SZS Tools.

SZS Explorer

This will teach you how to port with the SZS Explorer using a Goomba 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 the course that has it. They're kuribo.brres and the kuribo folder (along with the two files that are in it, of course) that's in the brasd folder. Right click then to do so.
  • 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. If there isn't a brasd folder in your new course file, right click the root and create one.

You should already be able to use a goomba in your new course. Remember that 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 (those are the ones without a 3d model, such as light emissors for example).

Porting skydome models, map models, course models, KCLs and KMPs is the same proccess: you export it from the original course, and you replace it in the new course. The best KCL to use is Maple Treeway's and the best map_model.brres to use is Mushroom Gorge's, if you want to know. 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 crate 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

Changing Post Effects

Post effects are meant to simulate the natural environment of the world. There are post effects to make courses look snowy, desert-like, very hot, etc. For example, if you decide to change a daytime course like Luigi Circuit so that it appears to be night time but don't edit the post effects, the course will still look bright and your characters will still seem to be in the sun, even if the level has been given a night-time sky. You must change post effects for lightning to be correct.

Swapping Post Effects

To change post effects, you simply export them from one course's file and import them into another, using SZS Explorer or Wiimms SZS Tools, the same as you would do with object files. Post effects, unsurprisingly, are found in the posteffects folder.

  • BBLM files - Glow, bloom
  • BDOF files - Focus, Sharpness and blur
  • BFG files - Fog
  • BLIGHT files - Lighting
  • BLMAP files - Post effect controller
  • ***1 files - Used for multiple post effects in the same course. Mushroom Gorge, for example, has post effect data for inside and outside the cave.

Editing Post Effect Files

A view of SZS Explorer's Hex Editor window with the Edit Menu displayed.

Currently the only method to edit post effect files is by Hex Editing. It is possible to find attributes by experimentally changing various hex values and then testing them in-game. The following attributes are currently known:

Fog

First you will need a posteffect.bfg file in your level; if there isn't one in the posteffect folder, import it from another level. You will want to find fog that already has the desired intensity because color is the only attribute currently known. Using SZS Explorer, open the file. Select Goto from the Edit Menu. Search for offset 0x0C. Then select Overwrite Mode to enable editing. The color is 4 bytes long and is in RR GG BB AA format; the alpha is seemingly ignored. Intense red fog, for example, would have the value FF 00 00 00.

Lightning

A view of a normal Hex Editor

First you have to export the Posteffect.blight in the posteffect folder, because editing on SZS Explorers Hex Editor might be difficult. Open it with your Hex Editor and search after the magic 'LOBJ'. The first object is the normal road, so search again after the magic. The second object is the shadow. If you need it go to the next 'LOBJ'. Then activate this Object, notice the ID, and Change the RGBA light colour. We choose for example green lightning, so change it to the value 00 FF 00 FF.
In KCL you activate it with choosing the noticed ID. For change it go to KCL flag.

Links