Page 1 of 3
Texture / retexturing problem.
Posted: Thu May 09, 2013 5:10 pm
by valley609
I have been messing with the Legend of Grimrock editor a lot in the last week or so.
I have done some basic scripting and some decent level design, and I decided to take it a step further.
So I installed the Asset pack and the Modelling kit and followed a retexturing tutorial I found on the wiki:
http://grimwiki.net/wiki/Model_Retexturing_Tutorial
I followed it every step of the way, I downloaded a DDS plugin for photoshop, I copied over all the texture files, made a new material, renamed the files, checked my export
options in photoshop.
But when I try to import the material through Tools -> Material Find / Replace,
this:
http://imgur.com/0TzVdV7
turns into this:
http://imgur.com/QMHWMyr
I have tried to use different models, different material settings, different import and export
settings in photoshop and double checked file names and paths, but I still have this problem
and I would appreciate any help. Thanks in advance.
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 6:24 pm
by remma
look like it's not loading the image, if you save it as is and try to load it in grimrock editor your will likely get an invalid path error (always a good test anyway as it'll give you a sanity check) , double check your entries in your materials.lua file I'm betting you've misstyped the path to your images.
Also don't forget they should end spider.tga instead of spider.dds
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 6:54 pm
by valley609
Thanks, I had missed a folder in the path to one of my texture files in materials.lua.
I also changed my texturefiles to .tga files instead of .dds, but now I have another problem.
When I open and apply the material in the modelling tool, I have the exact same problem as before.
And if I import it to my dungeon anyways and try to open the dungeon in the editor I get
this error:
http://imgur.com/Dx3GQhf
So the bottom line is, I did have an error in my materials.lua, I fixed it, and changed my .dds texture files
to .tga, none of this made any difference.
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 7:09 pm
by Sutekh
Don't worry about how the model looks in the tool kit, it turns white unless you create a preview of the material anyway. It's what it looks like in the editor/game that counts. As for the files, they should be exported as .dds but named .tga in the material definition.
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 7:16 pm
by valley609
Sutekh wrote:Don't worry about how the model looks in the tool kit, it turns white unless you create a preview of the material anyway. It's what it looks like in the editor/game that counts. As for the files, they should be exported as .dds but named .tga in the material definition.
Okay, I think I understand what you mean. I did what you say, kept my texture files as dds files and my materials.lua is set to look for tga files.
But now I get a another error when trying to open my dungeon in the editor:
http://imgur.com/OSyvT9l
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 7:22 pm
by JohnWordsworth
It's pretty confusing with the different extension. To clarify, you should have the file...
mod_assets/textures/monsters/spider1_dif.dds (a dds file with the dds extension).
In your materials.lua file, you should have a material definition starting with...
Code: Select all
defineMaterial{
name = "my_spider",
diffuseMap = "mod_assets/textures/monsters/spider1_dif.tga",
...
}
So, the diffuseMap parameter points to a .tga file, but the game actually expects a .dds file with the .dds extension.
You can get the Grimrock Model Toolkit to preview materials from your mod too if you also set the 'Current Dungeon Directory' in the preferences. I would get it to work in the game first though, and then go back and get it to work in the GMT so that you can see a preview of your textures in the GMT. Note that the GMT only shows the diffuse texture and doesn't do any fancy lighting / bump mapping.
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 7:34 pm
by valley609
JohnWordsworth wrote:It's pretty confusing with the different extension. To clarify, you should have the file...
mod_assets/textures/monsters/spider1_dif.dds (a dds file with the dds extension).
So, the diffuseMap parameter points to a .tga file, but the game actually expects a .dds file with the .dds extension.
Thanks for clarifying, I had some mixed answers from some other friends that also work with this.
But I did exactly that, and now I have this error:
http://imgur.com/OSyvT9l
I am starting to suspect I messed something up when I edited the texture in photoshop because
the paths are set up correctly and it still cant read the "spider1_dif.dds" file.
Is there something I cant do while editing the texture in photoshop? Currently all I have done is made a Hue / Saturation layer, edited, and then merged the two layers.
Is it possible to export it as a dds without flattening the image? Or should I try to export it with alpha channels to?
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 8:40 pm
by valley609
Okay, I have tried to export the texture file from photoshop in every way I can think off and I'm still having problems.
I still get the "File not Found" error:
http://imgur.com/OSyvT9l
and I have NO idea what I can do, or what is even wrong.
It does not simply wanna read my custom texture, any and all help would be greatly appreciated.
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 9:46 pm
by remma
Ok so a little baffled now, I've tried to replicate the error in two ways, firstly by changing the name of the image in my script file and secondly by just moving an image out of a folder.
Got the same error in both cases (barring a slightly changed filename)
http://imgur.com/NXaaQYY
The one thing I do notice is that your error is looking for a *.tga file whereas mine is looking for a *.dds - not sure what that means though heh.
Can you paste a copy of the entry from your materials.lua perhaps?
Oh and have you re-applied the texture and re-saved the model in GMT after updating your paths?
Re: Texture / retexturing problem.
Posted: Thu May 09, 2013 9:58 pm
by Conchron
valley609 wrote:
I still get the "File not Found" error:
http://imgur.com/OSyvT9l
and I have NO idea what I can do, or what is even wrong.
Follow the path. Simply open the folders for your dungeon and follow the path. Go to mod_assets, then textures, then monsters and find the file named spider1_dif. Check how you've spelled the folders, if the file is in the correct folder and so on. Your problem is along that line.