Core.Object | +--Engine.Actor | +--Engine.Decoration | +--UnrealShare.SteelBarrel | +--UnrealShare.TarydiumBarrel
bChainedExplosion,
bDestroy
void
TakeDamage(int NDamage, Pawn instigatedBy, Vector hitlocation, Vector momentum, name damageType)
Timer()
00001 //============================================================================= 00002 // TarydiumBarrel. 00003 //============================================================================= 00004 class TarydiumBarrel extends SteelBarrel; 00005 00006 #exec TEXTURE IMPORT NAME=Jsteelbarrel2 FILE=MODELS\steelbt.PCX GROUP="Skins" 00007 00008 var bool bChainedExplosion, bDestroy; 00009 00010 auto state active 00011 { 00012 00013 function Timer() 00014 { 00015 local int NumChunks; 00016 local SpriteBallExplosion s; 00017 local RingExplosion3 r; 00018 00019 Super.Timer(); 00020 00021 if (!bDestroy) Return; 00022 00023 NumChunks = 12; 00024 s = spawn(class'SpriteBallExplosion'); 00025 r = spawn(class'RingExplosion3',,,Location - Vect(0,0,16),rot(16384,0,0)); 00026 r.PlaySound(r.ExploSound,,6); 00027 HurtRadius(250, 100, 'destroyed', 0, Location); 00028 if (bChainedExplosion) NumChunks = 4; 00029 skinnedFrag(class'Fragment1', texture'JSteelBarrel2', Vect(20000,0,0),1.0, 7); 00030 } 00031 00032 function TakeDamage( int NDamage, Pawn instigatedBy, Vector hitlocation, 00033 Vector momentum, name damageType) 00034 { 00035 bChainedExplosion = False; 00036 bDestroy=True; 00037 if (DamageType=='destroyed') { 00038 SetTimer(FRand()*0.4+0.2,False); 00039 bChainedExplosion = True; 00040 } 00041 else Timer(); 00042 Instigator = InstigatedBy; 00043 if ( Instigator != None ) 00044 MakeNoise(1.0); 00045 } 00046 00047 Begin: 00048 } 00049 00050 defaultproperties 00051 { 00052 Health=1 00053 Skin=Texture'UnrealShare.Skins.Jsteelbarrel2' 00054 }