• Welcome to Smashboards, the world's largest Super Smash Brothers community! Over 250,000 Smash Bros. fans from around the world have come to discuss these great games in over 19 million posts!

    You are currently viewing our boards as a visitor. Click here to sign up right now and start on your path in the Smash community!

A noobs guide to model swapping and glitch fixing :Update 10-8: Step by Step guide

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
well, a long time since a real update, but at this point, most everything has been covered. i put in a basic step by step guide, because some people apparently have a hard time using a guide if there isn't one. granted, this isn't so much of a guide as it is a place for all the model swapping notes.


This guide is aimed towards character model importing and fixing, but the basic model importing also kind of applies toward stages as well, but I don’t know enough about stages to answer questions about it. And if you already know how to import and replace models, feel free to skip to section 2. Also, I have a full list of the important bones towards the bottom of this guide, so you know. It has bone totals, TransN index, HaveN index, and EyeYellowM index numbers.

Also, before I begin, here are some important links to programs and such that you might need.

http://www.smashboards.com/showthread.php?t=238861 – BrawlBox, but if you didn’t already have it by now, why are you reading a thread about model swapping that requires BrawlBox?

http://www.mediafire.com/?dttmnkm2y0j – direct link to the bone adding program. FortWaffles made it. And you will most likely need it.

http://www.smashboards.com/showthread.php?t=263127 – MDL0 files from other games thread. It has the bone adding program there as well, but remember, it’s against forum rules to distribute the MDL0’s, you have to ‘obtain’ them yourself. It also has a guide of how to hex the MDL0’s to work in Brawl. Go there with questions about that stuff, this guide if for after the model works in Brawl.

http://forums.kc-mm.com/index.php?topic=14409.0 – bone hierarchy changer. You use this to change bone indexes and where the bone is physically located instead of a hex editor.

http://www.smashboards.com/showthread.php?t=284044 - download for Tabuu/OpenSA3. it's incredibly usefull, so go get it. it makes it so you can tell Brawl where to look for certain bones, and it can re-link hurtboxes.


And one more thing, some basic terminology, so you know what I’m talking about.
Bone index number – the number it shows in BrawlBox for bone index. Should be obvious, but the first bone is index 0, so just be aware.
Model importing = model rigging = model swapping = model replacing, basically.
Model = character = fighter, I interchange between them, but they are all the same, except that fighter is kind of aimed towards the actual fighters, and character is any character.
New Model = the model you want to put over a character
Replaced Character = the replaced character
As I think of a few others, I’ll put them here. But for now, let the guide begin.

Sections:
0 Step by Step Guide
1 Basic Model Importing
2 Important Bones
3 Glitch Fixing
4 Bone Hexing Guide
5 Tabuu Guide
6 FAQ’s
7 Lists

0 Step by Step Guide


because apparently some people have a difficult time following a guide unless it has a step by step portion, here you go.

step 1; get the model of the character you want to put over another (either the .mdl0, or the .pac/.pcs file).

step 2; get the FitCharacter00.pac/.pcs file for the character you want to replace.

step 3; open the FitCharacter00.pac/.pcs in BrawlBox, go to the .mdl0 file, right click, click replace, and replace it with the model you want. also, replace the textures using the same method.

and you're done! with the model swap, at least. the rest of what you'll need to do is purely glitch fixing. here's the basic order of what glitches to check for and fix as you go along. try doing all of these before testing in Brawl. that way, you will most likely have it work perfectly fine the first try. and you won't have nearly as many freezing issues.

glitch 1; does your new model have the same (or more) bones than the replaced character? if no, add bones in using the bone adding program (linked above).

glitch 2; does your new model have the TransN bone in the same place as the replaced character? if not (or if your new model doesn't have a TransN bone), then you'll have to A) if one slot swap: rename the bone in the same index as the replaced character (i have a list for those in Section 7) B) if full character project: edit the TransN Bone Reference in Tabuu (program linked above, and a mini tutorial of how to use Tabuu is inSection 5).

glitch 3; does your new model have the HipN bone in the same place as the replaced character? if not, then refer to glitch 2 to see how to fix it.

glitch 4; does your character have a Model bone over the replaced character's EyeYellowM bone? if so, then you'll have to edit the bone index by hexing it. i have a mini guide for bone hexing in Section 4. this one may also be a little tricky to notice at first, especially if your new model isn't from Brawl. if it is from Brawl, then all Model bones end with M.

these are the main glitches that you can pick out even before you try testing the new model in Brawl for the first time. there are a few others to watch out for, like not holding items properly (or at all) and being able to be hit from across the stage (hurtbox issues). for those, you'll just have to play around with the new model in Brawl before knowing if you even need to fix them.

as for the Sections, Section 1 is if you want a little more info on the steps i have listed above. Section 2 has more details about why the glitches happen. Section 3 is more detail on how to fix the individual glitches. Section 4 is about bone index hexing, and how to hex in general. Section 5 is a mini guide on using Tabuu. Section 6 is a very incomplete FAQ. Section 7 has a ton of lists, all bone index info for the important bones for all the Brawl characters (the fighters, not every single model).

so happy swapping! and remember, if you have any questions, just ask. this is a ton of info, and it can get a bit confusing if you don't know what you're doing.


1 basic model importing
This is the easy part. Make sure you keep unedited files somewhere as well, in case you mess up and wan to start over. Find the file you want, open it in BrawlBox, expand the ModelData[0], right click the MDL0 file (should be gray), click export, save it to an easy to find area, open the file you want the model to replace, go back to the MDL0 file, right click, click replace, select the file you exported, and that’s it. You should probably do the same with the TextureData[0], simply because that has all the textures the model will need. Also, don’t bother to mess around with the ModelData[10], because that’s just the character’s shadow and isn’t that big of a deal if you don’t have it, but feel free to replace it as well if you want.


2 important bones

