Import gr2 skeleton

Nefliqus

Prince
Joined
Sep 16, 2010
Messages
400
Location
Poland
i looked into this breifly with max 2008, but I could not import a gr2.....could be either i did not pay enough attention to what i was doing...i am not experienced with 3dmax..

has anyone had success with this method????
 
Did you try doing it with a regular firaxis gr2 or did you use a modified one by using granny hacker?

If a program still exists that allows me to import and export this games gr2 files into and out of 3ds Max, where can I find it? The site listed is dead, my browser won't allow me to reach it. I Explorer will allow you to go there at your own risk, but altervista has destroyed all the links to downloads...

They are very particular about people using their proprietary software, it seems.

What is the current method for accessing and altering these files?

VR
Doc
 
right now we convert a gr2 using granny materialhackerV2. that creates a new gr2. then we view that gr2 in grannyviwere and then copy using 3D printscreen. that makes a 3dxml which we import into blender. That is just the mesh so you have to use (or create) a template that danrell made to rig a mesh to a skeleton. export as an fbx. then use the indiestone nexus buddy to convert that into a gr2.

Not as fun as it sounds ;)
 
There is a way to get civ 5 skeletons and meshes into blender by converting to smd then to milkshape 3d txt file. I have poor blender skills though (I only know the stuff that berine14 and Deliverator put in their tutorials) and I can not get the mesh to stick to the skeleton so when I export to *.FBX it crashes indiestone nexus buddy. This is how the exported .FBX looks like in milkshpae 3d. I would appreciate if any blender experts could give me a tip as to where I am going wrong.
 

Attachments

  • Gunship.png
    Gunship.png
    9.7 KB · Views: 479
Thanks Ekmek, attatched is the files for the gunship.

I had to first open the *.gr2 then save it in indiestone nexus buddy or it would fail the smd conversion. Extract the grnreader98 zip and navigate to it in command prompt and enter grnreader98.exe "<path to re-saved gr2 folder>*.gr2" -a -t which will create the *.smd file. Install trial of Milkshape 3d and import into Milkshape 3d (using the first one on list - Half-Life SMD) then export as a Milkshape 3D ASCII file. Import Milkshape 3D ASCII file into blender and you have the skeleton and mesh then re-attach texture. That's as far as I got but I could not get the mesh to stick to skeleton when I exported to *.FBX.
 

Attachments

  • GunshipTemplate.zip
    870.6 KB · Views: 332
I'm looking at your blender setup now, I don't see anything obvious but I'm going to keep looking. Ekmek is far more skilled at blender than I am, but I'll see what I can do. I would LOVE to have a gunship template to work from!!
 
hmmm. thats a nasty one. I'm getting the indie stone crash you got. I then tried exporting it as a nif. then re-importing and it crashed blender. I then edited the nif to put the texture into the skeleton node. I got it to import into blender that way but once I export to fbx it still crashed nexusbuddy. i'll keep digging.

On another front I added a later versionofblender (2.66, I usually use 2.49) because it has a smd import addon but when I tried to import your smd file it just came out as a stick.
 
I was able to load it up too, no problem but got the same indiestone crash. I'm going to try and import a new model, rig that one to the skeleton then delete the old one and see if that works.

EDIT: So removing the old model and adding a new one didn't work... I doubt this is something I'll be able to fix. Ekmek I'm hoping you can!!
 
EDIT: SUCCESS!!

Ok, I was able to make a gr2 from your blend file. But it requires the 2.66 version of blender which sucks because we can't import nifs with that one. 2.49 is the last stable version. And I'm not that familiar with 2.66 but so far I didn't see a milkshape import function. ug.

But here is what I did:
- Opened your blend file in 2.49.
- Clicked on the helo object and went to edt mode
- in edit mode I went to uv/image editor
- i clicked image->replace and selected the helo.dds I extracted a long time ago (in this case I copied into the working folder for your smd and other files).
- I then saved that blend file (helo2.blend for example)
- I then opened blender 2.66
- I opened the helo2.blend file
- I selected export to fbx (note it doesn't give a pop up for x,y,z like 2.49 does it just does it)
- then I did the nexusbuddy per the previous tutorial and it created a gr2 and I checked it in granny viewer.


I haven't tested in game so I'm not sure if its positioned correctly but we do have a g2 generated from an imported skeleton :woohoo:
 
Thanks for the milkshape discovery.

I'm sure snafu and I will get the milkshape trial now but to save the hassle lets post our blend files here so we don't duplicate efforts and waste our 30 days ;)

I tried getting an smd of a leader.gr2 and it always crashed. let me know if you have any luck.

EDIT: also I hate going through DOS these days so if you put the cmd line and specific file name in a txt file. resave and change the extension to a bat. you won't have to go through all the pain of writing the drive path in DOS. you just have to click the bat in the folder you are working in.

EDIT2: I got a leader to export just don't use the -a or -t. Now I need to see if I can milkshape it. the other problem is the materials which always failed. For now I'll stick to units.
 
When i got the install option i chqnged the folder to blender266 to install to. it didnt overwrite it. but you may want to make sure you uncheck the option to open blend files with it. im more comfortable with 249 so i left it like that. i also created a shortcut on the desktop for blender 249 and then a shortcut to blender266. If you dont have to dig for them. i havent tried milkshape ywt. i hope its easy.

I cant believe it take naterialhacker to make a gr2, grnreader to make a smd, milkshPe to make an ascii, blender 249 to make a blend, blender 266 to make an fbx, and finally nexusbuddy to make a gr2. :lol:
 
I tried what you said Ekmek and I got a working gr2 file as well. I just need to make up a unit art sql file and test it in the game. Will let know results when im done.

EDIT: Did not work in game. Unit is invisible but it may just be I missed something. I will go through tutorial again and try again.
 
Got it to export - one problem though. It doesn't ask for the name of the root during the export process- it exports the scene with a root called, 'Scene_Root' when we need it to say 'WORLD_center'. Not sure how to fix this though.

EDIT: Never mind, I figured out how to get it named correctly in Blender. I compared the two gr2 files (standard civ5 unit vs. the converted new one) in grannyviewer, and only noticed one wierd thing: The new one has 1 new bone (though I can't figure out which one). I tried it in game and the gunship is scattered all over the screen:

Spoiler :


EDIT 2: Attached is my version of the converted model.
 

Attachments

  • Gunship.zip
    459.9 KB · Views: 265
I don't know if this will help but in the helicoptergunship.fxsxml there is this line <Bone name="WORLD_center"/>
under bone usage. I am wondering if changing this to SCENE_root will work.

EDIT: This did nothing I will try your blend file.
 
Top Bottom