Core.Object | +--Engine.Actor | +--Engine.Brush | +--Engine.Volume | +--XIII.LethalVolume
string
LethalVolumeGameOverTypes[3]
LethalVolPointOfView
PointOfViewWhenFalling
enum
eLVGameOver
void
Touch(Actor Other)
//_____________________________________________________________________________
00001 //----------------------------------------------------------- 00002 // 00003 //----------------------------------------------------------- 00004 class LethalVolume extends Volume; 00005 00006 VAR() enum eLVGameOver 00007 { 00008 GO_Falling, 00009 GO_Killed, 00010 GO_GoalIncomplete, 00011 } GameOverType; 00012 VAR() LethalVolPointOfView PointOfViewWhenFalling; 00013 00014 VAR string LethalVolumeGameOverTypes[3]; 00015 00016 //_____________________________________________________________________________ 00017 auto STATE() WaitForTouch 00018 { 00019 function Touch (actor Other) 00020 { 00021 // Log(self@"touched by"@other); 00022 if ( (XIIIPlayerPawn(Other) != none) && !XIIIPlayerPawn(Other).bIsDead ) 00023 { 00024 Level.Game.EndGame( XIIIPlayercontroller(XIIIPlayerPawn(Other).controller).PlayerReplicationInfo, LethalVolumeGameOverTypes[GameOverType] ); 00025 XIIIPlayerPawn(Other).PlayDying(class'DTSuicided', vect(0,0,0)); 00026 } 00027 } 00028 } 00029 00030 STATE() TriggerTurnOn 00031 { 00032 EVENT Trigger( actor Other, pawn EventInstigator ) 00033 { 00034 GotoState('WaitForTouch'); 00035 } 00036 } 00037 00038 00039 00040 defaultproperties 00041 { 00042 GameOverType=GO_Killed 00043 LethalVolumeGameOverTypes(0)="PlayerFalling" 00044 LethalVolumeGameOverTypes(1)="PlayerKilled" 00045 LethalVolumeGameOverTypes(2)="GoalIncomplete" 00046 InitialState="WaitForTouch" 00047 }