2016-10-14 08:46:15 +00:00
|
|
|
|
2017-01-14 10:43:08 +00:00
|
|
|
class SoundEnvironment : Actor
|
2016-10-14 08:46:15 +00:00
|
|
|
{
|
|
|
|
default
|
|
|
|
{
|
|
|
|
+NOSECTOR
|
|
|
|
+NOBLOCKMAP
|
|
|
|
+NOGRAVITY
|
|
|
|
+DONTSPLASH
|
|
|
|
}
|
2017-01-14 10:43:08 +00:00
|
|
|
|
|
|
|
override void PostBeginPlay ()
|
|
|
|
{
|
|
|
|
Super.PostBeginPlay ();
|
|
|
|
if (!bDormant)
|
|
|
|
{
|
|
|
|
Activate (self);
|
|
|
|
}
|
|
|
|
}
|
2016-10-14 08:46:15 +00:00
|
|
|
|
2017-01-14 10:43:08 +00:00
|
|
|
override void Activate (Actor activator)
|
|
|
|
{
|
|
|
|
CurSector.SetEnvironmentID((args[0]<<8) | (args[1]));
|
|
|
|
}
|
|
|
|
|
|
|
|
// Deactivate just exists so that you can flag the thing as dormant in an editor
|
|
|
|
// and not have it take effect. This is so you can use multiple environments in
|
|
|
|
// a single zone, with only one set not-dormant, so you know which one will take
|
|
|
|
// effect at the start.
|
|
|
|
override void Deactivate (Actor deactivator)
|
|
|
|
{
|
|
|
|
bDormant = true;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|