aboutsummaryrefslogtreecommitdiff
path: root/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut
diff options
context:
space:
mode:
authorBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-06-23 05:06:17 +0100
committerBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-06-23 05:06:17 +0100
commit8d4c71f7779120298773c9232dcdaa0fa0063786 (patch)
treeba87b4e511de66161faabd7ba8ffa3efcab08974 /Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut
parent207facbc402f5639cbcd31f079214351ef605cf2 (diff)
downloadNorthstarMods-8d4c71f7779120298773c9232dcdaa0fa0063786.tar.gz
NorthstarMods-8d4c71f7779120298773c9232dcdaa0fa0063786.zip
lts and powerup rewrite, more gamestate changes
Diffstat (limited to 'Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut')
-rw-r--r--Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut14
1 files changed, 2 insertions, 12 deletions
diff --git a/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut b/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut
index 9c70cfb90..91ebf8c69 100644
--- a/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut
+++ b/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_speedball.nut
@@ -14,9 +14,9 @@ void function GamemodeSpeedball_Init()
// gamemode settings
SetRoundBased( true )
SetRespawnsEnabled( false )
+ SetShouldUseRoundWinningKillReplay( true )
Riff_ForceTitanAvailability( eTitanAvailability.Never )
Riff_ForceSetEliminationMode( eEliminationMode.Pilots )
- SetServerVar( "roundWinningKillReplayEnabled", true ) // really ought to get a function for setting this
AddSpawnCallbackEditorClass( "script_ref", "info_speedball_flag", CreateFlag )
@@ -59,19 +59,9 @@ void function OnPlayerKilled( entity victim, entity attacker, var damageInfo )
DropFlag()
if ( victim.IsPlayer() && GetGameState() == eGameState.Playing )
- {
- // this REALLY ought to be an elimationmode thing rather than gamemode-based
- int livingPlayers
- foreach ( entity player in GetPlayerArrayOfTeam( victim.GetTeam() ) )
- if ( IsAlive( player ) )
- livingPlayers++
-
- if ( livingPlayers == 0 )
- SetWinner( GetOtherTeam( victim.GetTeam() ) )
- else if ( livingPlayers == 1 )
+ if ( GetPlayerArrayOfTeam_Alive( victim.GetTeam() ).len() == 1 )
foreach ( entity player in GetPlayerArray() )
Remote_CallFunction_NonReplay( player, "ServerCallback_SPEEDBALL_LastPlayer", player.GetTeam() != victim.GetTeam() )
- }
}
void function GiveFlag( entity player )