You must be logged in to post messages.
Please login or register

Modding Discussions
Moderated by Alexastor, MosheLevi, Mister SCP

Hop to:    
loginhomeregisterhelprules
Bottom
Topic Subject: Non-useful GR2->MS converter
posted 01-03-06 12:37 PM EDT (US)   
Due to prompting by Argalius:

The non-useful converter is downloadable here (240KB), containing grnreader.exe, which kind of reads a limited selection of GR2 files and outputs some MAXScript to create the mesh in 3ds max / gmax (though the latter is untested). (It'd be relatively straightforward for somebody to modify the output code to generate a different file format, if anybody wants to try.)

Usage instructions are somewhat like:
1) Find a suitable .gr2 file - animated units seem to never work, so plain buildings (I've used HC_cathedral.gr2 when testing) are best.
2) Copy it into a folder containing grnreader.exe and granny2.dll (the zip includes the DLL from the demo).
3) Run "grnreader.exe HC_cathedral.gr2" (or whatever the file is called) from the command line. (You could probably instead drag-and-drop the .gr2 file onto the .exe, but then you wouldn't see the error messages, and I've never tested it that way.)
4) In 3ds max / gmax, use MAXScript -> Run Script, then select the output.ms which should have been generated in the folder containing the other files.

Optional 5) If you want textures, you hopefully just need to set up the materials correctly - convert the model's textures into .tga, then put the standard texture into Diffuse (with Alpha Source set to None), and copy it into Opacity (with Mono Output set to Alpha). For specularity (which is even more optional), put the bump+spec texture into specular (with Mono set to Alpha again). For bump maps, new versions of 3ds max might be able to handle that natively, though I don't know how; otherwise, try the Displacement Map Creator to convert the bump+spec texture into a 'displacement'/'bump' (as opposed to 'normal') map, and then put that into max's Bump slot (and probably set Amount=100).

The result of all that should be like this.


The zip also includes source code (plus code generators) and VS2005b2 project files. The code is not meant to be any good. Consider it all public domain, and do whatever you want with it. (I haven't touched it for the past two months, and am unlikely to do anything with it in the future.)

Replies:
posted 01-03-06 02:23 PM EDT (US)     1 / 7  
I know it's unsupported and all, but I have a question anyway.

What do you mean with this:

Quote:

3) Run "grnreader.exe HC_cathedral.gr2" (or whatever the file is called) from the command line.


Because I tried to do it through Start\Run and then the whole name and with HC_cathedral.gr2 behind, and then it says that it can't be found.

When I drag and drop it I get an error similar like this:
Log ... granny_file_info.cpp... File has run-time type tag ... , which doesn't match this version of Granny. Automatic conversion will be attempted.

So I replace the old granny2.dll with the new one, no effect.

When I just try to open grnreader.exe I get some message, but I can't read it because it instantly closes again. I also had that with the drag and drop but I managed to take a screenshot of it so I could read it. (I think that is because of Windows XP, not sure though.

EDIT: I managed to take a screenshot of the second one too and then it says to run "C:\...\grnreader.exe HC_Cathedral.gr2" When try to do that through Start\Run, Windows says it can't be found...

Oh and yes, I did put everything in the same map as you said.


|| argalius.elpea.net
|| Cherub at AoE3H
|| In honor of FlipBizcut
|| Mod: The Age of Crusades

[This message has been edited by Argalius (edited 01-03-2006 @ 02:29 PM).]

posted 01-03-06 02:36 PM EDT (US)     2 / 7  

Quote:

When I drag and drop it I get an error similar like this:
Log ... granny_file_info.cpp... File has run-time type tag ... , which doesn't match this version of Granny. Automatic conversion will be attempted.


That's not actually an error - it's just an internal Granny message, saying it's going to automatically convert the data into the latest version. It should carry on correctly after that.

It appears that the program does work if you drag-and-drop files onto it, except the output goes into "C:\Documents and Settings\You\output.ms", which is not the most convenient place. But once you know it's there, that might be a reasonable way to use it.

Otherwise:

Quote:

I tried to do it through Start\Run


You have to do it from the proper command-line shell, like Start...Run...'cmd' then 'cd "c:\wherever\the\files\are"' then 'grnreader whatever.gr2'. (Its input/output are done from the current directory, which you have to use the 'cd' command to set.)

Quote:

screenshot


It may be easier to use the Pause key (and Enter to unpause). It's very annoying that Windows no longer has an easy "don't close window when the program terminates" option
posted 01-03-06 03:23 PM EDT (US)     3 / 7  

Quote:

The non-useful converter is downloadable here...

LOL, even your non-useful tools are fascinating Ykkrosh.

posted 01-03-06 04:20 PM EDT (US)     4 / 7  
Dare I ask why they're called 'granny' models?

▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲
βỉğҒặŧŽ
₪₪₪₪₪₪₪₪₪₪₪₪₪₪₪
Proud Member of Liquid Fire Studios
▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼
posted 01-03-06 04:48 PM EDT (US)     5 / 7  
Because they're part of the Granny 3D system . As for why that's called Granny, I have no idea, and can't find any explanations - given that they (RAD) have other libraries called Smacker and Bink, I assume it has no deep significance . (It also gives them a good excuse to use a granny in their demonstrations.)
posted 01-03-06 05:53 PM EDT (US)     6 / 7  
...That granny is creepy. I think I'm gonna have nightmares of her sitting in a rocking chair petting this.

Yay, Fluffy! Check the cheat units of AoE3 for more!


▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲
βỉğҒặŧŽ
₪₪₪₪₪₪₪₪₪₪₪₪₪₪₪
Proud Member of Liquid Fire Studios
▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼▲▼
posted 01-04-06 05:41 AM EDT (US)     7 / 7  
You were right Ykkrosh. Anyway, it's all working now. Thanks.

|| argalius.elpea.net
|| Cherub at AoE3H
|| In honor of FlipBizcut
|| Mod: The Age of Crusades
Age of Empires III Heaven » Forums » Modding Discussions » Non-useful GR2->MS converter
Top
You must be logged in to post messages.
Please login or register
Hop to:    
Age of Empires III Heaven | HeavenGames