Simple Short Tutorial
Posted: Wed Oct 03, 2012 6:31 pm
Create Texture: any image contains wooden planks, resize to 256x256 / 512x512 / 1024x1024 (32*2*n)
Blender: new project with basic cube

Blender: add UV map to cube faces: Select face - Mesh - UV unwrap - Unwrap

Blender: optional - rename material
Blender: File - Export - Wavefron (.obj)
GMT (Grimrock Model Toolkit): Import OBJ Model
GMT: Tools - Material Find / Replace - replace (or check) the right material name

GMT: File - Save (.model) - wooden_cube.model
Photoshop: Export texture to DDS format: Save as Nvidia DDS format DXT3 (downloadable plugin for Photoshop)

Photoshop: Save texture as wooden_planks_dif.dds
Copy wooden_cube.model to your Grimrock "/mod_assets/models/wooden_cube.model"
Copy wooden_planks_dif.dds to your Grimrock "/mod_assets/textures/wooden_planks_dif.dds"
Edit "/mod_assets/models/scripts.lua":
Edit "/mod_assets/models/objects.lua":
Grimrock Editor: Open/Reload your project, place "wooden_cube" anywhere

Next to work is creating the other 2 textures (normal map and specular map) for make it looks better...
Blender: new project with basic cube

Blender: add UV map to cube faces: Select face - Mesh - UV unwrap - Unwrap

Blender: optional - rename material
Blender: File - Export - Wavefron (.obj)
GMT (Grimrock Model Toolkit): Import OBJ Model
GMT: Tools - Material Find / Replace - replace (or check) the right material name

GMT: File - Save (.model) - wooden_cube.model
Photoshop: Export texture to DDS format: Save as Nvidia DDS format DXT3 (downloadable plugin for Photoshop)

Photoshop: Save texture as wooden_planks_dif.dds
Copy wooden_cube.model to your Grimrock "/mod_assets/models/wooden_cube.model"
Copy wooden_planks_dif.dds to your Grimrock "/mod_assets/textures/wooden_planks_dif.dds"
Edit "/mod_assets/models/scripts.lua":
Code: Select all
defineMaterial{
name = "wooden_planks",
diffuseMap = "mod_assets/textures/wooden_planks_dif.tga",
-- specularMap = "",
-- normalMap = "",
doubleSided = false,
lighting = true,
alphaTest = false,
blendMode = "Opaque",
textureAddressMode = "Wrap",
glossiness = 30,
depthBias = 0,
}
Code: Select all
cloneObject{
name = "wooden_cube",
baseObject = "barrel_crate_block",
model = "mod_assets/models/wooden_cube.fbx",
}
Next to work is creating the other 2 textures (normal map and specular map) for make it looks better...



