chunk_pc


Yo, I've been looking at these .chunk_pc files past weekend and have reverse engineered some info out of them.

I have no clue on majority of the files' contents, but I got a Blender script that pulls positions of objects and creates vertices to visualize them. So this is NOT world mesh data.

Screenshot 2021-10-04 165800.png


I moved this fence 10 (metres?) along world x axis. Weirdly enough it culls if I look away from it's original position and not the new one.
20211003190831_1.jpg



I pulled this knowledge from my ass with a hex editor so something's probably inaccurate.
 
Last edited:
I found a second set of positions and stuff way further in the airport terminal chunk. Not sure what they are, but they follow the building's shape pretty well.
Screenshot 2021-10-05 162637.png

Edit: So I got 1944 positions from this section. Right after that there's a bunch of strings. Exactly 1944 of them until something stupid happens to the rest.

Code:
fenceParkB54
fenceParkB53
fenceParkB52
CharredHard01
ATInt_windshattpiece19
ATInt_VKP_Stairs02c
Object04
railinggggg
ATInt_Dec11
ATInt_dec_objectA01
etc...

I pulled the names and they match the props in game.
1633445244218.png
 
Last edited:
1633520756539.png

My script can now pull all meshes bundled at 0x0006FA90 in sr2_chunk028_terminal.chunk_pc.
I assume it will work on other files if you figure out the address and mesh count.

This is just geometry. I have no idea where UVs, materials and such are stored.

I think there's more stuff at 0x00146250. World mesh maybe? no it's not.
0x00147FD0 is definitely mesh data

Edit: I have no clue what this shape is supposed to be, but I found this from the second mesh area
The model format is different.
1633537941723.png
 
Last edited:
That's a great progress! Are all models centered on the grid or can they be placed where they should, but automatically? It reminds me of ripping Stilwater parts using Ninja Ripper. It was so painful to manually place the objects where they should be.
 
The first section contains props, like store shelves, handrails and benches. I don't how to place them in the world yet.

The second section has some weird stuff going on and I have only been able to import them one at a time using manual labor.
The 3 or 4 first models were all the same shape I posted previously, just rotated differently. Also centered. I hope the stuff further down this section is level geometry.

-Update: I still haven't figured the length of the header of each model. My logic works 24 times but the 25th model header is 4 bytes shorter for some reason.

This format is a bit more involved in other ways, too. Most models have one mesh, but some have 3 or even 8. They also contain a lot of other data that I'm skipping for now. The meshes I've gotten out so far look pretty abstract to me; I can't recognize any of them.

1633641861098.png
 
Last edited:
1633955539651.png

Update: The github repo now contains chunk_pc_import_mesh0.py, a mesh import script. Whether it actually works of crashes blender on a given chunk is a coin toss, though.

Edit: I looked at files that make it crash, and I think I understand how it works now.

Edit2: There we go
1633978246263.png

I'm actually amazed, it survived importing the WHOLE chunks1 directory at once.
1633978431266.png
 
Last edited:
Back
Top