LolGunZ, where GunZ is for the lulz.
Would you like to react to this message? Create an account in a few clicks or log in to continue.

FBF(Fake But Functional)Water [TuT]

Go down

FBF(Fake But Functional)Water [TuT] Empty FBF(Fake But Functional)Water [TuT]

Post by Jassper123 Tue Jun 02, 2009 7:26 pm

FBF: Fake but Functional


FBF Water is water that doesn't use the same water animations as gunz used to, actually, its just a stagnant pool, and it doesn't even make a splash noise when you fall into it. However, you can make water thats translucent and intangible... or See Thru and... Water, for short. We can achieve this by using shader properties that you can define.


Alright, lets get started.


Since Legion already wrote out a Shader's tutoral, I suggest you go read through that. That will give you a basic idea of what we are doing.
The Legion's Shader Tutorial

The first thing your going to want to do is create a shader file in your script's folder. The scripts folder is how you tell gtk and the compiler what you want to make certain textures do in game.

Open up a text file (notepad) and input this:
Code:

textures/water/water
{
   surfaceparm nonsolid
        surfaceparm additive
        qer_trans 0.8
   qer editorimage "textures/water/water.tga"
}

Let me break this down to you so you understand what it means.

Code:
textures/water/water
This tells the shader file where the texture will be. It saves you time if you put all the same types of shaders in the same folder, so water seemed appropriate at the moment. Use liquid if you want.

Code:
surfaceparm nonsolid
This makes the brush intangible, or noclip.
Code:
surfaceparm additive
This makes the texture translucent, or see thru. WARNING, IF YOU DO NOT CAULK YOUR BRUSHES, THIS LOOKS HORRIBLE.
Code:
qer_trans 0.8
This tells Radiant to display the texture as translucent, or see through. This does not affect gunz at all.
Code:
qer editorimage "textures/water/water.tga"
The most important part, the path to the texture. Make sure you create a water folder and a water texture inside that folder.

Go ahead and save the shader, then edit the shader list file and add 'water'




Lets review:

To make water

1. Create water.shader in root/scripts/
2. Input:
Code:

textures/water/water
{
   surfaceparm nonsolid
        surfaceparm additive
        qer_trans 0.8
   qer editorimage "textures/water/water.tga"
}
3. Save water.shader as a shader file.
4. Create a water folder in root/textures
5. Place said 'water.tga' in water folder.


Voila, throw it on a map and be amazed.


Ironically, this is also how you make fake doors.

Code:
Credits and Tutorial to Jassper123
Jassper123
Jassper123
I PoSt A lOt

Posts : 206
Join date : 2009-05-30
Age : 31
Location : Granville, New York

Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum