aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-06 21:52:34 +0000
committerBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-06 21:52:34 +0000
commit1f534d940670d6df826be68b39fcaa846f139a81 (patch)
treeb5c08b6f8a12a2047455e9b1066d855bf803e632
parentf1a07e1b01923b45f7a82c063d25b8dea5b13d53 (diff)
downloadNorthstarMods-1f534d940670d6df826be68b39fcaa846f139a81.tar.gz
NorthstarMods-1f534d940670d6df826be68b39fcaa846f139a81.zip
some bugfixes from playtest
-rw-r--r--Northstar.Client/mod/resource/northstar_client_localisation_english.txtbin17064 -> 17134 bytes
-rw-r--r--Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut2
-rw-r--r--Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_hs.gnut2
-rw-r--r--Northstar.CustomServers/mod/cfg/autoexec_ns_server.cfg14
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_ctf.nut15
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/lobby/sh_private_lobby_modes_init.gnut1
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/mp/_base_gametype_mp.gnut23
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/mp/spawn.nut6
8 files changed, 40 insertions, 23 deletions
diff --git a/Northstar.Client/mod/resource/northstar_client_localisation_english.txt b/Northstar.Client/mod/resource/northstar_client_localisation_english.txt
index d3cc63f38..d8cf9a0cd 100644
--- a/Northstar.Client/mod/resource/northstar_client_localisation_english.txt
+++ b/Northstar.Client/mod/resource/northstar_client_localisation_english.txt
Binary files differ
diff --git a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
index c288b3a83..63377f9fd 100644
--- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
+++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
@@ -172,7 +172,7 @@ string function FormatServerDescription( int server )
void function OnServerSelected( var button )
{
- if ( NSIsRequestingServerList() || !NSMasterServerConnectionSuccessful() )
+ if ( NSIsRequestingServerList() || !NSMasterServerConnectionSuccessful() || NSGetServerCount() == 0 )
return
int serverIndex = file.page * BUTTONS_PER_PAGE + int ( Hud_GetScriptID( button ) )
diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_hs.gnut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_hs.gnut
index ccdd5b853..af7aaced4 100644
--- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_hs.gnut
+++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_hs.gnut
@@ -171,7 +171,7 @@ void function TryNotifyLastPlayerAlive( entity victim, entity attacker, var dama
if ( victim.GetTeam() == HIDEANDSEEK_TEAM_HIDER )
{
array<entity> hiders = GetPlayerArrayOfTeam( HIDEANDSEEK_TEAM_HIDER )
- if ( hiders.len() == 1 )
+ if ( hiders.len() == 2 ) // 2nd to last hider is the one getting killed rn
{
PlayMusicToAll( eMusicPieceID.GAMEMODE_2 )
diff --git a/Northstar.CustomServers/mod/cfg/autoexec_ns_server.cfg b/Northstar.CustomServers/mod/cfg/autoexec_ns_server.cfg
index 66efa13d3..0e55312da 100644
--- a/Northstar.CustomServers/mod/cfg/autoexec_ns_server.cfg
+++ b/Northstar.CustomServers/mod/cfg/autoexec_ns_server.cfg
@@ -1,5 +1,9 @@
-//ns_auth_allow_insecure 1
-ns_server_name "boba server (very cool)"
-ns_server_desc "fucign badass dude "
-ns_masterserver_hostname "192.248.160.3"
-everything_unlocked 1 \ No newline at end of file
+ns_server_name "Unnamed Northstar Server" // server name
+ns_server_desc "Default server description" // server description
+ns_server_password "" // server password
+ns_report_server_to_masterserver 1 // whether this server should report itself to the masterserver
+ns_report_sp_server_to_masterserver 0 // whether this server should report itself to the masterserver if started on a singleplayer map
+
+ns_auth_allow_insecure 0 // keep this to 0 unless you want to allow people to join without masterserver auth/persistence
+ns_erase_auth_info 1 // keep this to 1 unless you're testing and crashing alot, so you don't have to go through the northstar lobby to reauth
+ns_player_auth_port 8081 // this can be whatever, make sure it's portforwarded over tcp
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_ctf.nut b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_ctf.nut
index dad94f672..09caa48d1 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_ctf.nut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_gamemode_ctf.nut
@@ -71,21 +71,24 @@ void function RateSpawnpoints_CTF( int checkClass, array<entity> spawnpoints, in
// get average startspawn position and max dist between spawns
// could probably cache this, tbh, not like it should change outside of halftimes
vector averageFriendlySpawns
- float maxFriendlySpawnDist
+ float averageFriendlySpawnDist
+
+ int averageDistCount
foreach ( entity spawn in startSpawns )
{
foreach ( entity otherSpawn in startSpawns )
{
float dist = Distance2D( spawn.GetOrigin(), otherSpawn.GetOrigin() )
- if ( dist > maxFriendlySpawnDist )
- maxFriendlySpawnDist = dist
+ averageFriendlySpawnDist += dist
+ averageDistCount++
}
averageFriendlySpawns += spawn.GetOrigin()
}
averageFriendlySpawns /= startSpawns.len()
+ averageFriendlySpawnDist /= averageDistCount
// get average enemy startspawn position
vector averageEnemySpawns
@@ -97,7 +100,7 @@ void function RateSpawnpoints_CTF( int checkClass, array<entity> spawnpoints, in
// from here, rate spawns
float baseDistance = Distance2D( averageFriendlySpawns, averageEnemySpawns )
- float spawnIterations = ( baseDistance / maxFriendlySpawnDist ) / 2
+ float spawnIterations = ( baseDistance / averageFriendlySpawnDist ) / 2
foreach ( entity spawn in spawnpoints )
{
@@ -108,11 +111,11 @@ void function RateSpawnpoints_CTF( int checkClass, array<entity> spawnpoints, in
for ( int i = 0; i < spawnIterations; i++ )
{
- vector zonePos = averageFriendlySpawns + Normalize( averageEnemySpawns - averageFriendlySpawns ) * ( i * maxFriendlySpawnDist )
+ vector zonePos = averageFriendlySpawns + Normalize( averageEnemySpawns - averageFriendlySpawns ) * ( i * averageFriendlySpawnDist )
float zonePower
foreach ( entity player in enemyPlayers )
- if ( Distance2D( player.GetOrigin(), zonePos ) < maxFriendlySpawnDist )
+ if ( Distance2D( player.GetOrigin(), zonePos ) < averageFriendlySpawnDist )
zonePower += 1.0 / enemyPlayers.len()
zonePower = min( zonePower, remainingZonePower )
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/lobby/sh_private_lobby_modes_init.gnut b/Northstar.CustomServers/mod/scripts/vscripts/lobby/sh_private_lobby_modes_init.gnut
index 5cd4de503..a7d6152b3 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/lobby/sh_private_lobby_modes_init.gnut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/lobby/sh_private_lobby_modes_init.gnut
@@ -31,6 +31,7 @@ void function PrivateMatchModesInit()
AddPrivateMatchModeSettingEnum( "#MODE_SETTING_CATEGORY_RIFF", "featured_mode_amped_tacticals", [ "Disabled", "Enabled" ], "0" )
AddPrivateMatchModeSettingEnum( "#MODE_SETTING_CATEGORY_RIFF", "featured_mode_rocket_arena", [ "Disabled", "Enabled" ], "0" )
AddPrivateMatchModeSettingEnum( "#MODE_SETTING_CATEGORY_RIFF", "featured_mode_shotguns_snipers", [ "Disabled", "Enabled" ], "0" )
+ AddPrivateMatchModeSettingEnum( "#MODE_SETTING_CATEGORY_RIFF", "iron_rules", [ "Disabled", "Enabled" ], "0" )
// gamemode settings
AddPrivateMatchModeSettingEnum( "#GAMEMODE_cp", "cp_amped_capture_points", [ "Disabled", "Enabled" ], "1" ) // would've been nice to use amped_capture_points, but this var is already used ingame and its value is default 0
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/_base_gametype_mp.gnut b/Northstar.CustomServers/mod/scripts/vscripts/mp/_base_gametype_mp.gnut
index 70fa148e1..fcad7d31f 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/mp/_base_gametype_mp.gnut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/_base_gametype_mp.gnut
@@ -415,7 +415,6 @@ void function RespawnAsPilot( entity player, bool manualPosition = false )
void function RespawnAsTitan( entity player, bool manualPosition = false )
{
player.isSpawning = true
-
entity spawnpoint = FindSpawnPoint( player, true, ShouldStartSpawn( player ) && !IsFFAGame() )
TitanLoadoutDef titanLoadout = GetTitanLoadoutForPlayer( player )
@@ -429,7 +428,6 @@ void function RespawnAsTitan( entity player, bool manualPosition = false )
player.SetPetTitan( null ) // prevent embark prompt from showing up
AddCinematicFlag( player, CE_FLAG_HIDE_MAIN_HUD ) // hide hud
- player.HolsterWeapon() // hide crosshair
// do titanfall scoreevent
AddPlayerScore( player, "Titanfall", player )
@@ -449,20 +447,27 @@ void function RespawnAsTitan( entity player, bool manualPosition = false )
camera.SetLocalAngles( < camera.GetAngles().x, spawnpoint.GetAngles().y, camera.GetAngles().z > ) // this straight up just does not work lol
camera.Fire( "Enable", "!activator", 0, player )
- waitthread TitanHotDrop( titan, "at_hotdrop_01", spawnpoint.GetOrigin(), spawnpoint.GetAngles(), player, camera ) // do hotdrop anim
+ player.EndSignal( "OnDestroy" )
+ OnThreadEnd( function() : ( player, titan, camera )
+ {
+ if ( IsValid( player ) )
+ {
+ RemoveCinematicFlag( player, CE_FLAG_HIDE_MAIN_HUD ) // show hud
+ player.isSpawning = false
+ }
+
+ titan.Destroy() // pilotbecomestitan leaves an npc titan that we need to delete
+ camera.Fire( "Disable", "!activator", 0, player )
+ camera.Destroy()
+ })
- camera.Fire( "Disable", "!activator", 0, player ) // stop using the camera
- camera.Destroy()
- RemoveCinematicFlag( player, CE_FLAG_HIDE_MAIN_HUD ) // show hud
- player.DeployWeapon() // let them use weapons again
- player.isSpawning = false
+ waitthread TitanHotDrop( titan, "at_hotdrop_01", spawnpoint.GetOrigin(), spawnpoint.GetAngles(), player, camera ) // do hotdrop anim
player.RespawnPlayer( null ) // spawn player as pilot so they get their pilot loadout on embark
player.SetOrigin( titan.GetOrigin() )
WaitFrame()
PilotBecomesTitan( player, titan ) // make player titan
- titan.Destroy() // pilotbecomestitan leaves an npc titan that we need to delete
}
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/spawn.nut b/Northstar.CustomServers/mod/scripts/vscripts/mp/spawn.nut
index 1766a216d..70d1e5276 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/mp/spawn.nut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/spawn.nut
@@ -139,6 +139,10 @@ entity function FindSpawnPoint( entity player, bool isTitan, bool useStartSpawnp
InitRatings( player, team )
+ // don't think this is necessary since we call discardratings
+ //foreach ( entity spawnpoint in spawnpoints )
+ // spawnpoint.CalculateRating( isTitan ? TD_TITAN : TD_PILOT, team, 0.0, 0.0 )
+
void functionref( int, array<entity>, int, entity ) ratingFunc = isTitan ? GameMode_GetTitanSpawnpointsRatingFunc( GAMETYPE ) : GameMode_GetPilotSpawnpointsRatingFunc( GAMETYPE )
ratingFunc( isTitan ? TD_TITAN : TD_PILOT, spawnpoints, team, player )
@@ -165,7 +169,7 @@ entity function FindSpawnPoint( entity player, bool isTitan, bool useStartSpawnp
spawnpoint.s.lastUsedTime = Time()
player.SetLastSpawnPoint( spawnpoint )
-
+
return spawnpoint
}