Brawl makes a lot of assumptions when it comes to bone matching, hence why you can get some pretty weird looking characters. If the bones don’t match up enough, then the new model will be t-posed. Why? Because Brawl still assumes it’s loading the original character, therefore causing certain bone requirements before the new model will function properly. This is the list of those required bones, so far as I’ve been able to find and test as necessary. So before I go into glitch fixing, I want to explain why the glitches occur. I’ll go in order of obvious need to fix to unnoticeable.

2a Overall bone count. This is what was holding model importing back for so long. Basically, your model should have the same (or more) number of bones as the character being replaced. Having fewer bones will cause the game to freeze just after you select a stage, but before the fight starts. The new model can have about 2-3 bones less than the replaced character, but having fewer bones will cause the game to freeze when you shield.

2b TransN. The TransN bone is the bone that controls movement while on the ground. Not having a TransN bone, or having it misplaced will cause the model to run but not move. This is why the model itself may move, but the tracker (the P1 or the thing that’s always over the fighter) will stay in one place, or that the model stays in one place and doesn’t move. This is also referred to as the ‘Snap Back’ glitch.

2c EyeYellowM. This bone is only present in Brawl fighters, and only shows up when the fighter has a smash ball. Have you noticed some models only showing up when they have a smash ball? That’s because they have a Model bone (bones that end in M, like BodyM) over the replaced characters EyeYellowM. Most of the fighters have it as their second bone (bone index 1), which sometimes correlates with other characters BodyM bone (the BodyM bone is basically just a bone connected to the entire model, or just a portion of the model, hence why the model wont show up if it’s over the EyeYellowM).

2d HipN. The HipN bone is a little deceiving, because not having one or having a misplaced one will cause the grab and throwing glitches (yes, two separate glitches). The ThrowN bone also connects with throwing, but the HipN is the cause of the being grabbed glitch, because the grab animation grabs the HipN bone. how you can tell you have this glitch is when the new model is thrown, the model basically explodes into a bajillion polygons.

2e ThrowN. As mentioned above, the ThrowN connects to the grab and throw glitches. the ThrowN bone is what the character grabbing uses to grab another character, and it controls the shield. The ThrowN bone is almost always last for Brawl characters, and having a different bone in the replaced characters ThrowN index will cause a random body part to grow really big and then shrink with the shield, simply because of the way they decided to animate the shield, or if it’s on an added bone, the shield will be really tiny and at the character’s feet (this is because the added bones all reference the TopN bone, which is located at the bottom of the model).

2f HaveN. ] As obvious as the name implies, the HaveN is where the character holds items. Most of the characters have 2, all but Samus (because of her gun), Mario (I guess he’s special that way), Ivysaur and Pikachu (they hold items in their mouths), and Squirtle (he has 3, but the 2 in his hands are dummied out, but still there, so he uses the one in his mouth), and the Alloys (they have none, because they can’t pick up items). If the character doesn’t have enough original bones (bones in the model before adding any in), then the game will freeze when trying to hold items. Some items will work, it’s just the smaller items that a character holds that will freeze.

2g Hurtboxes. have you ever played as a new character, but could get hit from across the stage? Then that model has a hurtbox problem. Just a little terminology first: hurtbox = where a character can be hit, hitbox = where a character hits from. Hurtbox problems are incredibly annoying, mostly because of how random they are. I think I’ve seen almost all variations: an infinite horizontal line from where the character is standing, an infinite vertical line from where the character is, anywhere behind the character, anywhere in front of the character, a big circle around the character, and literally anywhere on the stage. If the new model has more original bones, then usually this isn’t as big of a problem.

There are a many other bones that are shared between all the characters, but those aren’t necessary (to model swapping, at least), but the bones that are more important are the TopN, XRotN, and YRotN. The TopN is the bone that basically tells Brawl ‘this is the model you are looking for’, and will always be the first bone, even if named differently. XRotN and YRotN are both used for moving the model in animations, like the TransN and HipN. The difference is that the X and YRotN bones are rarely used. The XRotN is usually set for how high the model is in an animation, so if your character is in the ground for an animation, reset the XRotN for the animation and it will work. And I’ve never really seen the YRotN used, but is does tell Brawl where the player tag goes (the P1 or whatever tag that floats above the character), and you can use it for one-slot resizings (covered in other tutorials).


3 glitch fixes

And now for the fixes to the glitches. I’ll go in order of the previous section. I have lists towards the bottom for all of these. and if your model doesn't have these (non-Brawl models), then you'll just have to rename certain bones. what i mean by that is that most models have most of these bones already, just not named correctly. An example is that the HipN is usually 'hip' or 'hips' on non-Brawl models, but the rest just depend on the game you got the model from, but are usually within the first few bones (although I have seen some models with them at almost the end of the bone structure).

3a Overall bone count. This one is now easy, thanks to FortWaffles’s bone adding program (download provided at the top of the guide). Just find how many bones the character you want to replace has, then how many bones your model has, and add enough bones to match. Simple, right? But there’s a catch. Two actually. First being that if you need to hex edit a model that has added bones, then you have to go down farther than you would before (due to the way that the bone adder works, it copies most of the model and pastes it at the end, so there’s basically 2 models worth of info, but you have to edit the second bone structure, otherwise the changes won’t show), and second being that you can only add a certain number of bones to a model before it starts overwriting other code in the model and cause it to not work right. the more bones that the model has originally, the more bones can then be added. I tried a model that has 10 bones originally, but I could only get it to have 56 at the very most, but a model that started with 23 bones accepted up to 76 (and could still possibly do more), so just a warning.

