Glass is a pretty fundamental part of first-person shooters these days. It's taken for granted most of the time, but it adds greatly to the general realism. And it's fun to shoot, too.
Make some Glass
For this tutorial I built a glass house thing, kind of like the one that is included with Red Faction. Half-Life's glass is not as satisfying to destroy as Red Faction's, but it's still a pretty fun way to pass time... if you're bored.
There's nothing particularly special about Half-Life's glass, apart from its unique bullet marks. If you create a slab of glass in WorldCraft (i.e. any brush with one of the 'glass' textures covering it), it will just look like any other object. Only when it's an entity can it be translucent and breakable, and it's not difficult to set up.
First you need your brush. Click Browse
on the texture panel in WorldCraft, and type 'glass' into the Filter box. A group of glass textures should appear. I used 'glass_med' for my example map. Double-click the texture you want, and create a simple cube somewhere.
Once you've created your brush, right-click it and select Tie to Entity
. Choose func_breakable
from the entity list that pops up. Obviously if you'd prefer indestructible glass you'll have to use something different - try func_wall
. If you are using the func_breakable
, set Gibs Direction
to Relative to Attack
(looks a bit cooler this way). Material Type
should already be Glass
, and everything else can stay as it is. Simple!
You will find that almost all of the brush-based entities you can create in WorldCraft have these basic properties:Render FXRender ModeFX AmountFX Color
To make your glass translucent, open your new brush's property sheet (right-click it), set Render Mode
, and type some numerical value between 1
in FX Amount
is fully opaque, and 1
is transparent. A value of about 100
generally works for glass, but you can experiment and choose something that suits you.
That's about all there is to it. Fire up the example map, pick up one of the weapons, and blow away some windows!