Grim Fandango Deluxe - Original Thread [Locked]

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

Moderator: ScummVM Team

Locked
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Great stuff!

I can do the textures again.
User avatar
Blacksad
Posts: 30
Joined: Sun Feb 12, 2012 11:02 pm

Post by Blacksad »

ok, i tried some things. cleaning up, rotating, uv-remapping, reapplying materials, exporting with the last two blender versions. nothing worked :(

I have made a completely clean model without any additional data. Just the meshes + materials + uv-mappins.

With this file i get new error messages

Code: Select all

Texture vertice 0 was never scaled in scaleTexVerts()
Texture vertice 1 was never scaled in scaleTexVerts()
...
I don't know what i could do more...
Glottis_n2 :: .obj :: .blend
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Well that's frustrating. Hmm! :(
cplhenshaw
Posts: 54
Joined: Wed Aug 10, 2011 9:17 pm

Post by cplhenshaw »

I took the original version of glottis and replaced it piece by piece with your new version, compiling each time until it stopped working, which is when the chest piece was replaced. I then tried all pieces except the chest piece and the model compiled fine.

Presumably when this piece is read in it throws the program off kilter somehow, which is why all the error messages start showing up. I'm pretty sure there's nothing wrong with the piece itself, it just happens to catch some bug in my code which none of the pieces up to now have. So I still have no idea why this is happening, but I'll do a bit more investigating and see what turns up.
User avatar
Blacksad
Posts: 30
Joined: Sun Feb 12, 2012 11:02 pm

Post by Blacksad »

Wow. Sounds like a lot of work. The models are made of 40 different meshes.

Can you explain me, what the error massage means? Vertices are single points of the 3d-mesh, but i don't know what a texture vertice is. Maybe the corresponding position of a "3d-vertice" on the texture. But one vertice can't be scaled, it has no dimensions. Though it sounds like it could be an issue with the uv-mapping.


edit: I have the same problem with the latest manny version btw. After the one which johnnywalker compiled, i did some tweakings and from this point the compiling didn't work anymore.
cplhenshaw
Posts: 54
Joined: Wed Aug 10, 2011 9:17 pm

Post by cplhenshaw »

In the way that a regular vertex is a position in 3d space, a texture vertex is a 2d position on a texture. In Blender when you do UV mapping, the points you move about on the image are the texture vertices.

By scaling the texture vertices I mean scaling each coordinate from the range 0 - 256 (pixels) to 0 - 1 (generic) and back again. The problem wasn't here, but was just a symptom of the program going off track.

The bug was pretty typical of a less than careful C programmer.
When reading the material names in the .obj file, I was reading into a 32 char array, and :oops: failed to do any bounds checking:cry:. So when it got to a nice long material name like "gl_j_chest.mat_gl_j_chest.bmp.001" any excess bytes were just trampling through other data, namely a counter which was keeping track of how many texture vertices had been encountered. This then fouled up some other stuff and stopped the program from working correctly.

Anyway I fixed it, and uploaded new versions here: 3doStuff.zip

Edit: LAB with new glottis.3do Data006.lab
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

Great news! I'll get to work on hires textures for Glottis!
User avatar
Blacksad
Posts: 30
Joined: Sun Feb 12, 2012 11:02 pm

Post by Blacksad »

cplhenshaw wrote:In the way that a regular vertex is a position in 3d space, a texture vertex is a 2d position on a texture. In Blender when you do UV mapping, the points you move about on the image are the texture vertices.

By scaling the texture vertices I mean scaling each coordinate from the range 0 - 256 (pixels) to 0 - 1 (generic) and back again. The problem wasn't here, but was just a symptom of the program going off track
Ah, thanx for the advice. I thought it might be something like that, but i wasn't sure about it.

I'm glad, that you have solved the problem. I was afraid that i did something wrong and couldn't fix it, because of lack of experience. ^^


Edit:
Improved version glottis.3do :: datausr.lab


Edit:
New problem incoming.
I have remodeled the extra head-meshes for manny. (manny_head2 + manny_head3). Mesh-swapping works fine but the head2-model has no textures mapped on it, although the .blend file is textured.

When i import the original head2 model into blender, the textures are already missing, though the materials are applied correctly.

Here are mannys latest .obj's
mannysuit.obj :: manny_head2.obj :: manny_head3.obj :: datausr.lab
User avatar
Morden
Posts: 157
Joined: Mon Nov 03, 2008 10:15 am
Contact:

Post by Morden »

It's great to see that people are still working on Grim Fandango, and Residual! I woke up yesterday and thought to myself "It's been a really long time since I checked up on Residual" and wouldn't you know it, something is happening, but that's neither here nor there.

What i wanted to ask is this: How do I get Manny's updated model to work? Instructions are simple to follow. I just place the new *.lab file in the game directory, run the game and it should work. It doesn't. From what I understand, the new face texture is single frame, so the face shouldn't be animated. It is, which makes me think the model wasn't loaded. I'm assuming that both the model and textures are in the same *.lab.

Any ideas on how to solve this? I'm using the 0.1.0-preb32fcfa version [Aprl 16th].

Edit - Ok, solved. I just noticed you had to tick the box to allow the use of modifications. The model did load, however, once I got out from the office and got to the poisoning, Manny's face disappeared [click to enlarge]!

Image
iceberg
Posts: 4
Joined: Fri Apr 06, 2012 10:33 pm

Post by iceberg »

cplhenshaw wrote: Edit: LAB with new glottis.3do Data006.lab
If I use this latest version of Data006.lab for Glottis, will I lose the spruced-up Manuel?

Or is the enhanced Manny character found in DataUSR.lab?
yp
Posts: 3
Joined: Sat Apr 21, 2012 1:10 pm

Conversion from 3do to obj

Post by yp »

cplhenshaw wrote:In the way that a regular vertex is a position in 3d space, a texture vertex is a 2d position on a texture. In Blender when you do UV mapping, the points you move about on the image are the texture vertices.

By scaling the texture vertices I mean scaling each coordinate from the range 0 - 256 (pixels) to 0 - 1 (generic) and back again. The problem wasn't here, but was just a symptom of the program going off track.

The bug was pretty typical of a less than careful C programmer.
When reading the material names in the .obj file, I was reading into a 32 char array, and :oops: failed to do any bounds checking:cry:. So when it got to a nice long material name like "gl_j_chest.mat_gl_j_chest.bmp.001" any excess bytes were just trampling through other data, namely a counter which was keeping track of how many texture vertices had been encountered. This then fouled up some other stuff and stopped the program from working correctly.

Anyway I fixed it, and uploaded new versions here: 3doStuff.zip

Edit: LAB with new glottis.3do Data006.lab
Hi all,

I'm not a 3d-expert, but I've tried converting some models using cplhenshaw's tool (3doobj), just to see what I can do to help.
The resulting obj seems wrong: when opened (I used Blender), the different meshes are not placed correctly, and the materials are not linked right.
A 3do file which reproduces this problem is: gatekeeper.3do.

Any help would be appreciated :)
User avatar
Blacksad
Posts: 30
Joined: Sun Feb 12, 2012 11:02 pm

