rott/kf_sources/KFMod/Classes/LevelSwitcher.uc
2026-07-14 20:27:09 +07:00

40 lines
749 B
Ucode

// Custom Trigger to switch maps , in Killing Floor Single Play
class LevelSwitcher extends Trigger;
var() name NextMapName;
function Touch( actor Other )
{
if( IsRelevant( Other ) )
{
Other = FindInstigator( Other );
if ( ReTriggerDelay > 0 )
{
if ( Level.TimeSeconds - TriggerTime < ReTriggerDelay )
return;
TriggerTime = Level.TimeSeconds;
}
TriggerEvent(Event, self, Other.Instigator);
// Switch to new map
if ( (Pawn(Other) != None) && (Pawn(Other).Controller != None) )
{
Pawn(Other).Controller.ConsoleCommand("OPEN KFS-04");
}
}
}
defaultproperties
{
}