[Stages] Wall / Collision Data Edits

usagiZ

Well-Known Member
I've been trying to figure out how to edit the collision data for doa2u stages, and was partially successful in my most recent tests.

Collision Test 1:

0zee5Qw.jpg
So for collision test 1, I copy-pasted a section of data from one stage_dat.bin onto this highlighted section of the island's stage_dat.bin and this was the result.
This was before I noticed the patterns for the specific data sections, so this was just a lucky shot in the dark.

Copy-pasting that bit of data somehow created a half-wall in the middle of the first island. Notable things include, the fact that you can walk through the new wall, and that it doesn't cause wall throws at all.

Collision Test 2:

xprU5iL.jpg
For this test, I zeroed out this chunk of data at the start of the stage_dat.bin, and the result was that you could walk through walls, as long as you didn't hit the opponent with a wall splat move.

Zeroing out that data also removed the slope and altitude information for the stage, which is why the characters stay on the same level on the Y axis regardless of the stage's geometry.

One of the results of that change is that the camera starts acting strange when you walk outside the previous bounds of the stage. If you go too far out of bounds you start to rubber band back within the expected bounds.

If you zero out the entire file, or delete all the data in the file altogether, the collisions are all nullified and you can walk out of bounds without the camera problem iirc.

======================================================================================================

After noticing some of the patterns in the data, I was finally able to change wall types:
I started with one of DOA2U's beta/test stages "sWAL_dat.bin"
MvQK4wB.jpg
The data in the second red circle is the pointer to the wall type data for this stage, but I had to add the data in the first red circle to get to the intended destination.
P9eKhSY.png

0x3BB4 + 0x0004 = 0x3BB8.

After going to 0x3BB8, we get to a bit of data that looks like this:
mFPs8Kz.jpg


The large area outlined in red is a small part of the wall type data for this stage.
Each wall type seems to be defined in 8 byte sections.
The 8 byte section of data highlighted in multiple colors is one example of a wall definition - not sure what each part means, but I think it reads something like this:

[18 00] = wall start
[19 00] = wall end
[00 C0] = unkown currently
[10 00] = wall type

My current idea of how walls work in DOA2U is that the wall start and wall end values act like fence posts, between which the wall is actually spawned.
I've tried changing the values before, and the wall did end up spawning slightly differently, like at a diagonal between two other walls - which is why I now think that fence post idea makes sense.

Changing wall types is as easy as changing the two byte wall type value.
It can be a little tedious figuring out which 8 byte chunk is the wall you want to change, however.

There's quite a few wall types in DOA2U, each for specific circumstances. Here's a list of all the ones I've tested:
10 = invisible / hits when rolling
12 = full wall + wall throw
13 = full wall + wall throw
14 = half-wall
15 = half-wall - no wall throw
16 = fall off / slip
17 = half-wall - no wall throw + hits when rolling
18 = half-wall - no wall throw
19 = invisible / hits when rolling
1A = half-wall + wall throw
1B = half-wall + wall throw
1C = invisible wall
1D = invisible wall
1E = invis / hits wall when rolling
1F = full wall
20 = half-wall
21 = fall off / slip
22 = fall off / flip over fence
FE = pass through? weird rubber banding effect

Using the info from my findings with wall type editing, I tested a few more things.
Here's some more examples of the results I've had after changing the wall type values on certain stages:
g6ySaJ3.gif

In this one, I was trying to see if I could make the characters go back into the Koku An, after already being in the outdoor portion of the stage.
The stage obviously isn't coded to work that way, so the transition to outdoors just repeats instead of going back inside :(


GdfoW9w.gif

This one was just for fun. I wanted to see what would happen if I launched Hitomi into the abyss, and for some reason we return to the starting area.
I think this stage might have originally been planned to transition to the start if you get knocked off the bottom platform - or it's just doing that because I'm changing the wall to something it shouldn't be and it's glitching lol.

--------------------------------------------------------------------------------------------
I'm hoping to eventually know enough about the way stages are coded so I can give Bass' Truck stage some invisible walls and include it as a playable stage.
cRrlxwL.gif

Currently, you can just walk out of bounds in this stage forever lol.

If stage coding is somehow eventually figured out, it might even be possible to create entirely new stages - since there's a blender tool that lets you create .xprs from new geometry.

Anyway, I'll post my findings here if I figure anything else out.
 
Last edited:

dee4doa

Member
This is an amazing find thank you! I was trying to figure out DOA2 stage collision values back on Dreamcast (I wonder if the .bin collision formats are the interchangable DOA2/DOA3/DOA2U/DOA4 with eachother?)

I'd love to try this with the original Dead Or Alive 2 (Sega Naomi/Dreamcast build) to see if there are any hidden areas anywhere on the maps. Can't wait to try this in the 'Spiral' stage and disable the glowing barriers to see if I can be knocked down to a hidden lower level that was cut or unused.
I'm hoping some of the 1999 SEGA NAOMI tech demo stages are still somewhere on these maps in the final release but are unused/inaccessable to the player.

bg32-114708.jpg

bg12-114690.jpg