3b TransN, or the Walking and/or Running glitch. This can be a tricky one to fix, because the TransN of the new model MUST be in the same spot as the replaced model, but there’s 2 ways to fix it, a one slot swap, and full character fix.
One Slot Swap: Example - you want to replace Mario, he has a TransN of 7, therefore to avoid the walking glitch the new models 7th bone must also be TransN. The easiest way to fix it is to find a character that has the same TransN index and replace that one. If you can’t or don’t want to replace those characters, then you can either rename the bone that is in the TransN index of the replaced character, but this might cause issues later on, because Brawl is referencing a random bone thinking it’s the TransN when it really isn’t.
Full Character Fix: you can edit the TransN Bone Reference in Tabuu, but since you have to edit the FitCharacter.pac (the PSA file), the change will affect all costume slots. I have a Tabuu guide later (section 5). TransN bones still have to match up, but with Tabuu, you can tell Brawl where to look for it, instead of Brawl telling you where to put it.


3c EyeYellowM bone, or ‘why does my model only show when I have a smash ball?’ As I explained above, this bone is only active when you have a smash ball. Look at it this way, are Metaknight’s wings always out? No. Is his cape always out? No. The EyeYellowM works the same way, except when you have a smash ball. This is also why, say, Mario’s hat not appearing when over most other fighters, because Mario’s HatM bone is bone index 1, while most others’ EyeYellowM is also index 1. So how do you make the model show up then? Find where your new model’s BodyM bone is. Then, the easiest way to fix it is by bone hexing, and trust me, its one simple change, and I’ll have a picture showing exactly what you need to do. Either that, or you can put the model over Olimar, Yoshi, or ROB, because they don’t have an EyeYellowM bone. Or hope that the BodyM is lower in the bone structure. as a note also, there are other bones that only show during certain times, so it's just best to hex the BodyM (or whatever model bone you want showing) bone over the TransN (if you want it always showing, and it doesn’t have to be the TransN, it can be any other index).
There’s also a way to fix the EyeYellowM Reference in Tabuu, but this will affect every costume slot. In Tabuu, there’s a section called Model Display. Under that is a tab called Hidden, and the EyeYellowM Reference is in there. It’s usually the first one, but just check the Bone Index on the right to verify (again, it’s usually an index of 1). Then, edit to what you want it to be.


