Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
00001 00002 00003 00004 00005 00006 00007 00008 00009 00010 00011 00012 00013 00014 00015 00016 00017 00018 00019 00020 00021 00022 00023 00024 00025 00026 00027 00028 00029 00030 00031 00032 00033 00034 00035 00036 00037 00038 00039 00040 00041 00042 00043 00044 00045 00046 00047 00048 00049 00050 00051 00052 00053 00054 00055 00056 00057 00058 00059 00060 00061 00062 00063 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 00084 00085 00086 00087 00088 00089 00090 00091 00092 00093 00094 00095 00096 00097 00098 00099 00100 00101 00102 00103 00104 00105 00106 00107 00108 00109 00110 00111 00112 00113 00114 00115 00116 00117 00118 00119 00120 00121 00122 00123 00124 00125 00126 00127 00128 00129 00130 00131 00132 00133 00134 00135 00136 00137 00138 00139 00140 00141 00142 |
//============================================================================= // Emitter: An Unreal Emitter Actor. //============================================================================= class Emitter extends Actor native placeable; var() deepcopy editinline array<ParticleEmitter> Emitters; var (Global) bool AutoDestroy; var (Global) bool AutoReset; var (Global) bool DisableFogging; var (Global) bool RotationAndVelocityFromOwner; var (Global) rangevector GlobalOffsetRange; var (Global) range TimeTillResetRange; var transient int Initialized; var transient Box BoundingBox; var transient float EmitterRadius; var transient float EmitterHeight; var transient bool ActorForcesEnabled; var transient vector GlobalOffset; var transient float TimeTillReset; var transient bool UseParticleProjectors; var transient ParticleMaterial ParticleMaterial; var transient bool DeleteParticleEmitters; #if IG_SHARED // rowan: emitter control var bool bPlaying; var bool bStoppedOverTime; event PlayEmitters() { local byte i; if (!bPlaying) { for(i = 0; i<Emitters.Length; ++i) { if (bStoppedOverTime) { Emitters[i].RespawnDeadParticles = true; Emitters[i].KillPending = 0; } Emitters[i].Disabled = false; Emitters[i].ResetParticles(); } bStoppedOverTime = false; bPlaying = true; } } event StopEmitters(optional bool bStopOverTime) { local byte i; if (bPlaying) { // Disable all emitters for(i = 0; i<Emitters.Length; ++i) { if (bStopOverTime) { Emitters[i].RespawnDeadParticles = false; Emitters[i].KillPending = 1; bStoppedOverTime = true; } else { Emitters[i].Disabled = true; } } bPlaying = false; } } #endif // IG // shutdown the emitter and make it auto-destroy when the last active particle dies. native function Kill(); simulated function UpdatePrecacheRenderData() { local int i; for( i=0; i<Emitters.Length; i++ ) { if( Emitters[i] != None ) { if( Emitters[i].Texture != None ) Level.AddPrecacheMaterial(Emitters[i].Texture); } } } event Trigger( Actor Other, Pawn EventInstigator ) { local int i; for( i=0; i<Emitters.Length; i++ ) { if( Emitters[i] != None ) Emitters[i].Trigger(); } } #if IG_EFFECTS event PreAutoDestroyed() { if (bNeedLifeTimeEffectEvents) { UntriggerEffectEvent('Alive'); TriggerEffectEvent('Destroyed'); } } #endif defaultproperties { RemoteRole=ROLE_None Style=STY_Particle DrawType=DT_Particle Texture=Texture'Engine_res.S_Emitter' #if IG_EFFECTS // WARNING: We need emitters to be bNoDelete=false in order to be spawned at runtime by // the Effects System. However, because they are RemoteRole=None, any emitters placed // (not spawned) in a level will not show up on network clients. // We solved this in SWAT by making Engine.Emitter be bNoDelete=true, and having all placed // emitters be Engine.Emitters. Then we made a new SpawnableEmitter subclass that is bNoDelete=false, // and all our effects that are spawned by the Effects System at runtime are subclasses of // SpawnableEmitter. bNoDelete=false #else // bNoDelete=true #endif bUnlit=true bPlaying = true; #if IG_TRIBES3 // david: AutoDestroy default is 'true' AutoDestroy=true #endif } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |