How to add an earthquake

Prerequisites:
The Basics

Overview:
One way to add "shaking around" or "earthquake" effects to a map is by using the ShakeTrigger.  Perhaps you want to give the player the impression that a large explosion has occurred.

NOTE: The explosion "shakes" and sound effects after you blow up the ship in Deus Ex were done using mission scripting and are much more elaborate that what you can do with a simple ShakeTrigger.  If you'd like to look at the UnrealScript for that, it's in the ShipExplosionEffects function in the Mission09.uc mission script.

 

1. Place the ShakeTrigger

Under Actor -> Triggers -> Trigger, select ShakeTrigger and add one to your map.  Move it somewhere where the player will be able to run into it.  You can use the Actors -> Radii View in the overhead 2D window's menu to look at the "collision radius".  Adjust that if necessary by changing the Collision -> CollisionRadius value.

 

2. Set properties

Pull up the ShakeTrigger's properties and you'll see that under the ShakeTrigger category there are some values you can set.  The shakeRollMagnitude determines how much the player's view will rock back and forth, the shaketime is how many seconds the "quake" will last, and the shakeVertMagnitude determines how much the player's view will shake up and down.

 

3. Trigger a sound effect (optional)

This part is optional, but your shaking effect might seem weird without any sound to go with it.  For this example, set the ShakeTrigger -> shaketime on your ShakeTrigger to 2.0 and set its Events -> Event value to explosionSound.

Under Actor -> Triggers, select SpecialEvent, and add one to your map near your ShakeTrigger.  The icon for the SpecialEvent trigger in the editor looks like a normal trigger, but has an exclamation point on it: .  Pull up the properties for the SpecialEvent in your map and set Events -> Tag to explosionSound.

You'll also need to set Object -> InitialState to PlaySoundEffect, since that's what we want it to do.

The final step is to set SpecialEvent -> Sound to the sound effect you want to play.  Go to the Browse menu and select SoundFX.  For the next two drop-downs, select DeusExSounds, then Generic.  Select an appropriate sound effect, such as LargeExplosion1, click on the "Sound" property, and press the Use button.


Back to main page