• 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!

Melee dat format...

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
A while back I was trying to figure out how the game could tell what file was what and I guess I never posted the results. Its the string table. The game knows the PlMsRe file from PlMsNr by the string table which comtains the name of the file.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Zankyou, so I think you stated this when you posted the kalos league stage, but I think the color structs aren't working with your model imports. If the material struct flag contains (00000004), then that means to use the color struct overlay. I'm guessing this is why the flickering happens.

When I was looking at the regular hyrule stage, it seemed like the material struct flag containing (00000002) = cast shading on the object due to light source.

But idk for sure...just trying to look into some stuff.
 
Last edited:

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Zankyou, so I think you stated this when you posted the kalos league stage, but I think the color structs aren't working with your model imports. If the material struct flag contains (00000004), then that means to use the color struct overlay. I'm guessing this is why the flickering happens.

When I was looking at the regular hyrule stage, it seemed like the material struct flag containing (00000002) = cast shading on the object due to light source.

But idk for sure...just trying to look into some stuff.
I havent really been consistent with how Im referring to them since no one has even seen them in the game, but the color struct Im referring to with the kalos league is similar to that of the shine's color except it has a different structure instead of being directly referenced in the display list. It different from the color node referenced by the material structure. Do you think the material structure's flag is responsible for this as well?
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
I havent really been consistent with how Im referring to them since no one has even seen them in the game, but the color struct Im referring to with the kalos league is similar to that of the shine's color except it has a different structure instead of being directly referenced in the display list. It different from the color node referenced by the material structure. Do you think the material structure's flag is responsible for this as well?
Oh I don't know anything about the Kalos League problem then.

The color struct offset, and therefore color struct data, is not being copied to the new RAM bone data. (I'm using the main stage of Return to Dream Land for this testing.)
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Oh I don't know anything about the Kalos League problem then.

The color struct offset, and therefore color struct data, is not being copied to the new RAM bone data. (I'm using the main stage of Return to Dream Land for this testing.)
I doubt I forgot to make a pointer for it. Any Idea why its skipping it?
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
The only difference is that I should have done dreamland before I realized you could add bones.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
So is the entire new Dream Land one single bone structure? Do you have the offset for the bone structure?
Its weird. I didnt change or add any bones. I just extended the object groups for that bone. I dont remember how many bones I used but it should be part of the main stage bone with the default platforms and stuff. This is before I started taking general notes down of offsets but Im pretty sure I jotted down what each bone set does somewhere. I could probably find it if you wanted.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Its weird. I didnt change or add any bones. I just extended the object groups for that bone. I dont remember how many bones I used but it should be part of the main stage bone with the default platforms and stuff. This is before I started taking general notes down of offsets but Im pretty sure I jotted down what each bone set does somewhere. I could probably find it if you wanted.
I found it like 5 mins ago.
0x00010aa8
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Well, I managed to single out an object and get the color struct working...kind of.

When the material structure flag contains (40000000), then the material follows transparency according to 0xC in the color structure. 1=opague, 0 = transparent.

transparency float = 0.5:
Capture.PNG



Then, changing the transparency float back to 1.0 and changing 0x0 of the color struct to red:
Capture.PNG


unfortunately the color structure still flickers...but anyway, I don't think that is what we are really interested in, in regards to stage shading.

We need it to be able to obtain shadow from the light source, which I believe should be flag (00000002) in the material structure, but changing it did nothing in my above example.
 
Last edited:

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Intentional or not, that looks absolutely savage. Someone should try to incorporate this into a good looking stage.
Terry, don't talk to me about savage pictures.

zankyou, the newer stage files seem to load the color struct fine.

This is what the material struct flag gives in this scenario when I have it exactly equal 0x00000002...
Capture.PNG
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Z zankyou , the only way I see colors being able to be displayed on each individual face of a single bone object is through the mesh/displaylist stuff. I see some color values in those structures on the HAL DAT format page.

Thoughts?
Object struct in question is at 0x83d38
 
Last edited:

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Z zankyou , the only way I see colors being able to be displayed on each individual face of a single bone object is through the mesh/displaylist stuff. I see some color values in those structures on the HAL DAT format page.

Thoughts?
Object struct in question is at 0x83d38
Ive added each color struct that the pac file had in hopes that even if it didnt load Id figure it out one day and correct it. Im not exactly sure how to go about it though. Ive only seen a color struct referenced by the displaylist once and that was captain falcon. It seemed to point to the vert data though so I didnt know what to make of it.

As far as the newer stages, Ive imported them the exact same way as battlefield using a new bone and going from there. Does the 0x00000002 have the same flickering effect. The flags seem so inconsistent that Im not sure why battlefield's platform becomes invisible. But Ive seen other weird effects, try changing the part of the platform that turn invisible to 0x40000002. Its how I fixed the water.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Ive added each color struct that the pac file had in hopes that even if it didnt load Id figure it out one day and correct it. Im not exactly sure how to go about it though. Ive only seen a color struct referenced by the displaylist once and that was captain falcon. It seemed to point to the vert data though so I didnt know what to make of it.

As far as the newer stages, Ive imported them the exact same way as battlefield using a new bone and going from there. Does the 0x00000002 have the same flickering effect. The flags seem so inconsistent that Im not sure why battlefield's platform becomes invisible. But Ive seen other weird effects, try changing the part of the platform that turn invisible to 0x40000002. Its how I fixed the water.
No, 00000002 does not flicker.

In the Hyrule stage, if the flag word equals 40000002, then the entire wall is invisible. If it equals 00000002, then it's like the above picture (notice the interesting black to maroon gradient).

For battlefields platform, I might have been using 40000002, which probably would have caused the invisibleness. I forget.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
So btw zankyou, unless you want an object to look like that 50% opacity dream land from above, there shouldn't be a reason to use the (40000000) flag. I know it made a difference in Dream Land but that one had broken color structs to begin with for some reason.
 
Last edited:

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Using the 0x4000 flag was the only way to get the water to show up in the foreground of battlefield though. Im sure theres more to it though.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
So I get whats going on now. The reason its not working for dreamland is because there isnt a color struct for that stage. Only color nodes referenced by the material struct. So the 0x00000002 flag is loading the color structs. This wont create the shading effect but this is a huge discovery on something I wasnt even sure if the game supported. If you look at the second image in the OP, the material flag for it should be 0x40000012 which is why its translucent and its loading the color struct.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
So I get whats going on now. The reason its not working for dreamland is because there isnt a color struct for that stage. Only color nodes referenced by the material struct. So the 0x00000002 flag is loading the color structs. This wont create the shading effect but this is a huge discovery on something I wasnt even sure if the game supported. If you look at the second image in the OP, the material flag for it should be 0x40000012 which is why its translucent and its loading the color struct.
Where is the pointer to this color structure that you are referring to?
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Mesh attribute structure. Its dealing with the displaylist and stuff.
Okay, good. That's what I wanted to hear...unfortunately, this is where I become less helpful...

But why can't you use it to create a shading effect? That's what vanilla Hyrule temple was doing, right?
 
Last edited:

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Okay, good. That's what I wanted to hear...unfortunately, this is where I become less helpful...
No its fine, the fact that its even loading the color struct is amazing. I just need to figure out how to get them to import properly and possible add transparency to them.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Okay, good. That's what I wanted to hear...unfortunately, this is where I become less helpful...

But why can't you use it to create a shading effect? That's what vanilla Hyrule temple was doing, right?
Could you tell me which pointer it is loading exactly for the color structs. Just 1 is fine. I need to know if its reading the right data.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Yeah although Im pretty sure I found the problem.
Edit: Got it
This is how it looks in brawlbox as well so I dont really know what gives the stage its blue color and blue highlights. But Im satisfied with this.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
I knew there was a reason I was still using the 0x4000 flag for materials. If I dont alpha isnt supported it seems. Achilles do you want to look into this or at least point me in the right direction for figuring out what this flag does.
This is what happens when I use 0x04000002
GALE01-141.png

But if I use 0x44000002 I get this.
GALE01-139.png
 

Attachments

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Yeah although Im pretty sure I found the problem.
Edit: Got it
zankyou....I loveyou. Everything looks gorgeous now. I'm stoked.

I knew there was a reason I was still using the 0x4000 flag for materials. If I dont alpha isnt supported it seems. Achilles do you want to look into this or at least point me in the right direction for figuring out what this flag does.
This is what happens when I use 0x04000002
View attachment 79687
But if I use 0x44000002 I get this.
View attachment 79689
It looks as though the transparency value in the color struct (pointed from material struct) for the front grass is not using a value of 1.0, but instead something smaller. Once you turn on 40000000, it starts using that transparency value. But I've also never been able to do 40000002, with your current imports, without making the entire structure disappear. So idk if things are different now.

Also, I'm concerned that you didn't sleep last night.
 
Last edited:

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
zankyou....I loveyou. Everything looks gorgeous now. I'm stoked.


It looks as though the transparency value in the color struct (pointed from material struct) for the front grass is not using a value of 1.0, but instead something smaller. Once you turn on 40000000, it starts using that transparency value. But I've also never been able to do 40000002, with your current imports, without making the entire structure disappear. So idk if things are different now.

Also, I'm concerned that you didn't sleep last night.
Hah I couldnt sleep because I was getting so close. But I didnt have anything to do until noon so I got a decent amount.
Do you know where its getting the transparency value. The 0x0002 half word seems to ignore the color structure (material referenced) for me. Not that I mind because Id take these colors over it any day. Also its really weird. I cant tell if its a shading effect or not. There are near 1000 colors in the color struct I imported so I cant just go through each one and see if its pseudo shading or not but it seems that theres a shading effect created by the sun clock? which isnt there in brawl box.

Worse case scenario is just that I have to use the 0x0400 flag for the stage but 0x4400 for the stuff that needs alpha. But Id rather have some type of universal flag instead of guessing and checking which ones I need.
 

Achilles1515

Smash Master
Joined
Jun 18, 2007
Messages
3,211
Location
Cincinnati / Columbus OH
Hah I couldnt sleep because I was getting so close. But I didnt have anything to do until noon so I got a decent amount.
Do you know where its getting the transparency value. The 0x0002 half word seems to ignore the color structure (material referenced) for me. Not that I mind because Id take these colors over it any day. Also its really weird. I cant tell if its a shading effect or not. There are near 1000 colors in the color struct I imported so I cant just go through each one and see if its pseudo shading or not but it seems that theres a shading effect created by the sun clock? which isnt there in brawl box.

Worse case scenario is just that I have to use the 0x0400 flag for the stage but 0x4400 for the stuff that needs alpha. But Id rather have some type of universal flag instead of guessing and checking which ones I need.
Yeah, idk. I would need to play around with the file, then. I feel your desire for a universal flag, but I don't think it would be good practice. For example, not everything needs the 04000000 for character shadows. Things start getting weird when it is always included.

Capture.PNG
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Fairly certain the light source is not in the ground param section. Just copied everything up to the point from battlefield into kongo jungle 64 and the light source was still behind the characters. I feel like Ive read somewhere about this but I could be making it all up. When I first started playing with stages I found some flags the manipulated shadows but its been way too long since then.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Confirmed it now. Changing the number of areas in the area table breaks the game if theres something that transforms.
 

zankyou

Smash Lord
Joined
Sep 12, 2014
Messages
1,055
Ive been looking into how the game manipulates platforms and what not. The strings being loaded look similar to that in the aj files. Figuring out moving platforms might actually be the first step towards cracking animations.
 
Top Bottom