aboutsummaryrefslogtreecommitdiff
path: root/Northstar.Custom/mod/scripts/vscripts/gamemodes
diff options
context:
space:
mode:
authorGeckoEidechse <40122905+GeckoEidechse@users.noreply.github.com>2024-01-04 01:32:45 +0100
committerGitHub <noreply@github.com>2024-01-04 01:32:45 +0100
commit76582b6890294d2a53163a4be1b806c454aba90e (patch)
tree1f05a59c3c601d340ed6386ed32d1fb975a84b26 /Northstar.Custom/mod/scripts/vscripts/gamemodes
parent44505833b1fb686c614e75d8269f23f0bc3173c4 (diff)
downloadNorthstarMods-76582b6890294d2a53163a4be1b806c454aba90e.tar.gz
NorthstarMods-76582b6890294d2a53163a4be1b806c454aba90e.zip
Use `getrandom()` instead of random int from player array (#778)v1.21.4-rc1v1.21.4
Use `getrandom()` instead of random int from player array to select infected Co-authored-by: ASpoonPlaysGames <66967891+ASpoonPlaysGames@users.noreply.github.com>
Diffstat (limited to 'Northstar.Custom/mod/scripts/vscripts/gamemodes')
-rw-r--r--Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_inf.gnut2
1 files changed, 1 insertions, 1 deletions
diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_inf.gnut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_inf.gnut
index c7175e74..02f0799a 100644
--- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_inf.gnut
+++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_inf.gnut
@@ -54,7 +54,7 @@ void function SelectFirstInfectedDelayed()
return
}
- entity infected = players[ RandomInt( players.len() ) ]
+ entity infected = players.getrandom()
InfectPlayer( infected )
RespawnInfected( infected )