Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

DeusEx.PlasmaBolt


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
//=============================================================================
// PlasmaBolt.
//=============================================================================
class PlasmaBolt extends DeusExProjectile;

var ParticleGenerator pGen1;
var ParticleGenerator pGen2;

var float mpDamage;
var float mpBlastRadius;

#exec OBJ LOAD FILE=Effects

simulated function DrawExplosionEffects(vector HitLocation, vector HitNormal)
{
    local ParticleGenerator gen;

    // create a particle generator shooting out plasma spheres
    gen = Spawn(class'ParticleGenerator',,, HitLocation, Rotator(HitNormal));
    if (gen != None)
    {
      gen.RemoteRole = ROLE_None;
        gen.particleDrawScale = 1.0;
        gen.checkTime = 0.10;
        gen.frequency = 1.0;
        gen.ejectSpeed = 200.0;
        gen.bGravity = True;
        gen.bRandomEject = True;
        gen.particleLifeSpan = 0.75;
        gen.particleTexture = Texture'Effects.Fire.Proj_PRifle';
        gen.LifeSpan = 1.3;
    }
}

function PostBeginPlay()
{
    Super.PostBeginPlay();

   if ((Level.NetMode == NM_Standalone) || (Level.NetMode == NM_ListenServer))
      SpawnPlasmaEffects();
}

simulated function PreBeginPlay()
{
    Super.PreBeginPlay();

    Damage = mpDamage;
    blastRadius = mpBlastRadius;
}

simulated function PostNetBeginPlay()
{
   if (Role < ROLE_Authority)
      SpawnPlasmaEffects();
}

// DEUS_EX AMSD Should not be called as server propagating to clients.
simulated function SpawnPlasmaEffects()
{
    local Rotator rot;
   rot = Rotation;
    rot.Yaw -= 32768;

   pGen2 = Spawn(class'ParticleGenerator', Self,, Location, rot);
    if (pGen2 != None)
    {
      pGen2.RemoteRole = ROLE_None;
        pGen2.particleTexture = Texture'Effects.Fire.Proj_PRifle';
        pGen2.particleDrawScale = 0.1;
        pGen2.checkTime = 0.04;
        pGen2.riseRate = 0.0;
        pGen2.ejectSpeed = 100.0;
        pGen2.particleLifeSpan = 0.5;
        pGen2.bRandomEject = True;
        pGen2.SetBase(Self);
    }
   
}

simulated function Destroyed()
{
    if (pGen1 != None)
        pGen1.DelayedDestroy();
    if (pGen2 != None)
        pGen2.DelayedDestroy();

    Super.Destroyed();
}

defaultproperties
{
     mpDamage=8.000000
     mpBlastRadius=300.000000
     bExplodes=True
     blastRadius=128.000000
     DamageType=Burned
     AccurateRange=14400
     maxRange=24000
     bIgnoresNanoDefense=True
     ItemName="Plasma Bolt"
     ItemArticle="a"
     speed=1500.000000
     MaxSpeed=1500.000000
     Damage=40.000000
     MomentumTransfer=5000
     ImpactSound=Sound'DeusExSounds.Weapons.PlasmaRifleHit'
     ExplosionDecal=Class'DeusEx.ScorchMark'
     Mesh=LodMesh'DeusExItems.PlasmaBolt'
     DrawScale=3.000000
     bUnlit=True
     LightType=LT_Steady
     LightEffect=LE_NonIncidence
     LightBrightness=200
     LightHue=80
     LightSaturation=128
     LightRadius=3
     bFixedRotationDir=True
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: Mon 8/11/2021 16:22:52.000 - Creation time: Mon 8/11/2021 16:31:31.360 - Created with UnCodeX