The textures in this beta version of the stage were reused in the final, the actual 3D meshes and collisions are VERY different though. It seems like there is a stair mechanic still possibly in the code of the original DOA2 (image above with tina) though I'm not sure if that is just cosmetic or was actually used ingame and was cut from the release until DOA2U?

I actually remade this area in Blender (Though I'm going off 2 source images from the 90s which is very difficult to remake fully) with the DOA2 textures and converted it to .XPR and imported into DOA2U and ran with CXBX-R. My stage loaded great! but no collisions

Finally Im wondering how to convert the .XPR exporter to the latest version for use in blender (2.80)? my DOA blender 3D tools will not work now:(
 

usagiZ

Well-Known Member
This is an amazing find thank you! I was trying to figure out DOA2 stage collision values back on Dreamcast (I wonder if the .bin collision formats are the interchangable DOA2/DOA3/DOA2U/DOA4 with eachother?)

I'd love to try this with the original Dead Or Alive 2 (Sega Naomi/Dreamcast build) to see if there are any hidden areas anywhere on the maps. Can't wait to try this in the 'Spiral' stage and disable the glowing barriers to see if I can be knocked down to a hidden lower level that was cut or unused.

-snip-

I actually remade this area in Blender (Though I'm going off 2 source images from the 90s which is very difficult to remake fully) with the DOA2 textures and converted it to .XPR and imported into DOA2U and ran with CXBX-R. My stage loaded great! but no collisions

Finally Im wondering how to convert the .XPR exporter to the latest version for use in blender (2.80)? my DOA blender 3D tools will not work now:(
Nice! It's good to know that using the blender export tool to make stages actually works. I hadn't tried it myself, but assumed it would be possible since making parts for costumes works.

Yeah, I do think DOA2U and DOA3 have the same stage_dat.bin format. They both have the same wall test stage in the data, so I would assume it didn't change between the two games.
MvQK4wB.jpg

It would be really interesting to see if this works on the dreamcast version. If you try it, please post the screenshots here and share with the thread if you can.

I had a few issues trying to get the export tool to work in the past, and the problem in my case was that I forgot to include some essential files when I copied over the tool into the new version's folder. I kept getting an error while clicking export to xpr, and it was resolved once I copied over all the essential files. If missing files isn't the problem, you might have to use the older version of blender that did work instead of the newer version. Just in case, here's my backup of the export tool.

Also, welcome back o/
 
Last edited:

dee4doa

Member
Here's an example of my DOA2 Sega Naomi demo stage (W.I.P) as you can tell it's untextured because blender gives me errors when converting/importing my textures into the .XPR file do my textures have to be in DXT format?

blender does let me export the 3D mesh untextured though (which is a good sign)

All that's left is the textures, the collisions and then I'll go ahead and remake the rest of the pre-alpha NAOMI build stages from 1999 or ones of my own creation!
1551910797097.png
1551910889500.png
 

usagiZ

Well-Known Member
Oh nice! Thanks for the screenshots - Yeah this collision stuff needs to be figured out asap - Having stair interaction would be amazing for this stage.

Hmm... I wonder what's causing the texture export issue? As far as I know, it doesn't matter what format the textures are in, the exporter always makes them dxt1 or dxt5 depending on what settings you choose in the material / texture windows in blender.

Q4SbIuq.png

zivPe3Y.png

Ticking the "Alpha:" box makes the texture DXT5.

There's other things too, like ticking the "Mirror:" box makes it have a reflection overlay texture.
To do that you'd need two texture slots - my example image only has one, but you'd apply the mirror texture to the second texture slot.

You can also set the quality of the textures after you hit export and are in the window to name the file:
EcNRddi.png
 
Last edited:

dee4doa

Member
No matter what I do, I keep getting this error :(

1551924280073.png

EDIT: I fixed the issue! :D:thumbs up:
 
Last edited:

Tina2040_

Well-Known Member
Here's an example of my DOA2 Sega Naomi demo stage (W.I.P) as you can tell it's untextured because blender gives me errors when converting/importing my textures into the .XPR file do my textures have to be in DXT format?

blender does let me export the 3D mesh untextured though (which is a good sign)

All that's left is the textures, the collisions and then I'll go ahead and remake the rest of the pre-alpha NAOMI build stages from 1999 or ones of my own creation!

How'd you go with this in the end @dee4doa ?
 

dee4doa

Member
How'd you go with this in the end @dee4doa ?
Aaah sorry I've been quite busy but I couldn't seem to get the textures to export as I got an error, I didn't get it if I had no textures so it's something to do with the textures being converted that my blender doesn't like :(

I've actually had lighting work with just the default Blender point lighting (I tested the colour/intensity and it worked)

As for the collision data, I remember a Japanese person back on DCforums created a custom collission map using something called 'Depth Map'? I'm not an expert at 3D so I may ask a friend about it. It would be awesome to convert DOA4 stages into DOA2U.

What I did to create that was rip the textures from the DC version, create my own 3D arena (using very few screenshots as references) and then export.

Finally what you need to know is that when creating custom stages, always use the empty placeholders! I tried replacing a normal stage but it crashes the game so it seems the stage data might be hard coded into the .xbe file?

I actually had fun testing small maps from different games, I had imported the Sonic Adventure 2 train station map just for fun to see if it would load and it did! xD
 

leidoa

Member
Aaah sorry I've been quite busy but I couldn't seem to get the textures to export as I got an error, I didn't get it if I had no textures so it's something to do with the textures being converted that my blender doesn't like :(

I've actually had lighting work with just the default Blender point lighting (I tested the colour/intensity and it worked)

As for the collision data, I remember a Japanese person back on DCforums created a custom collission map using something called 'Depth Map'? I'm not an expert at 3D so I may ask a friend about it. It would be awesome to convert DOA4 stages into DOA2U.

What I did to create that was rip the textures from the DC version, create my own 3D arena (using very few screenshots as references) and then export.

Finally what you need to know is that when creating custom stages, always use the empty placeholders! I tried replacing a normal stage but it crashes the game so it seems the stage data might be hard coded into the .xbe file?

I actually had fun testing small maps from different games, I had imported the Sonic Adventure 2 train station map just for fun to see if it would load and it did! xD
i used to get the same problem, to export the xpr with textures just run blender as administrator it works ;):thumbs up:

i used blender to make custom costume parts
took me ages to do it

KASUMI copy.jpg


its still not finished though, i need to add gloss
to the custom parts but i still don't know how
:(
 

dee4doa

Member
1587763772882.png

It would be awesome to actually create collisions for cutscene stages so we could make them fun to play. Some cutscenes like the Desert and Snowing Miyama actually are just reskins so the data is the same.

Have you tried importing the collision data from the original DOA2 into DOA2U? if it's the same format then all we need is to use some kind of emulator ripper for the mesh, then import it into blender then convert to .XPR and finally export with the textures. There are a few PS2/DC stages that were sadly missing in Ultimate these were:
  • The Spiral
  • The Blanca
  • The L's Castle
 
Last edited:

leidoa

Member
View attachment 30873
It would be awesome to actually create collisions for cutscene stages so we could make them fun to play. Some cutscenes like the Desert and Snowing Miyama actually are just reskins so the data is the same.

Have you tried importing the collision data from the original DOA2 into DOA2U? if it's the same format then all we need is to use some kind of emulator ripper for the mesh, then import it into blender then convert to .XPR and finally export with the textures. There are a few PS2/DC stages that were sadly missing in Ultimate these were:
  • The Spiral
  • The Blanca
  • The L's Castle
unfortunately i don't know what kind of format doa2 original has, never tried messing with its files before
would love to have The Blanca back in doa2u , can we even extract files from the ps2 version ???

thought of remaking the Blanca before by just using
the test stage ( stage_wal.xpr ) as a base since it has a similar
hexagon shape , looked online for a similar mesh and texture cuz i still know nothing about hacking into the ps2 files but i didn't find any
 
Last edited:

dee4doa

Member
My custom stages load but every time I use one with textures the game just doesn't render the objects (the stage is just a black void) I wonder if it's something that blender is doing when exporting?
 

dee4doa

Member
So strange, the game renders the 3D objects when there is no texture files yet once I apply an image to it then it becomes black. What's strange is that GreedXplorer loads the textured version fine it's just ingame.

I can change the diffuse blank colours though as shown below:
1587929528312.png
 

CoYoTe

Active Member
i used to get the same problem, to export the xpr with textures just run blender as administrator it works ;):thumbs up:

i used blender to make custom costume parts
took me ages to do it

View attachment 30859

its still not finished though, i need to add gloss
to the custom parts but i still don't know how
:(
How did you export that?
I tried to export this custom model and when i converted it for Doa online the game crashes,so i used greedxplorer and this happens when i select the "Character" section:
IMG_20200826_171423.png

This happens when i select The "MDL" Section:
IMG_20200826_171432.png
 

CoYoTe

Active Member
I found other stages but they have A lot of bugs
To do this You must Overwrite "stage_WAL.emp" file that is located in this path:
DOA ONLINE/data/ingame/dat/stage/stage_WAL
in lobby talk to the girl with a gift icon on her head and select the "3 pancratium" stage, and run a fighting mode to see your 3d scene
IMG_20200827_181644.png

IMG_20200827_181634.png
 
Last edited:

leidoa

Member
How did you export that?
I tried to export this custom model and when i converted it for Doa online the game crashes,so i used greedxplorer and this happens when i select the "Character" section:View attachment 31495
This happens when i select The "MDL" Section:View attachment 31496
Actually swapping moving parts is very difficult so no joints, head or breast....
Someone actually swapped Christie's head with Kasumi's body long time ago but it was never explained :/
 

CoYoTe

Active Member
Actually swapping moving parts is very difficult so no joints, head or breast....
Someone actually swapped Christie's head with Kasumi's body long time ago but it was never explained :/
Maybe the reason that The christie/kasumi hybrid mod worked it's beacuse they edited the cat file
 
ALL DOA6 DOA5 DOA4 DOA3 DOA2U DOAD
Top