Core.Object | +--Engine.Actor | +--Engine.Effects | +--Engine.Debris | +--RuneI.DebrisFlesh
bool
bWasInAir
simulated
PlayLandSound()
void
PreBeginPlay()
SpawnDebrisDecal(vector HitNormal)
ZoneChange(ZoneInfo NewZone)
00001 //============================================================================= 00002 // DebrisFlesh. 00003 //============================================================================= 00004 class DebrisFlesh extends Debris; 00005 00006 00007 var bool bWasInAir; 00008 00009 00010 function PreBeginPlay() 00011 { 00012 Super.PreBeginPlay(); 00013 00014 if(class'GameInfo'.Default.bLowGore) 00015 { 00016 Destroy(); 00017 } 00018 } 00019 00020 simulated function ZoneChange(ZoneInfo NewZone) 00021 { 00022 local actor A; 00023 00024 if (class'GameInfo'.Default.bLowGore ) 00025 { 00026 return; 00027 } 00028 00029 if (!NewZone.bWaterZone) 00030 { 00031 bWasInAir = True; 00032 } 00033 else 00034 { // Entered water 00035 if (bWasInAir) 00036 { // spawn a bloodUnderwater on surface 00037 RotationRate = rot(0,0,0); 00038 Spawn(class'BloodWaterSurface',,, Location, rot(16384,0,0)); 00039 } 00040 else 00041 { 00042 A = Spawn(class'BloodUnderwater',,, Location, rotator(VRand())); 00043 } 00044 } 00045 } 00046 00047 00048 simulated function PlayLandSound() 00049 { 00050 switch(Rand(6)) 00051 { 00052 case 0: 00053 PlaySound(Sound'OtherSnd.Gibs.gib01'); 00054 break; 00055 case 1: 00056 PlaySound(Sound'OtherSnd.Gibs.gib02'); 00057 break; 00058 case 2: 00059 PlaySound(Sound'OtherSnd.Gibs.gib03'); 00060 break; 00061 case 3: 00062 PlaySound(Sound'OtherSnd.Gibs.gib04'); 00063 break; 00064 case 4: 00065 PlaySound(Sound'OtherSnd.Gibs.gib05'); 00066 break; 00067 case 5: 00068 PlaySound(Sound'OtherSnd.Gibs.gib06'); 00069 break; 00070 } 00071 } 00072 00073 simulated function SpawnDebrisDecal(vector HitNormal) 00074 { 00075 switch(Rand(5)) 00076 { // These are in order by size 00077 case 0: 00078 Spawn(class'DecalBlood',self,,Location, rotator(HitNormal)); 00079 break; 00080 case 1: 00081 Spawn(class'DecalBlood2',self,,Location, rotator(HitNormal)); 00082 break; 00083 case 2: 00084 Spawn(class'DecalBlood3',self,,Location, rotator(HitNormal)); 00085 break; 00086 case 3: 00087 Spawn(class'DecalBlood4',self,,Location, rotator(HitNormal)); 00088 break; 00089 case 4: 00090 Spawn(class'DecalBlood5',self,,Location, rotator(HitNormal)); 00091 break; 00092 } 00093 } 00094 00095 defaultproperties 00096 { 00097 LandSound=Sound'OtherSnd.Gibs.gib01' 00098 Skeletal=SkelModel'objects.Chunks' 00099 SkelGroupSkins(1)=Texture'objects.Chunksflesh' 00100 }