diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-07-17 23:46:52 +0100 |
---|---|---|
committer | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-07-17 23:46:52 +0100 |
commit | 27bd240871b7c0f2f49fef137718b2e3c208e3b4 (patch) | |
tree | a46f401fa389edbb42a32fe8674cbde3a28e7632 /Northstar.CustomServers/scripts/vscripts/gamemodes | |
parent | 1c1d36fad84687a93a629525145c557f78cbf673 (diff) | |
download | NorthstarMods-27bd240871b7c0f2f49fef137718b2e3c208e3b4.tar.gz NorthstarMods-27bd240871b7c0f2f49fef137718b2e3c208e3b4.zip |
ctf switchsides spawn fix (untested)
Diffstat (limited to 'Northstar.CustomServers/scripts/vscripts/gamemodes')
-rw-r--r-- | Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_ctf.nut | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_ctf.nut b/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_ctf.nut index 728d742d..704f55d3 100644 --- a/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_ctf.nut +++ b/Northstar.CustomServers/scripts/vscripts/gamemodes/_gamemode_ctf.nut @@ -69,8 +69,12 @@ void function RateSpawnpoints_CTF( int checkClass, array<entity> spawnpoints, in // if there are, spawn them outside of it ( but ideally still close ) // max distance away should be like, angel city markets - array<entity> startSpawns = SpawnPoints_GetPilotStart( team ) - array<entity> enemyPlayers = GetPlayerArrayOfTeam_Alive( GetOtherTeam( team ) ) + int spawnTeam = team + if ( HasSwitchedSides() ) + spawnTeam = GetOtherTeam( team ) + + array<entity> startSpawns = SpawnPoints_GetPilotStart( spawnTeam ) + array<entity> enemyPlayers = GetPlayerArrayOfTeam_Alive( GetOtherTeam( spawnTeam ) ) vector startSpawnAverage bool enemyInBase = false |