The VG Resource
WayForward .GR2 Model Format - Printable Version

+- The VG Resource (https://www.vg-resource.com)
+-- Forum: The Resources (https://www.vg-resource.com/forum-109.html)
+--- Forum: The Models Resource (https://www.vg-resource.com/forum-111.html)
+---- Forum: Ripping Help (https://www.vg-resource.com/forum-115.html)
+---- Thread: WayForward .GR2 Model Format (/thread-27178.html)



WayForward .GR2 Model Format - Daxar - 05-25-2015

I recently purchased Double Dragon Neon on Steam, mostly because it was a cheap WayForward game. The 3D models in the game are stored in .gr2 files, like other games of theirs (Such as DuckTales Remastered).

I successfully extracted the 3D model from the file bomb.gr2, with the following simple (*cough cough*) steps:
1. Extract .gr2 with a program I found called grnreader98, which outputs a Source Engine-style .smd model
2. Edit the .smd by hand to fix issues with the header
3. Open the .gr2 with another program Granny Viewer, which only views (doesn't extract) the texture
4. Use another program GLXtractor to rip the texture data from Granny Viewer's OpenGL context (This can also output an .obj with the mesh data, but without UV coordinates and rotated strangely, so I ignore this)
5. Import the .smd into Blender with an import script I found online
6. Remove extraneous vertices from the mesh (looks like collision data and the like)
7. Translate the UV coordinates upwards, as they're incorrect
8. Flip the normals, as they're incorrect
9. Scale the model to a more reasonable size
10. Import the model texture
11. Export .obj, unchecking export normals
12. Manually edit the .mtl to have relative, rather than absolute, file path to UV texture

The results are pretty good-looking (Blender render):
[Image: bomb.png]

My question is if much of anything is known about the .gr2 file format, and if there's an easier way to do this? From my online searches, it looked like the people who knew the most about the format didn't share source code or didn't document it, but it looked like a lot of different games, like Civ 5, use it.

TL;DR I'd like to rip this (Other game formats are .tex and .anb, which I have experience with), but repeating these steps over and over for all 397 of the game's .gr2 files sounds rather daunting.

EDIT: Upon further digging, seems that .gr2 is a Granny Engine - specific format, which is a proprietary format by RAD Game Tools. Everybody else just used a function in a Granny .dll to extract the files. So this may be the best that can be done... kinda sucks.