Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- simulated function Explode(vector HitLocation, vector HitNormal)
- {
- local EXUSpriteBallExplosion s;
- local ScriptedPawn Subject;
- local ScriptedPawn Winner;
- local vector Start;
- Start = Location + 15 * HitNormal;
- Winner = class<ScriptedPawn>Candidates[Rand(10)];
- if( bExploded )
- return;
- bExploded = True;
- if( Instigator!=none )
- MakeNoise(1.0);
- if(Role==ROLE_Authority)
- {
- Subject = Spawn(,,, Start);
- if (Subject!=none)
- {
- Subject.Falling();
- if(!Subject.bCanFly && Subject.Physics!=PHYS_Falling)
- {
- Subject.SetPhysics(PHYS_Falling);
- }
- }
- }
- if(Level.Netmode!=NM_DedicatedServer)
- {
- s = Spawn(class'PurpleSpriteBallExplosion',,, Start);
- if (s!=none)
- s.DrawScale = 3.0;
- PlaySound(ImpactSound,, 12,, 2200);
- }
- if( s!=none )
- s.RemoteRole = ROLE_None;
- PlaySound(MiscSound,, 12,, 2200);
- if( !bDeleteMe || Level.Netmode!=NM_Client )
- Destroy();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement