From bd9cfac5499a76b0a952af2363110e3db44b3178 Mon Sep 17 00:00:00 2001 From: Coopyy Date: Mon, 17 Jan 2022 14:38:27 -0600 Subject: Added Sticks & Stones Configuration as Playlist Vars (#115) * added mode config options in menu --- .../mod/scripts/vscripts/gamemodes/_gamemode_sns.gnut | 17 ++++++++++++----- .../mod/scripts/vscripts/gamemodes/sh_gamemode_sns.gnut | 6 ++++++ 2 files changed, 18 insertions(+), 5 deletions(-) (limited to 'Northstar.Custom/mod') diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_sns.gnut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_sns.gnut index f3b7d2eee..98bb06b90 100644 --- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_sns.gnut +++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/_gamemode_sns.gnut @@ -4,17 +4,18 @@ struct { string score_leader_highlight = "enemy_boss_bounty" // highlight effect applied to person in 1st place string offhand_weapon = "mp_weapon_thermite_grenade" // offhand weapon - bool reset_pulse_blade_cooldown_on_pulse_blade_kill = true + bool reset_pulse_blade_cooldown_on_pulse_blade_kill - int wme_kill_value = 10 - int offhand_kill_value = 10 - int reset_kill_value = 5 - int melee_kill_value = 5 + int wme_kill_value + int offhand_kill_value + int reset_kill_value + int melee_kill_value } file void function SNS_Init() { + SetSpawnpointGamemodeOverride( FFA ) SetShouldUseRoundWinningKillReplay( true ) ClassicMP_ForceDisableEpilogue( true ) SetLoadoutGracePeriodEnabled( false ) // prevent modifying loadouts with grace period @@ -25,6 +26,12 @@ void function SNS_Init() AddCallback_OnPlayerKilled( OnPlayerKilled ) AddCallback_OnPlayerRespawned( OnPlayerRespawned ) AddCallback_GameStateEnter( eGameState.WinnerDetermined, OnWinnerDetermined ) + + file.reset_pulse_blade_cooldown_on_pulse_blade_kill = GetCurrentPlaylistVarInt( "reset_pulse_blade_cooldown_on_pulse_blade_kill", 1 ) == 1 + file.wme_kill_value = GetCurrentPlaylistVarInt( "wme_kill_value", 10 ) + file.offhand_kill_value = GetCurrentPlaylistVarInt( "offhand_kill_value", 10 ) + file.reset_kill_value = GetCurrentPlaylistVarInt( "reset_kill_value", 5 ) + file.melee_kill_value = GetCurrentPlaylistVarInt( "melee_kill_value", 5 ) } void function OnPlayerKilled( entity victim, entity attacker, var damageInfo ) diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_sns.gnut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_sns.gnut index b3d2c2da3..e0f26b94e 100644 --- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_sns.gnut +++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/sh_gamemode_sns.gnut @@ -24,6 +24,12 @@ void function CreateGamemodeSNS() AddPrivateMatchMode( GAMEMODE_SNS ) // add to private lobby modes + AddPrivateMatchModeSettingArbitrary( "#PL_sns", "wme_kill_value", "10" ) + AddPrivateMatchModeSettingArbitrary( "#PL_sns", "offhand_kill_value", "10" ) + AddPrivateMatchModeSettingArbitrary( "#PL_sns", "reset_kill_value", "5" ) + AddPrivateMatchModeSettingArbitrary( "#PL_sns", "melee_kill_value", "5" ) + AddPrivateMatchModeSettingEnum( "#PL_sns", "reset_pulse_blade_cooldown_on_pulse_blade_kill", [ "Disabled", "Enabled" ], "1" ) + GameMode_SetDefaultScoreLimits( GAMEMODE_SNS, 300, 0 ) #if SERVER -- cgit v1.2.3