Post by Blacksad »

Hello and welcome :D We would be glad if you can help out with some modeling.

Which model did you convert? I had some issues with meshe's model. The fingers were totally stewed up. Though, after re importing into the game, all parts were positioned correctly.
edit: Oops, missed the last line. You tried gatekeeper^^

When you import the .obj into blender, you need to place the .mtl and the texture images which belong to the model into the same folder. After importing, the rotation of the model is not correct, but that can be easily fixed by rotating the whole thing.

edit:
Ok. I tried it with the gatekeeper too. The whole model is rotated by 90 degree to the left and the head is pointing to the right.
Textures and materials are applied to the objects but uv-mapping does not exist. I had the same problem with the manny_head2 model.

Til tis problems are not solved, i recommend to trie another model.
Last edited by adiro69 on Sat Apr 21, 2012 8:19 pm, edited 2 times in total.
yp
Posts: 3
Joined: Sat Apr 21, 2012 1:10 pm

Post by yp »

Blacksad wrote:Hello and welcome :D We would be glad if you can help out with some modeling.
Thanks, I will be happy to help! :)
Blacksad wrote:Which model did you convert? I had some issues with meshe's model. The fingers were totally stewed up. Though, after re importing into the game, all parts were positioned correctly.
edit: Oops, missed the last line. You tried gatekeeper^^
Yep ;) The biggest problem is not the misplacement of the parts (I believe I can do that manually), it's the fact that no materials are linked, and trying to relink them manually did not work well, as it seems that the images I've extracted from the mat files (using mat16) are not at the right size.. Any ideas?
Blacksad wrote:When you import the .obj into blender, you need to place the .mtl and the texture images which belong to the model into the same folder.

Tried that, didn't work..
Blacksad wrote:After importing, the rotation of the model is not correct, but that can be easily fixed by rotating the whole thing.
I seems that each part has undergo a different rotation..I'm not much of an expert, but as I said, I believe I can fix this manually..
yp
Posts: 3
Joined: Sat Apr 21, 2012 1:10 pm

Post by yp »

Blacksad wrote:Hello and welcome :D We would be glad if you can help out with some modeling.

Which model did you convert? I had some issues with meshe's model. The fingers were totally stewed up. Though, after re importing into the game, all parts were positioned correctly.
edit: Oops, missed the last line. You tried gatekeeper^^

When you import the .obj into blender, you need to place the .mtl and the texture images which belong to the model into the same folder. After importing, the rotation of the model is not correct, but that can be easily fixed by rotating the whole thing.

edit:
Ok. I tried it with the gatekeeper too. The whole model is rotated by 90 degree to the left and the head is pointing to the right.
Textures and materials are applied to the objects but uv-mapping does not exist. I had the same problem with the manny_head2 model.

Til tis problems are not solved, i recommend to trie another model.
Ok, thanks!
User avatar
JohnnyWalker2001
Posts: 405
Joined: Mon Oct 16, 2006 1:27 pm
Location: London, UK

Post by JohnnyWalker2001 »

iceberg wrote:
cplhenshaw wrote: Edit: LAB with new glottis.3do Data006.lab
If I use this latest version of Data006.lab for Glottis, will I lose the spruced-up Manuel?

Or is the enhanced Manny character found in DataUSR.lab?
Enhanced Manny is in DataUSR.lab. In theory all modifications should go into that .lab, as that's what it was designed for. Anyway, you can just drop Data006.lab in and they won't clash.
Locked