Grim Fandango Deluxe - Original Thread [Locked]

Discussions regarding the development of the mod "Grim Fandango Deluxe"

Moderator: ScummVM Team

Locked
User avatar
giucam
Posts: 139
Joined: Mon Mar 21, 2011 9:20 am

Post by giucam »

ultraneonoirantihero wrote:So the 3D models have the reference to the color pallete which is used by the model's texture? AKA: The 3DO file uses MAT file and has a reference to the CMP file? Then the 3do file has all the necessary data?
No, a 3do has a list of its materials only. The colormap is set externally by the costume.

Example: mcc_thunder.cos (Thunderboy Manny)

Code: Select all

#  ID	TagID  Hash	ParentID	Name
...
	62	5		0		42			mth_head1.3do
	63	5		0		42			mth_head2.3do
	64	5		0		42			mth_head3.3do
...
	78	3		0		64			thunder.cmp
	79	3		1		63			thunder.cmp
	80	3		2		62			thunder.cmp
Here you see that the costume sets the cmap thunder.cmp on the head models, since the ParentID of the cmaps are the IDs of the models.
User avatar
ultraneonoirantihero
Posts: 106
Joined: Mon Sep 05, 2011 5:13 pm

Post by ultraneonoirantihero »

I didn't know the structure of files is like that.

