From 7124ce1005b130e1967f00c0292f71f1db835eda Mon Sep 17 00:00:00 2001 From: Marco Hladik Date: Wed, 24 Mar 2021 07:54:14 +0100 Subject: [PATCH] monster_scientist: Force health reset on health and base_health... that's a bug. We need to backtrace that some time. --- src/server/monster_scientist.qc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/server/monster_scientist.qc b/src/server/monster_scientist.qc index dcf9785..9d9eb39 100644 --- a/src/server/monster_scientist.qc +++ b/src/server/monster_scientist.qc @@ -257,6 +257,8 @@ monster_scientist::Respawn(void) CBaseNPC::Respawn(); m_iFlags |= MONSTER_CANFOLLOW; PlayerUse = OnPlayerUse; + health = base_health = Skill_GetValue("scientist_health", 20); + takedamage = DAMAGE_YES; if (autocvar_sh_scialert) { m_iFlags |= MONSTER_FEAR; @@ -307,9 +309,9 @@ monster_scientist::monster_scientist(void) model = "models/scientist.mdl"; base_mins = [-16,-16,0]; base_maxs = [16,16,72]; + base_health = Skill_GetValue("scientist_health", 20); CBaseNPC::CBaseNPC(); precache_model(m_oldModel); - base_health = Skill_GetValue("scientist_health", 20); if (m_iBody == -1) { /* This stuff needs to be persistent because we can't guarantee that