From 976d62fccf654ce327b44980eea901e85badb051 Mon Sep 17 00:00:00 2001 From: Agiel Date: Tue, 9 Jul 2024 23:19:20 +0200 Subject: [PATCH] Change damage modifiers to parity. (#488) --- mp/game/neo/cfg/skill.cfg | 8 ++++---- mp/src/game/server/player.cpp | 8 ++++++++ mp/src/game/shared/neo/neo_gamerules.cpp | 16 ++++++++-------- mp/src/game/shared/neo/neo_player_shared.h | 7 ++++--- 4 files changed, 24 insertions(+), 15 deletions(-) diff --git a/mp/game/neo/cfg/skill.cfg b/mp/game/neo/cfg/skill.cfg index 8a48ca673..659e9eee4 100644 --- a/mp/game/neo/cfg/skill.cfg +++ b/mp/game/neo/cfg/skill.cfg @@ -8,8 +8,8 @@ sk_healthkit "25" sk_healthvial "10" // player damage adjusters -sk_player_head "3" +sk_player_head "1" sk_player_chest "1" -sk_player_stomach "1" -sk_player_arm "1" -sk_player_leg "1" \ No newline at end of file +sk_player_stomach "0.75" +sk_player_arm "0.75" +sk_player_leg "0.6" diff --git a/mp/src/game/server/player.cpp b/mp/src/game/server/player.cpp index 0675e66b4..55c6634b4 100644 --- a/mp/src/game/server/player.cpp +++ b/mp/src/game/server/player.cpp @@ -183,11 +183,19 @@ extern void AddMultiDamage( const CTakeDamageInfo &info, CBaseEntity *pEntity ); //#define MAX_SAFE_FALL_UNITS ( PLAYER_MAX_SAFE_FALL_DIST * 12 ) // player damage adjusters +#ifdef NEO +ConVar sk_player_head( "sk_player_head","1" ); +ConVar sk_player_chest( "sk_player_chest","1" ); +ConVar sk_player_stomach( "sk_player_stomach","0.75" ); +ConVar sk_player_arm( "sk_player_arm","0.75" ); +ConVar sk_player_leg( "sk_player_leg","0.6" ); +#else ConVar sk_player_head( "sk_player_head","2" ); ConVar sk_player_chest( "sk_player_chest","1" ); ConVar sk_player_stomach( "sk_player_stomach","1" ); ConVar sk_player_arm( "sk_player_arm","1" ); ConVar sk_player_leg( "sk_player_leg","1" ); +#endif //ConVar player_usercommand_timeout( "player_usercommand_timeout", "10", 0, "After this many seconds without a usercommand from a player, the client is kicked." ); #ifdef _DEBUG diff --git a/mp/src/game/shared/neo/neo_gamerules.cpp b/mp/src/game/shared/neo/neo_gamerules.cpp index 976407e95..a1909521d 100644 --- a/mp/src/game/shared/neo/neo_gamerules.cpp +++ b/mp/src/game/shared/neo/neo_gamerules.cpp @@ -30,7 +30,7 @@ ConVar mp_neo_warmup_round_time("mp_neo_warmup_round_time", "45", FCVAR_REPLICAT ConVar mp_neo_preround_freeze_time("mp_neo_preround_freeze_time", "10", FCVAR_REPLICATED, "The pre-round freeze time, in seconds.", true, 0.0, false, 0); ConVar mp_neo_latespawn_max_time("mp_neo_latespawn_max_time", "15", FCVAR_REPLICATED, "How many seconds late are players still allowed to spawn.", true, 0.0, false, 0); -ConVar sv_neo_wep_dmg_modifier("sv_neo_wep_dmg_modifier", "0.5", FCVAR_REPLICATED, "Temp global weapon damage modifier.", true, 0.0, true, 100.0); +ConVar sv_neo_wep_dmg_modifier("sv_neo_wep_dmg_modifier", "1", FCVAR_REPLICATED, "Temp global weapon damage modifier.", true, 0.0, true, 100.0); ConVar neo_sv_player_restore("neo_sv_player_restore", "1", FCVAR_REPLICATED, "If enabled, the server will save players XP and deaths per match session and restore them if they reconnect.", true, 0.0f, true, 1.0f); ConVar neo_name("neo_name", "", FCVAR_USERINFO | FCVAR_ARCHIVE, "The nickname to set instead of the steam profile name."); @@ -66,17 +66,17 @@ extern bool RespawnWithRet(CBaseEntity *pEdict, bool fCopyCorpse); // NEO TODO (Rain): check against a test map static NEOViewVectors g_NEOViewVectors( Vector( 0, 0, 58 ), //VEC_VIEW (m_vView) // 57 == vanilla recon, 58 == vanilla assault (default), 60 == vanilla support. Use the shareddefs.h macro VEC_VIEW_NEOSCALE to access per player. - + Vector(-16, -16, 0 ), //VEC_HULL_MIN (m_vHullMin) Vector(16, 16, NEO_ASSAULT_PLAYERMODEL_HEIGHT), //VEC_HULL_MAX (m_vHullMax). 66 == vanilla recon, 67 == vanilla assault (default), 72 == vanilla support. Use relevant VEC_... macros in shareddefs for class height adjusted per player access. - + Vector(-16, -16, 0 ), //VEC_DUCK_HULL_MIN (m_vDuckHullMin) Vector( 16, 16, NEO_ASSAULT_PLAYERMODEL_DUCK_HEIGHT), //VEC_DUCK_HULL_MAX (m_vDuckHullMax) Vector( 0, 0, 45 ), //VEC_DUCK_VIEW (m_vDuckView) - + Vector(-10, -10, -10 ), //VEC_OBS_HULL_MIN (m_vObsHullMin) Vector( 10, 10, 10 ), //VEC_OBS_HULL_MAX (m_vObsHullMax) - + Vector( 0, 0, 14 ), //VEC_DEAD_VIEWHEIGHT (m_vDeadViewHeight) Vector(-16, -16, 0 ), //VEC_CROUCH_TRACE_MIN (m_vCrouchTraceMin) @@ -823,7 +823,7 @@ static inline void SpawnTheGhost() { ghost->SetAbsOrigin(ghostSpawn->GetAbsOrigin()); } - + break; } } @@ -1128,7 +1128,7 @@ void CNEORules::CleanUpMap() { if (m_iIterator == g_MapEntityRefs.InvalidIndex()) { - // This shouldn't be possible. When we loaded the map, it should have used + // This shouldn't be possible. When we loaded the map, it should have used // CCSMapLoadEntityFilter, which should have built the g_MapEntityRefs list // with the same list of entities we're referring to here. Assert(false); @@ -1147,7 +1147,7 @@ void CNEORules::CleanUpMap() } else { - // Cool, the slot where this entity was is free again (most likely, the entity was + // Cool, the slot where this entity was is free again (most likely, the entity was // freed above). Now create an entity with this specific index. return CreateEntityByName(pClassname, ref.m_iEdict); } diff --git a/mp/src/game/shared/neo/neo_player_shared.h b/mp/src/game/shared/neo/neo_player_shared.h index 4c7ac68fd..5e09eb658 100644 --- a/mp/src/game/shared/neo/neo_player_shared.h +++ b/mp/src/game/shared/neo/neo_player_shared.h @@ -151,9 +151,10 @@ COMPILE_TIME_ASSERT(NEO_ASSAULT_CROUCH_SPEED == NEO_SUPPORT_CROUCH_SPEED); #define NEO_ASSAULT_MODEL_SCALE ((NEO_ASSAULT_PLAYERMODEL_HEIGHT / HL2DM_DEFAULT_PLAYERMODEL_HEIGHT) * NEO_HULL_TOLERANCE_SCALE) #define NEO_SUPPORT_MODEL_SCALE ((NEO_SUPPORT_PLAYERMODEL_HEIGHT / HL2DM_DEFAULT_PLAYERMODEL_HEIGHT) * NEO_HULL_TOLERANCE_SCALE) -#define NEO_RECON_DAMAGE_MODIFIER 1.2f -#define NEO_ASSAULT_DAMAGE_MODIFIER 1.0f -#define NEO_SUPPORT_DAMAGE_MODIFIER 0.56f +// These look like magic but are actually taken straight from the og binaries. +#define NEO_RECON_DAMAGE_MODIFIER 1.485f +#define NEO_ASSAULT_DAMAGE_MODIFIER 1.2375f +#define NEO_SUPPORT_DAMAGE_MODIFIER 0.66f #define NEO_ANIMSTATE_LEGANIM_TYPE LegAnimType_t::LEGANIM_9WAY #define NEO_ANIMSTATE_USES_AIMSEQUENCES true