[DONE] Grimrock Model Tookit

Talk about creating Grimrock 1 levels and mods here. Warning: forum contains spoilers!
tomimt
Posts: 3
Joined: Sun Oct 07, 2012 12:19 pm

Re: [WIP] Grimrock Model Tookit

Post by tomimt »

Hi

I've got this weird issue going on with a model I did in Blender. On the smaller editor view the model looks okay, but if I switch to the fullscreen mode the model tears apart. Any ideas what might be causing this?

Here's a link to a pic
User avatar
Phitt
Posts: 442
Joined: Tue Aug 14, 2012 9:43 am

Re: [WIP] Grimrock Model Tookit

Post by Phitt »

tomimt wrote:Hi

I've got this weird issue going on with a model I did in Blender. On the smaller editor view the model looks okay, but if I switch to the fullscreen mode the model tears apart. Any ideas what might be causing this?

Here's a link to a pic
Most likely the same problem described by me and Leki. There seems to be a problem when exporting to model format, you'll have to wait until John finds out what causes it and how to fix it.
User avatar
JohnWordsworth
Posts: 1397
Joined: Fri Sep 14, 2012 4:19 pm
Location: Devon, United Kingdom
Contact:

Re: [WIP] Grimrock Model Tookit

Post by JohnWordsworth »

*Does a little happy dance* I think I've found it :). Fix incoming!
My Grimrock Projects Page with links to the Grimrock Model Toolkit, GrimFBX, Atlas Toolkit, QuickBar, NoteBook and the Oriental Weapons Pack.
User avatar
Komag
Posts: 3658
Joined: Sat Jul 28, 2012 4:55 pm
Location: Boston, USA

Re: [WIP] Grimrock Model Tookit

Post by Komag »

that sounds good!
Finished Dungeons - complete mods to play
User avatar
JohnWordsworth
Posts: 1397
Joined: Fri Sep 14, 2012 4:19 pm
Location: Devon, United Kingdom
Contact:

Re: [WIP] Grimrock Model Tookit

Post by JohnWordsworth »

Ok, there's some good news and some bad news I'm afraid. First of all - I'm pretty confident that I've fixed the .model save issues. After a couple of hours with a hex-editor, I realised that I had mis-read the .model format specification, a MeshSegment has an 'FirstIndex' and a 'Count', but that Count isn't the number of indices, but the number of triangles.

The bad news is that any/all models that have been imported using an earlier version will have this problem. Any re-skinned models should be fine (as I just use the values from the original file), but all meshes imported using GMT to date will have this problem.

Please check and feedback - there is always the possibility that there are other problems in saving .model files, but I've imported @Phitt's OBJ files, and while there is still a problem with the normals - the dungeon always renders fine now (no garbage triangles being rendered) :). I've deleted all previous versions of the GMT from my site and upgraded the version number to reflect that this version should be used from now onwards.

Oh, I've also added group export to OBJ files, so mesh entities with multiple segments should now export as multiple 'OBJ Groups' so that they can be edited separately in Blender. This also means that when you round-trip a model, they retain their material name.

GMT Home Page Direct Download
My Grimrock Projects Page with links to the Grimrock Model Toolkit, GrimFBX, Atlas Toolkit, QuickBar, NoteBook and the Oriental Weapons Pack.
tomimt
Posts: 3
Joined: Sun Oct 07, 2012 12:19 pm

Re: [WIP] Grimrock Model Tookit

Post by tomimt »

I gave it a quick spin and it seems to work correctly now.
User avatar
Isaac
Posts: 3185
Joined: Fri Mar 02, 2012 10:02 pm

Re: [WIP] Grimrock Model Tookit

Post by Isaac »

This is great news. 8-)
User avatar
Leki
Posts: 550
Joined: Wed Sep 12, 2012 3:49 pm

Re: [WIP] Grimrock Model Tookit

Post by Leki »

John,
bad news - I opened some models and got 3 results:
SpoilerShow
Image
I'm the Gate I'm the Key.
Dawn of Lore
User avatar
Wolfrug
Posts: 55
Joined: Wed Oct 03, 2012 6:56 pm

Re: [WIP] Grimrock Model Tookit

Post by Wolfrug »

Hum. I just tried this today to see if I could manage to resize the sack_full model in Blender and turn it into my very own coin_pouch. So far so good:
SpoilerShow
Image
Except that's exactly what it looks like in-game too :(

I've got the item defined:

Code: Select all

defineObject{
	name = "coin_pouch",
	class = "Item",
	uiName = "Coin Pouch",
	model = "mod_assets/models/coinsack.fbx",
	gfxIndex = 81,
	weight = 0.1,
	container = false,
	stackable = true,
}
and custom materials for it (just using the original sack textures):

Code: Select all

defineMaterial{
	name = "coin_pouch",
	diffuseMap = "mod_assets/textures/sack_full_dif.tga",
	specularMap = "assets/textures/common/black.tga",
	doubleSided = false,
	lighting = true,
	alphaTest = false,
	blendMode = "Opaque",
	textureAddressMode = "Wrap",
	glossiness = 20,
	depthBias = 0,
}
I know it's not the material entry that's wrong - I tried changing the "name" field to "flask" and got myself a nicely leather-coloured flask model. The item.lua entry is also correct since, well, it shows up in-game:
SpoilerShow
Image
Not sure what exactly I'm doing wrong here. :-/ I'm a bit of a noob when it comes to 3D-modelling, so I suppose I might have screwed something up somewhere, but...well. I don't know?
Try my Mordor: Depths of Dejenol LoG-ification. Feedback much appreciated!
User avatar
JohnWordsworth
Posts: 1397
Joined: Fri Sep 14, 2012 4:19 pm
Location: Devon, United Kingdom
Contact:

Re: [WIP] Grimrock Model Tookit

Post by JohnWordsworth »

Oh bugger, there appears to be a problem with exporting meshes that have multiple mesh segments. Imports should still be ok from Blender models, but I think the OBJ outputs for meshes with >1 segments is not quite right. Build this morning was a bit of a rush - got a Pathfinder RPG game to run in 10 minutes and had to write the story! Will upload a fix after the game this evening!
My Grimrock Projects Page with links to the Grimrock Model Toolkit, GrimFBX, Atlas Toolkit, QuickBar, NoteBook and the Oriental Weapons Pack.
Post Reply