Game Development Community

Specular map or similar effect in Max for TGE

by Nmuta Jones · in Artist Corner · 07/24/2009 (2:33 pm) · 1 replies

I am using Max 9.

I want a bowl to look shiny.

I could use an environmental map, specular map, or anything that would help me achieve this effect. How do I set up a material in max so that it looks 'shiny', preferably reflecting something (does not have to be the environment....it could be a 'fake' effect).

I tried TDN but for some reason my browser gets a blank screen every time I've visited today.

thanks in advance.

#1
07/25/2009 (12:14 am)
The trick is to use the alpha blending cubemap trick. First, you need to understand that Photoshop, if you are using Photoshop, does _NOT_ properly export alpha channels. You will need to use a plugin for Photoshop like SuperPNG, or another program altogether, such as Gimp (most other programs export Alpha Channels without a problem).

Now you set the white values to be where you want your 'specular' to show, and dark values where it should not show.

Now! In 3D Studio Max, for your material (and it has been a long while since I've done this, and I don't currently have Max installed, so I'm running this from memory, so I apologize if it is slightly off)... in your material channel, add a Reflective property, and set its value. Now export your model.

In Torque, you will need to define a material (yes, the original Torque had materials as well - just not as advanced as what is in Torque3D). To do that, you will need to add a line of code that looks like this (taken from the propertyMap.cs file in the Interiors directory from a default install of Torque):

addMaterialMapping( "Floor_slate01" , "sound: 0" );

Here is a copy/paste of the post from TDN which describes this function:

addMaterialMapping( materialName, map0 [ , ... , map97 ])
Purpose
Use the addMaterialMapping function to create a new material map instance. These maps are used by terrain and interiors for creating proper footstep sounds and dust puffs when an avatar treads upon a terrain block or interior surface using the associated texture.

Syntax
materialName: The unadorned texture name this map is associated with. For example, "sand.jpg" would have a materialName of "sand".
map0: At least one (required) map. See map chart below for format of these maps.
... , map97 - Up to 96 additional maps.

Returns
No return value.

Notes
There are fewer mapping types than the maximum number of maps this function will accept.


And the direct link to that page: tdn.garagegames.com/wiki/TorqueScript_Console_Functions_12#addMaterialMapping.28...


Hope that helps!!