Please Help Support E-Mods.net by Donating

e-mods.net

  • 2017-10-24, 02:42:38
  • Welcome, Guest
Please login or register.

Login with username, password and session length
Advanced search

News:

Looking for VTMR Modding Tutorials? Check out the Open Nod Development section of e-mods.net.

Author Topic: Creating Masked Textures  (Read 1318 times)

Nagaraja

  • Member
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 49
Creating Masked Textures
« on: 2007-07-23, 14:13:35 »

Question

How do I make textures for the game that have areas that can be seen through (transparent)?

Answer

To do this you first need to create your texture and prep it in a graphics editor then specially prepare the textures .nam file.

Although this can be accomplished by most graphics program I am using the Paint Shop Pro interfaqce in the below example to explain it, but it can be applied to other graphic editors out there.

First save your texture as a tga file (the usual 24bit, uncompressed). Then
color all areas of the image that you want to be transparent with black
paint. Then go to your masks menu and select mask->new->from image. A dialog will
show up, select "Any non zero value" and make sure the drop down says "this window", your black painted areas should turn
white. No go back into the masks menu and choose "Save to Alpha Channel", make
sure the filename of your texture is in the drop down box and click OK.
Give the channel a name (anything will do) and your texture is now prepared.
Last thing you need to do is make a quick edit to your textures .nam files.
Basically all you have to do is add the keyword "masked" to the file beneath
your texture statement like so:

texture vine.tga
masked

and save it. Be sure to save your texture to both your subdirectory and the
main materials directory else it wont show in game.

Thats about it. Masks are great for adding dirt to floors in uneven patterns, cobwebs, hanging foliage, etc... Im just beginning my experimentation with it and no dount Im gonna find dozens of good uses and nifty tricks. Let us know if you find anything useful above and beyond making irregular shaped tiles.

Oh by the way if your transparent sections of your brush intersect any walls or floors they overide that brushes material in the intersected area and make it see through, resulting in holes in your structures and buildings, so place these carefuly or set the surface properties of the texture in Embrace to decal, NO CSG, NO lightblock, NO lightmap.

-Jaks 
« Last Edit: 2007-07-23, 14:18:21 by Nagaraja »
Logged
 

Page created in 0.07 seconds with 24 queries.