The "costume" contains many 3Dmodels that when combined form the actual character, and the COS file has the colormap for the whole character. Each 3dmodel (character's individual element) has the info about it's own texture/material, but those textures go up one level in hierarchy and fetch the pallete?

+COS
|
|---3DO
|---|
|---|-MAT
|
|---3DO
|---|
|---|-MAT
|
|---CMP
Last edited by carrrramba on Thu Oct 13, 2011 3:16 pm, edited 1 time in total.
User avatar
giucam
Posts: 139
Joined: Mon Mar 21, 2011 9:20 am

Post by giucam »

Yes, that's how it works, more or less.
Actually it's more complex, since an actor usually has more than one costume, and not all .cos files set the colormap. (All the Costume objects do so, anyway).
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Huh.

If LucasArts don't give this guy any trouble, I don't think we've got anything to worry about with regards to publicly sharing artwork assets from GF.

http://mixnmojo.com/news/Hedonistic-Aus ... ackgrounds

He's extracted the backgrounds from almost every single LucasArts SCUMM game.
User avatar
somaen
ScummVM Developer
Posts: 376
Joined: Thu Apr 21, 2011 7:31 pm
Location: Trondheim, NO

Post by somaen »

As long as you don't mention or touch a certain franchise involving glowing sabres and spaceflight, LucasArts doesn't seem to care at all these days.
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Well that's a bit of good news!

Can I ask something regarding the 3D: Excuse my igorance, but is it possible to get a version of Manny that can be opened in some 3D software so it that actually looks like Manny?

At the moment all we get is a bundle of shapes all piled on top of each other. I don't fully understand 3D and the different file formats, so I'm not sure if it's even technically possible?

I personally found it very difficult to play around with Manny when I couldn't tell what shape referred to what :-/ I'm not sure if that's my lack of experience, or if everyone who wants to help will have the same problem?

Could anyone explain?

Thanks!
Last edited by nuphonic on Sun Oct 16, 2011 2:48 pm, edited 1 time in total.
User avatar
ultraneonoirantihero
Posts: 106
Joined: Mon Sep 05, 2011 5:13 pm

Post by ultraneonoirantihero »

Then how were these 3D models made? Didn't CPLhenshaw re-made them in Blender?

http://www.youtube.com/watch?v=iByj4NIjf8E
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

ultraneonoirantihero wrote:Then how were these 3D models made? Didn't CPLhenshaw re-made them in Blender?

http://www.youtube.com/watch?v=iByj4NIjf8E
They're from CPL's own model viewer he made. Good point: He managed to get the models to look like they do in game, so it is possible using just the 3DO files. Good news.
cplhenshaw
Posts: 54
Joined: Wed Aug 10, 2011 9:17 pm

Post by cplhenshaw »

Back on page 9 I posted what I had so far of my importer/exporter. It can convert the .3do files to .obj and these can be opened by various 3d modelling programs. I use Blender (because it's free) and if you convert the appropriate textures to a suitable format Blender will search for them when you import. The resulting model has all the pieces separated correctly and you can see all the textures etc. The only thing it still doesn't do is the rotation of the various pieces which occur in some of the .3do files.

You can then edit the model / texture maps and export the edited .obj back to .3do file and put it back in the game. It all seems to work O.K except that the lighting is not correct on the new model, so either the normals or some of the face properties that I was guessing are wrong. Anyway I've been a bit busy so I haven't fixed that up since I posted it.

The video's on my youtube channel were done by a Python script I had written to rebuild the models inside Blender, except for the last video which was a demonstration of the model viewer. That script was pretty experimental and involved varying stages of automation.
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Agh. I'd forgotten about that. How perfectly crap of me. I'll make more notes of where we're up to in the future. It's tricky trying to push forward three different "branches" at the same time, but I've got a lot more free time at the moment, so hopefully I can keep on top of it.
nathanel.mori
Posts: 47
Joined: Sun Aug 01, 2010 9:48 am

Post by nathanel.mori »

Hey, people.

I haven't the slightest idea what you guys are talking about, but I just want to express my admiration and adoration towards all of you, for taking part in such a noble effort to revive what is probably the prettiest gem in computer gaming.

Please don't let us lose such a beauty! Future generations will never forgive us if we do...
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

cplhenshaw wrote:I've updated my programs to handle textures now.
http://www.mediafire.com/download.php?lo1cpzlzrn17tw4

I don't know what modelling programs people will want to use but I've been using Blender 3d for trying this out (I don't have anything else) and so there may be a different set of quirks and whatnot for getting it working in other programs.

Basic usage:

'3doobj mannysuit.3do manny.obj .png' will output the file manny.obj and manny.mtl. manny.mtl will have simple materials which will specify the textures to use, so bone.mat becomes bone.png or whatever image format you specify on the command line. (if you don't specify one it will just use .png)

Place these two in a folder along with all the textures you want the modelling program to use.

Then (for Blender) when you import the .obj it will search the folder for the textures specified in the .mtl and apply them to the model appropriately. You can then change the model and adjust the texture mapping etc, and export again as a .obj

'obj3do mannysuit.3do mannyNEW.obj m.3do'
This will go through the .obj file and update the appropriate parts of the original .3do file and write out the result as m.3do or whatever the third argument to the program is. This can then be placed in the .lab file and used in ResidualVM.


Notes: When you export out of your modelling program the resulting .mtl is not needed for the reverse trip. The program assumes that the material names used in the .obj file will have (for example) m_bone.mat somewhere in it.

These programs do not seem to handle the normals correctly or maybe some of the face options are being set incorrectly. Even converting to .obj then straight back, the result in game is strange lighting on the model so I will need to have a play around to see what is wrong there and fix it.

Also these programs still do not do any of the rotations that are present in later model files.

So try it out and let me know how it works. Hopefully it does :wink:
This seems to work perfectly. I'm still getting to grips with getting the textures visible in Maya, though. Not sure if they're needed for someone wanting to help out improving the 3D, though.
cplhenshaw
Posts: 54
Joined: Wed Aug 10, 2011 9:17 pm

Post by cplhenshaw »

If someone was to alter the 3d models, they would almost certainly need to adjust the UV mapping, so that the textures aligned correctly with the updated models.

A quick google suggests that lots of people have had trouble importing .obj with textures into Maya, so I'm not sure if there's a workaround for that.
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

cplhenshaw wrote:If someone was to alter the 3d models, they would almost certainly need to adjust the UV mapping, so that the textures aligned correctly with the updated models.

A quick google suggests that lots of people have had trouble importing .obj with textures into Maya, so I'm not sure if there's a workaround for that.
Maybe Blender is just an easier option. Do you have a version of the mannysuit OBJ with the textures ready to go? Given how LucasArts don't apparently care about people sharing their assets of old games, I think we should be OK while we're developing things (although not for distributing, probably).
cplhenshaw
Posts: 54
Joined: Wed Aug 10, 2011 9:17 pm

Post by cplhenshaw »

This imports with textures fine for me using Blender3d.

http://www.mediafire.com/download.php?i5vkh7jd4axpv08

When you import there's a whole bunch of options, most importantly is to make sure that you select the "image search" option. Also if you want the different pieces of the model to be separate objects you should have separate by objects selected.
Locked