| Glass Tutorial |
|
The other day I had a request about how to make a breakable glass
window, and seeing as I wasn't to sure on one or tow things I investigated,
starting with how best to make a glass window, and then how to make
it breakable etc.
|
| |
|
You have a number of options here.
|
|
| Option 1 - A sheet |
| You can use a sheet to make a window, but it will not
stop players or bullets |
| Option 2 - A semi-solid cube brush |
| This is almost the same as a sheet really |
| Option 3 - A solid cube brush (My personel favourite) |
| With this option you must make sure that the brush
does not touch other solid brushes else you get the HOM effect. |
| If you choose options 1 and 2 and you want players
blocked you will have to add an invisible collision hull brush to
blockthe player. Remember, these mustn't touch any other solid brushes
as well. |
| Obviously if you are making a walkway then it needs
to be solid, so you either need to choose Option 3 above, or Options
1 or 2 with a suitable invisible collision hull. Everything else would
be the same. |
| The most important property of the surface is obvious
Translucent. But I also find that setting most Glass textures to Unlit
makes them show up better. For a sheet you should make sure it is
2 sided as well. |
| You can stop here if all you want is
a glass window/walkway. The rest of the tutorial is for breakable
glass. |
| |
|
Next you should convert the brush into a mover by selecting it,
copying polys to brush and then clicking the Add Mover button. Set
the keyframe 0 to be where the window is, and Keyframe 1 to be somewhere
well out of reach, out of the map even.
|
| Set the Mover->MoveTime to 0. If you want
the window to return at some point then set Object->InitialState
to TriggerOpenTimed, else set it to TriggerToggle. If you choose TriggerOpenTimed
then set Mover->StayOpenTime to 30-60 seconds. |
| Most importantly of all set Mover->bDamageTriggered
to true and Mover->DamageThreshold to some value (5 to always
break, higher for more damage needed). Then set Event->Event
to bg1. |
| BreakingGlass is found under Effects->ExplodingWall->BreakingGlass. |
| You can place as many BreakingGlass objects as you
want, they should all have the same Tag so they are triggered when
the window is hit, so set Events->Tag to bg1. |
| Next set Effects->bOnlyTriggerable to true,
else when you shoot the BreakingGlass it will break on its own. |
| Next set ExplodingWall->bTranslucentGlass
to true and ExplodingWall->bUnlitGlass to true. |
| If you want the effect to happen more than once you
need to set Advanced->bNoDelete to true. |
| I've also discovered a 'feature' where the BreakingGlass
objects block projectiles from hitting the glass window so it can
help to set Collision->bCollideActors to false to stop this
happening. |
| That should be about it, and everything should work. |
| Download my Test map to see a working window. TUT-GLASS.ZIP |
| |