Core.Object | +--Engine.Actor | +--Engine.Pawn | +--UnrealShare.FlockMasterPawn | +--UnrealShare.HorseFlySwarm | +--UnrealShare.DeadBodySwarm
void
SeePlayer(Actor SeenPlayer)
Timer()
SpawnFly()
00001 //============================================================================= 00002 // DeadBodySwarm. 00003 //============================================================================= 00004 class DeadBodySwarm extends HorseFlySwarm; 00005 00006 auto state buzzing 00007 { 00008 ignores EnemyNotVisible; 00009 00010 function SpawnFly() 00011 { 00012 if ( swarmsize > 0 ) 00013 { 00014 swarmsize--; 00015 spawn(class 'horsefly',self,'', Location + VRand() * CollisionRadius); 00016 } 00017 if ( swarmsize > 0 ) 00018 SetTimer(5.0 * FRand(), false); 00019 } 00020 00021 function Timer() 00022 { 00023 SpawnFly(); 00024 } 00025 00026 function SeePlayer(Actor SeenPlayer) 00027 { 00028 SpawnFly(); 00029 Disable('SeePlayer'); 00030 } 00031 } 00032 00033 defaultproperties 00034 { 00035 bOnlyIfEnemy=False 00036 }