3d HipN, or the grabbing and throwing glitches. Yes, two different glitches from one bone, and the HipN has to be treated like the TransN, as in the HipN MUST be in the same index as the replaced character’s HipN index. Fixed in a similar manner as the TransN, though simply renaming may not work, it just depends on the model. But remember, if you put your character over a fighter that has identical TransN indexes, then the HipN indexes will also match, because the HipN is ALWAYS 3 bones after the TransN, for Brawl models at least (Tabuu can change the reference, and it’s exactly as I explained with the TransN, it affects all the costume slots, and i'll explain how to use Tabuu later).

3e ThrowN, or ‘why such a deceiving name?’ So basically, the ThrowN has little to do with throwing (it's used to grab another character), but it actually controls the shielding glitch. The way to avoid it is by having the same number (or more) of bones as the model being replaced. At least this is an easy one to fix and avoid.

And guess what? Now we can fix the shield glitch completely! First things first though, this will only apply to full character replacements, because it requires editing the FitCharacter.pac (the PSA file), so one slot replacements can’t be fixed this way. So to fix it, go here http://www.smashboards.com/showthread.php?t=284044 and download Tabuu. Then, get a clean FitCharacter.pac, it has to be an unedited one for now. Open it in Tabuu, then go to FitCharacter/MiscData[0] -> Sections -> Data -> Misc. the section we need is labeled BoneRef. The first one is the replaced character’s ThrowN index. To fix it, click it, and in the right window change the BoneIndex to where you want it on the new model, then right click it in the left window and click ‘Open Hex View’, and change the ‘As Int’ number at the bottom of the new window to match what you put in the previous. It might get a little tricky if your new model doesn’t have a specific ThrowN bone already, so you’ll want to find a bone that isn’t attached to the model to use as the ThrowN. After you’re done editing, go back up to the top, right click FitCharacter/MiscData[0], and hit save file. A message will pop up saying that it will replace the file, so just hit yes. About a minute later, an error message will pop up saying that Tabuu had some problem and must close. Don’t worry, though, it did save. Tabuu is still in development, so that will be fixed soon. Also, put an unedited FitCharacter00.pac in the same file as the FitCharacter.pac, this will help in seeing which bones are which when you look into the BoneRefs, so you wont have to search through the bone structure in BrawlBox while editing. If you have any questions, just ask.


3f HaveN, or the item grab glitch. This one took me a while to pin down, but to avoid it, the new model MUST have more original bones than the replaced character’s first HaveN bone (original being bones that the model had before using the bone adding program). Most of the first HaveN bones are around 33, I have a full list lower. And by more, I mean a few more, at least 2 or 3. And added bones don’t count. The bones MUST be bones originally in the model. So how do you fix it if it happens to your model?
For One Slot Swaps, and if the model can already hold items, many times the item is usually held in a weird spot, like the elbow, foot, or face. the way to fix it is to move (through hexing) the new model's HaveN bone to the replaced character's corresponding HaveN, and that will fix it. apparently the Cracker Launcher is still held weird, but that's because it has a specific animation it uses, meaning you can't fix that without making a new animation which would then affect all the costume slots.
This next method is for full character projects, because this requires FitCharacter.pac editing.
First, you’ll need 3 things, Tabuu (the program), a hex editor (yes, it requires some hex editing, but if you’ve done anything with my guide before, you should be pretty good with hexing. Right?), and the FitCharacter.pac of the character you’re replacing (the PSA file).

Now open the FitCharacter.pac in Tabuu, and go to FitCharacter/Miscdata[0] > Sections > data > UnknownO > and the 2 things in here are what we’ll be changing, just not in Tabuu. Click on the 0x000 and write down the FileOffset number, and probably the Value as well so you know what number you’re looking for.

Open the FitCharacter.pac in the hex editor and go to the FileOffset you wrote down. Around there will be what you’re looking for. This picture shows the pattern that you’ll see when you get there.


The red is the 0x000 Value, and the blue is the 0x001 Value, and the green is the ThrowN reference. They always appear in the same order, 2 of the 0x000 in a row, and all 5 of the 0x001 in a row. Be careful though, there are a few oddities, like Ganondorf’s Values are 00XX0000 instead of 000000XX, and Pikachu only has 4 0x001 Values (the first one is FFFFFFFF, I think). and the green value controls where heavy items are held, which is the character's ThrowN bone, meaning the new model should have it's ThrowN index there instead.

The reason I say around there is because Tabuu doesn’t count some of the Header data until the last of the file, so the rest of the Offsets are off a little. If you wrote down the Value as well, convert it to hex and look for it. An alternative/easier method would be to enter this into the search function of the hex editor: 000000XX 000000XX, where the XX is the hex value of the Value from earlier. There are 3 of the 0x000 numbers, and 5 of the 0x001 numbers, each reference telling Brawl where to put the item on the model when holding an item. The reason that Tabuu won’t work is because it only edits one of each of the numbers instead of all of them.

So once you find the numbers to change, it’s time to figure out where you want the new character to hold items. Open the new model in BrawlBox, and go to the part where you want the new model to hold items. I’ll use the arm as an example, since I’m sure that’s going to be the popular choice (it’s the same for right and left). The first Value, 0x000, corresponds to the replaced character’s HaveN bone, while the second, 0x001, refers to the HandN bone (these can also be the same, if your model is lacking in arm bones). Not all models will have a HaveN bone that you can easily use, but the good thing is that you don’t have to rename any bones for this to work (but if you do rename the bones, then it will borrow the animation for holding items, which may or may not look good). So once you have the bones you want to use, convert the BoneIndex (right window in BrawlBox while the bone of choice is highlighted) to hex, and put them into the hex editor, and save (just remember to get all 9 references).

and for your own reference, even your model does have the item grab glitch, it can still pick up and use some items. here's a list of what.
Smash Ball
Sandbag
Soccer Ball
Heavy Items (Barrel, Crates, Blast Box, Party Ball)
Mushrooms
Starman
Lightning
Timer
Healing Items (Food, Max Tomato, Heart Container)
Super Spicy Curry
Metal Box
Screw Attack
Franklin Badge
Bunny Hood
Warpstar
Dragoon Parts

basically everything that you don't have to hold.



3g. Hurtboxes, or ‘why does my character get hit from across the stage?’ glitch[/B this is quite the annoying glitch to fix, but we now have a way to fix it! Again, this will only apply to full character replacements, because it requires PSA editing, so one slot replacements can’t be fixed this way (if they have it, then they’re out of luck, no way to fix it). So to fix it, go here http://www.smashboards.com/showthread.php?t=284044 and download Tabuu. Then, get a clean FitCharacter.pac, it has to be an unedited one for now (unedited ones always open, edited ones might not). Open it in Tabuu, then go to FitCharacter/MiscData[0] -> Sections -> Data -> Misc. the hurtboxes are labeled as Hurtboxes. Under the Hurtboxes section, it will bring up all the hurtboxes that the replaced character has and what bones they’re attached to. You can change the size and location of them, but we want to re-link them to bones you’re new model has. Click the hurtbox you want to change, change the BoneIndex to where you want (it helps to have the new model open in BrawlBox to see which bones you want), then right click the hurtbox you just edited (in the left window), click ‘Open Hex View’, then at the bottom of the window in the box labeled ‘As Int’ put the same index number you just put in, then close the window. And that’s how you fix the hurtboxes! Just a warning, it will fix the problem for one player, but the hurtboxes may still be weird if there’s more than one of the new models fighting, it happened a few times to me. After you’re done editing, go back up to the top, right click FitCharacter/MiscData[0], and hit save file. A message will pop up saying that it will replace the file, so just hit yes. About a minute later, an error message will pop up saying that Tabuu had some problem and must close. Don’t worry, though, it did save. Tabuu is still in development, so that will be fixed soon.

But sometimes even this isn’t enough. If you still get random hurtbox problems, then this is what you’ll have to do.

First, open the FitCharacter.pac in Tabuu, then go to FitCharacter/MiscData[0] -> Sections -> Data -> Misc. the section we want is called UnknownT, just under the Hurtbox tab. Open it, and click on the first UnknownType1. What we care about is the Flags. The Flags contain data that points to bone indexes, and at least one of them is pointing to an ExtraBone, which is why the hurtbox problem is still there. And about the Flags, if you just look at it in the right hand window, they aren’t displayed correctly. From what I’ve seen, they show ‘1234’, when it should be ‘3412’. If you’re unsure, just right click the UnknownType1, click ‘Open Hex View’, and the Flags is the last set of bytes shown.

Now that you have the Flags, you need to convert them into binary. Use this list (Toomai made the list)

+----------------+-----------+-------------+
|Number (decimal)|Digit (hex)|String (bits)|
+----------------+-----------+-------------+
| 0 | 0 | 0000 |
| 1 | 1 | 0001 |
| 2 | 2 | 0010 |
| 3 | 3 | 0011 |
| 4 | 4 | 0100 |
| 5 | 5 | 0101 |
| 6 | 6 | 0110 |
| 7 | 7 | 0111 |
| 8 | 8 | 1000 |
| 9 | 9 | 1001 |
| 10 | A | 1010 |
| 11 | B | 1011 |
| 12 | C | 1100 |
| 13 | D | 1101 |
| 14 | E | 1110 |
| 15 | F | 1111 |
+----------------+-----------+-------------+

The rest of the explanation is from Eternal Yoshi (because I can’t really explain it much clearer. It’s just one of those things that it’s easy once you do it).


Example Flag: 24E10000

To Binary:

0010 0100 1110 0001 0000 0000 0000 0000

Then you take the first 9 bits(colored lime for you) and interpet them as a number.

You do this by copying the bits highlighted in green, opening this:

http://acc6.its.brooklyn.cuny.edu/~gurwitz/core5/nav2tool.html

and Pasting it in the lower section in the slot: Binary number to convert.

BE SURE TO REMOVE THE SPACES, VERY IMPORTANT.

Click Convert to decimal and that's the bone it's attached to(in decimal not hex).

If you want a new bone to attach it to, look at the top of that window, and type the bone
index you want in decimal number to convert.

Let's say I want bone index 20, the program gives me 10100

Then copy the number and paste it so that the last bit is the 9th one.

1010 0110 0001 0000 0000 0000 0000

Now fill the rest to the left with zeroes.

0000 1010 0110 0001 0000 0000 0000 0000

Now we convert this to hex.

0A610000

(back to my explanation) Once you get the flag back, right click the UnknownType1, and edit the Flags bytes accordingly (the last set of bytes out of the 8 sets). Once you change the Flags you need, go back to the top tab (the FitCharacter/MiscData[0]),right click it and save it. The random hurtboxes should no longer be a problem. And remember, you only need to change the Flags that have a higher bone index reference than the new model has for original bones. So if only 1 Flags is over the new model’s original bone count, then you only need to change that one. If 5 of them are over, then only those 5.

If you have any questions, just ask.


4 bone index hexing

Note: while I’m on the subject of hexing, http://kc-mm.com/?p=2106 is a great guide by Stickman on how to remove polygons through hex. I’ve had nothing but trouble from the auto polygon remover, and I’m sure I’m not the only one, so I thought I’d post what I found that really helped me.

Alright, here’s how you hex bones.



Key: black = the whole bone, blue = beginning of bone, red = bone index number, yellow = NodeId number, purple = flags, green = bone hierarchy, the very left hand numbers outside the box = offset number (if it ends on a number besides 0, just go that many bytes in).

For those of you who care, here's a list of all the bone properties. i listed the more important ones, but here's the rest of them
Here's every byte set that's used for bones (4 bytes each):

0x00 - Header Length (Usually 00D0)
0x04 - MDL0 Offset
0x08 - String Offset
0x0C - Bone Index
0x10 - Node ID
0x14 - Flags
0x18 - Pad 1
0x1C - Pad 2
0x20 - Scale X
0x24 - Scale Y
0x28 - Scale Z
0x2C - Rotation X
0x30 - Rotation Y
0x34 - Rotation Z
0x38 - Translation X
0x3C - Translation Y
0x40 - Translation Z
0x44 - Box Min. X
0x48 - Box Min. Y
0x4C - Box Min. Z
0x50 - Box Max. X
0x54 - Box Max. Y
0x58 - Box Max. Z
0x5C - Parent Offset
0x60 - First Child Offset
0x64 - Next Offset
0x68 - Previous Offset
0x6C - Bone Strings/Properties Offset
0x70 - FrameMatrix Set 1 Float 1
0x74 - FrameMatrix Set 2 Float 1
0x78 - FrameMatrix Set 3 Float 1
0x7C - FrameMatrix Set 4 Float 1
0x80 - FrameMatrix Set 1 Float 2
0x84 - FrameMatrix Set 2 Float 2
0x88 - FrameMatrix Set 3 Float 2
0x8C - FrameMatrix Set 4 Float 2
0x90 - FrameMatrix Set 1 Float 3
0x94 - FrameMatrix Set 2 Float 3
0x98 - FrameMatrix Set 3 Float 3
0x9C - FrameMatrix Set 4 Float 3
0xA0 - InverseBindMatrix Set 1 Float 1
0xA4 - InverseBindMatrix Set 2 Float 1
0xA8 - InverseBindMatrix Set 3 Float 1
0xAC - InverseBindMatrix Set 4 Float 1
0xB0 - InverseBindMatrix Set 1 Float 2
0xB4 - InverseBindMatrix Set 2 Float 2
0xB8 - InverseBindMatrix Set 3 Float 2
0xBC - InverseBindMatrix Set 4 Float 2
0xC0 - InverseBindMatrix Set 1 Float 3
0xC4 - InverseBindMatrix Set 2 Float 3
0xC8 - InverseBindMatrix Set 3 Float 3
0xCC - InverseBindMatrix Set 4 Float 3

just don't ask me what they all do.


Basically, bones are always 13 rows long, and the bone index number is always at the end of the first row. I threw in the other things I’ve found for those who know how to hex already. The NodeId and flags are also shown in BrawlBox, just under the bone index number. Also, you will need a decimal to hex converter, because BrawlBox shows everything in decimal, but it’s in hex in the hex editor (should be obvious there). I use the Windows calculator, but I have the superior XP on my laptop, so I don’t know about the others, but I would assume it’s still there. But in case you don’t know anything about hexadecimal coding, it’s rather simple to understand how it works. Decimal has 0-9, while hex has 0-9 and A-F, adding up to 16 numbers before repeating. So in decimal, you may have 11, but in hex you would have B.

So to change the index number (in red), all you have to do is find out what index number you want it to have, and change the last bit (in the pic, it would be the 02) to what you want it to be (in hex numbers). Simple, right? But just a few things you should know, not every bone likes to be moved. Avoid moving the TransN, for example, because it usually screws up the model when in game. But Model bones can be moved just fine, like the BodyM bone. One last thing, it’s fine if bones share indexes, just make sure the bone you’re moving wants to be moved first. This is how I usually fix the models that have a disappearing problem, I just re-index the BodyM bone (or whatever Model bone disappears) to be the same as the TransN, because I know the TransN bone is always shown. And that’s the basics of bone hexing.

and here's a few examples of why this is needed.



this first pic is when you just replace the models with the fighters, no hexing. the Mario Bros are missing their hats, Lyn's legs and sword appear, and Tails' tails appear. they all have a model bone over the EyeYellowM of the replaced characters.



this second pic is the after shot, when the Model bones are moved.

also, as a note, if a bone isn't directly attached to the model, then it can be moved wherever you want it to be. to see which bones are attached to the model, just preview your model in BrawlBox, choose the bone you want to move, and then increase the translations of the bone. you will quickly see if it is or isn't based on if anything on the model moves besides the little lines that represent the bone, that's supposed to move when you do this. Examples of unattached bones would be the BodyM, ThrowN, and the HaveN bones.

And another note, bones can share the same index number. Just make sure the bone isn’t attached to the model first.

and because i have so better place to put it, i'll include it here. some models have a tendancy to do wierd things if from games other than Brawl. it's only natural, seeing as not every game is programmed in exactly the same manner. but i have a trick that will help one problem, the model disappearing when too far from the center of the stage (usually from the game Mario and Sonic at the Winter Olympic Games). the reason this happens is because the model has different flags that Brawl mis-interprets. here's a pic to show you how to fix it.



as you can see, i've highlighted two different models, a clean Ness model, and a model from Mario and Sonic at the Winter Olympic Games (too long of a title...), and what should be obvios is the point i'm trying to make. the Ness model has all 0's for the unknown values of his model, but the other doesn't, which is causing the problem. there's two ways to fix this. one is to change the values to 0 in BrawlBox (if the numbers are black, then you can change them), or my approach (because BrawlBox wouldn't save those changes) is to manually hex the .mdl0 file. here's how to do the latter.



extract the .mdl0 file you want to edit, load it in a hex editor, and this is right at the top. most/all .mdl0's look like this, because it's part of the model header data, so it should be in the same place for all models. anyways, change all the highlighted portions to 0, except the last one. for the last one, only 0 out the red portion (i highlighted the entire bit so it would be easily noticeable).

and now the model shouldn't have weird problems! well, as long as you've followed the rest of my guide...


5 Tabuu Guide

so it's occured to me that not too many people know how to use Tabuu/OpenSA3. so here's a (brief) guide on how to use it!

first, download Tabuu. http://www.smashboards.com/showthread.php?t=284044.
second, get the FitCharacter.pac (the PSA file) of the character you're making. and keep in mind that this is basically PSA on steroids, meaning no one-slot character fixes.
third, open the FitCharacter.pac in Tabuu. now you should be looking at something like this.



it's extended to the portion that we want. the main editing (as far as model swapping is concerned) is in FitCharacter/MiscData[0] -> Sections -> Data -> Misc. and then Hurtboxes and BoneRef is what we're concerned about. you may want to save this pic because it shows the BoneRef order, it will always be in this order, even if Tabuu doesn't show the names. really, it's only the first 5 that we care for because this is where you tell Brawl where to look for the bones that have to be in a certain place (TransN, HipN, and kind of the ThrowN). to change them, click on the BoneRef you want to change, like the TransN (5th down). say your model has a TransN of 2, but you want to replace Mario who has a TransN of 7. click the TransN BoneRef, and in the right hand window, some options will show up. change the index from 7 to 2, and click something else to make sure the change is kept. now, right click the TransN BoneRef in the left hand window, and click 'Open Hex View'. in the new window, you'll see the old index in the line called 'As Int'. change that from 7 to 2, and click in one of the other lines, otherwise the change won't happen (not sure why, but it's the way it is). now, when you're done making changes, go back to the very top, right click the FitCharacter/MiscData[0], and click 'Save Changes'. it will bring up a warning, just hit yes, and then the program will crash after a moment. it's (not really) supposed to happen, but the changes will be saved.

and the Hurtboxes are changed the exact same way, except that it shows a little more data to change. you don't really need to change the height or size of any of them, but you can. if you do, though, you'll need to put the changes in the 'As Float' line in hex view, otherwise it might not work right. i haven't done much with the hurtboxes besides re-linking them to other bones, so i don't have much advise, except that trial and error is about the only way to make them work right.

and you could do everything that PSA does in Tabuu, including editing the Pokemon Trainer's Pokemon, and Dedede (PSA couldn't, unless you risked constant file corruption that PSA 1.3 gave), so you know.

and there might be a few files that Tabuu can't open. i'm not sure why, because Dantarion said he fixed it so Tabuu can open any PSA file. if it's a problem, go to the thread that you downloaded Tabuu from and bug him about it. or you could manually hex it. Tabuu gives the offsets for what it's changing, it's just a few rows off because it doesn't include the header data in the offset that Tabuu shows. you'd just need a clean FitCharacter.pac to look at the offsets, and then open the one that Tabuu won't open in a hex editor and change it there.

so, i hope this helps you learn how to use Tabuu! (i could go on, but it's pretty much the same that you've just read. again, trial and error. how do you think i know all this stuff?)



6 FAQ

I’ll probably add some later as more questions are asked. But feel free to ask, just remember, provide as much detail as possible, it’s kind of hard to diagnose a problem you have when all you say is ‘the (blank) bone isn’t working for me’, and that’s all you say.

Q: what character is the best to replace?
A: at this point, it depends on who you don’t like and think never should have been in Brawl to begin with. But I would advise avoiding Peach, Zelda and ROB, because they have 103, 105 and 163 bones, respectively, unless your new model has a lot of bones to begin with (probably over 80).


Q: Where do I find a good hex editor?
A: Google Google. I've used hex workshop, but it was only a trial version. I recommend HxD, because it's free (if it’s free, it’s for me), and it does what we need it to do.


Q: I can't find the offset number.
A: in BrawlBox, when you click the bone you want to change, look in the window on the right hand side. that is where you'll find the offset, it's labelled as MDL0 Ofset. remember, in BrawlBox, the offset is in decimal form, and no, that's not a negative sign, it's BrawlBox's way of saying that the number is in decimal form. so take that number and convert it to hexidecimal. then open the .MDL0 in a hex editor, and go to where the offset tells you. on the left hand side, you'll see offset numbers, but many times yours is in the row. say the offset you get is AF8, but the left hand numbers go from AF0 to B00. this means you go in 8 bytes from the first of the AF0 row, and there's the offset you're looking for.



Q: My new character freezes when I choose it in the Subspace Emissary. Why?
A: ...I'm working on it.


7 lists
I’ll separate the lists into individual bones, but I may combine all of them into one list, so you can see everything for one character together. And keep in mind that these are index numbers, so the first bone is actually indexed as 0. Also, the lists will be in order of how they appear in alphabetical order before their names are changed, as in Koopa is Bowser and that’s why he’s not at the top of the list. Also also, I didn’t include the Pokemon Trainer himself, but his bone structure is almost identical to Olimar. One last also, I’m including the Alloys, but excluding Giga Bowser and Wario Man, because the Alloys are used more than the other two.

Total bone count
C. Falcon – 64
Dedede – 63
Diddy – 70
DK – 62
Falco – 71
Fox – 67
G+W – 97
Ganondorf – 69
Ike – 73
Kirby – 60
Bowser – 76
Link – 79
Lucario – 55
Lucas – 64
Luigi – 62
Mario – 62
Marth – 70
Metaknight – 76
Ness – 66
Peach – 105
Pikachu – 47
Olimar – 45
Pit – 91
Ivysaur – 54
Charizard – 57
Squirtle – 46
Ice Climbers – 45
Jigglypuff – 63
ROB – 162
Samus – 47
Sheik – 62
Snake – 69
Sonic – 82
Zero Suit Samus – 66
Toon Link – 82
Wario – 78, 59
Wolf – 72
Yoshi – 77
Zelda – 103
Red, Yellow, Green Alloy – 33
Blue Alloy – 38
Basically, unless your model already has a ton of bones, don’t even bother trying to replace ROB. And the reason Wario has 2 numbers, his WarioWare costume has more bones than his overalls costume.


TransN
C. Falcon – 3
Dedede – 5
Diddy – 3
DK – 2
Falco – 3
Fox – 8
G+W – 11
Ganondorf – 3
Ike – 9
Kirby – 5
Bowser – 4
Link – 3
Lucario – 7
Lucas – 2
Luigi – 6
Mario – 7
Marth – 8
Metaknight – 2
Ness – 4
Peach – 4
Pikachu – 2
Olimar – 1
Pit – 9
Ivysaur – 2
Charizard – 2
Squirtle – 2
Ice Climbers – 2
Jigglypuff – 2
ROB – 1
Samus – 2
Sheik – 2
Snake – 10
Sonic – 18
Zero Suit Samus – 8
Toon Link – 2
Wario – 2
Wolf – 8
Yoshi – 1
Zelda – 7
Red, Yellow, Blue Alloy – 3
Green Alloy – 2
Sonic was always an over-achiever, he literally has 15 face bones, so don’t bother replacing Sonic if you don’t want the walking glitch, or worse, depending on the model.


EyeYellowM
C. Falcon – none
Dedede – 2
Diddy – 2
DK – 1
Falco – 2
Fox – 2
G+W – none
Ganondorf – 1
Ike – 1
Kirby – 3 and 4
Bowser – 1
Link – 1
Lucario – 1
Lucas – 1
Luigi – 2
Mario – 2
Marth – 1
Metaknight – 2
Ness – 2
Peach – 2
Pikachu – 1
Olimar – none
Pit – 1
Ivysaur – 1
Charizard – 1
Squirtle – 1
Ice Climbers – 1
Jigglypuff – 1
ROB – not sure
Samus – 1
Sheik – 1
Snake – 1
Sonic – 2
Zero Suit Samus – 1
Toon Link – 1
Wario – 1
Wolf – 2
Yoshi – none
Zelda – 1
All Alloys – none
Kirby has 2 because he has different polygons for when he’s big (inflated or while someone is swallowed), hence the second set. I couldn’t find one on ROB, and his bone structure is literally a maze to navigate. A few of the characters may also have other Model bones that only show during certain actions, just a warning. And the Alloys don’t have one because of the obvious lack of a final smash for them. Why have a bone if you don’t need it?


HipN – just add 3 to the TransN number.

ThrowN – almost always the last bone.

HaveN
C. Falcon – 32, 55
Dedede – 32, 54
Diddy – 34, 57
DK – 30, 54
Falco – 41, 65
Fox – 41, 63
G+W – 29, 59
Ganondorf – 41, 65
Ike – 48, 69
Kirby – 33, 40
Bowser – 44, 70
Link – 39, 67
Lucario – 31, 53
Lucas – 34, 57
Luigi – 34, 57
Mario – 57
Marth – 48, 64
Metaknight – 15, 40
Ness – 37, 59
Peach – 72, 101
Pikachu – 34
Olimar – 19, 41
Pit – 43, 72
Ivysaur – 23
Charizard – 29, 42
Squirtle – 8 (17 and 27 also, but these 2 aren’t used)
Ice Climbers – 22, 39
Jigglypuff – 36, 43
ROB – 35, 55
Samus – 32
Sheik – 30, 57
Snake – 29, 57
Sonic – 45, 76
Zero Suit Samus – 27, 54
Toon Link – 36, 70
Wario – 37, 67
Wolf – 39, 60
Yoshi – 34, 73
Zelda – 69, 99
All Alloys – none
Again, most characters have 2, but to avoid the item grab glitch, you only have to have more original bones than the replaced character. And since the Alloys can’t grab items to begin with, they don’t have any.
 

Fen__

Smash Ace
Joined
Mar 25, 2008
Messages
727
Just gave it a quick read. Nice guide, but to my knowledge, no one has actually been able to remove Olimar's antenna glow. Pikmin are removable, though.
 

Akuma2120

Smash Ace
Joined
Mar 27, 2008
Messages
826
I tried putting Shadow's assist trophy model over Sonic, but his feet were stretched to the middle of the stage, and they stayed there, and he also couldn't run

But I followed the steps to fix the TransN and HipN glitches exactly and changed the bone indexes to match those of Sonic, so what did I do wrong?

EDIT: Forgot to say, I used fortwaffles bone heirarchy changer to change the bone index, then I used his bone adder program to add the bones in that order, could that create a problem?

EDIT2: Ok, I've tried every possible approach, I've only added bones and not touched the HipN or TransN, and the same problem occurs except his upper body is stuck in the middle of the stage, then I tried editing just the HipN, and both his legs were stuck in the middle, then I tired just the TransN and only his left foot was NOT stuck in the middle

And renaming the bones won't let me save a .pac from it because some key dictionary error shows up

Can anyone get Shadow's model over Sonic for me, I know how to fix the wavy messed up spines, I already got that working I just need to have the model work successfuly
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
@Fen, i kind of thought that too, but i thought someone said they did it through PSA.

@Akuma2120, the problem is you put him on Sonic. Shadow's TransN is 1, so try putting him over Olimar or Yoshi first, and see if that helps. i think the reason it does that is because Sonic's TransN is 18, because he has 15 face bones, so Brawl is treating most of Shadow's body like face bones.
 

Akuma2120

Smash Ace
Joined
Mar 27, 2008
Messages
826
@Fen, i kind of thought that too, but i thought someone said they did it through PSA.

@Akuma2120, the problem is you put him on Sonic. Shadow's TransN is 1, so try putting him over Olimar or Yoshi first, and see if that helps. i think the reason it does that is because Sonic's TransN is 18, because he has 15 face bones, so Brawl is treating most of Shadow's body like face bones.
Someone has gotten him to work over Sonic on these boards but quit because they couldn't fix the wavy spines, but I know how to fix that, I just need the model working properly
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
what the bump?
yeah, i've been meaning to do that for at least a week. i've been buried in homework and school projects, but i finally have some time today that i can put it in.
 

Eternal Yoshi

I've covered ban wars, you know
Joined
Mar 3, 2007
Messages
5,450
Location
Playing different games
NNID
EternalYoshi
3DS FC
3394-4459-7089
Yeah. Pikazz's post is here.

http://www.smashboards.com/showpost....postcount=4386

One more thing to note.



As well as changing the values that Pikazz showed, you need to change one last value to make holding of heavy items work correctly.

You see where 2D is in that picture relative to the other values?
That's where the ThrowN bone value would go.
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
huh, didn't realize that. best i edit that now.


Edit: and done.
 

pikazz

Smash Lord
Joined
Dec 6, 2009
Messages
1,868
Location
Sweden, Umeå (Currently in Seattle)
NNID
pikamaxi
I need a little idea talks to you snoopy since you know alot with bones hex.
I am trying to find a cure against cancer freeze then grab glitch and this is what I wrote in Fully working character thread
I am trying to see how to fix freeze then grab glitch.
it seems all I have tested like to be grabbed over olimar. tried lucas too but there, only dusknoir liked to be grabbed, the rest froze.
I just want to see a connection, then things can be fixed
It also seems that X/Yrot Bone (with ThrowN) has something to do with it, not HipN bone

the character I tested:
Dusknoir
Driblim
Darkrai
Wheelie
Popperan

need to fix things first before I test out more
(Why I wrote it here is because all want to fix "freeze when grabbed" glitch on their character lol)
are you sure it is the HipN bone or could it be Y/XRotN because after that I looked in the animations "catch---" they have X/YRotN and ThrowN bone there he is grabbed :/
or maybe it is other bone related things like hands or shoulders :/
Yeah. Pikazz's post is here.

http://www.smashboards.com/showpost....postcount=4386

One more thing to note.



As well as changing the values that Pikazz showed, you need to change one last value to make holding of heavy items work correctly.

You see where 2D is in that picture relative to the other values?
That's where the ThrowN bone value would go.
I found it later after I post the guide :awesome:
but I didn't have time to update it cause I had vacations

anyway, it is kinda weird to mix with that because it don't like to be on some bones but it like the first "extra bone" to be on, not the rest extra bones D:
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
freeze then grab? i don't think i've had to deal with that one before. is it when a character tries to grab a new model character that it freezes, or when the new one tries to grab someone else?

hmm, Wheelie has the problem... is it the same thing with Gemini's Toad? i know that it freezes when others try grabbing Toad.
 

pikazz

Smash Lord
Joined
Dec 6, 2009
Messages
1,868
Location
Sweden, Umeå (Currently in Seattle)
NNID
pikamaxi
freeze then grab? i don't think i've had to deal with that one before. is it when a character tries to grab a new model character that it freezes, or when the new one tries to grab someone else?

hmm, Wheelie has the problem... is it the same thing with Gemini's Toad? i know that it freezes when others try grabbing Toad.
obs, my bad. "freeze then grabbed". when someone trying to grab the new character
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
ah, then i've only encountered this once, with Gemini's Toad. tell me, with all the ones you've tested, did they have an XRotN and YRotN bones? did they all have a ThrowN bone?

Toad has none of them, which could be the problem. i'm guessing that the pokemon in your list are from Pokepark Wii, meaning they don't have enough bones for the XRotN, YRotN and ThrowN, but i'm not sure about Wheelie or Popperan.
 

Snoopy

Smash Journeyman
Joined
Jan 3, 2010
Messages
367
SmashClash, sorry, but i don't know anything about item hexing. though if i were to take a guess, i'd say to find name of the smoke graphic, and then open the file in a hex editor and look for it.

Dark Sonic 15, maybe try doing what the error message suggests? that should be the obvious first step. if it doesn't work after that, try re-downloading Tabuu and see what happens.
 

jellyfishjosh

Smash Rookie
Joined
Jun 10, 2011
Messages
16
help

so how do you make them hold items right? because i cant get mecha sonic to hold it on his hand. it is on his head i want it on his hand tell me please:c
 

999HP

Smash Rookie
Joined
Apr 23, 2014
Messages
3
So I just have this model I've made and I want to place it over the Captain Falcon skeleton. Does this mean my model needs to be completely rigged with bones and such?
 
Top Bottom