From def78f91a30d41ff060b2d3d7c77d2677924c1e0 Mon Sep 17 00:00:00 2001 From: Marco Hladik Date: Tue, 5 Apr 2022 20:37:30 -0700 Subject: [PATCH] Extend FX_GibHuman with a dir (euler) and force parameter. --- src/client/game_event.qc | 7 ++++++- src/server/gamerules.qc | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/client/game_event.qc b/src/client/game_event.qc index d7476b1..8ae1dec 100644 --- a/src/client/game_event.qc +++ b/src/client/game_event.qc @@ -36,7 +36,12 @@ ClientGame_EventParse(float fHeader) vGibPos[0] = readcoord(); vGibPos[1] = readcoord(); vGibPos[2] = readcoord(); - FX_GibHuman(vGibPos); + vector vDir; + vDir[0] = readcoord(); + vDir[1] = readcoord(); + vDir[2] = readcoord(); + float flForce = readfloat(); + FX_GibHuman(vGibPos, vDir, flForce); break; case EV_BLOOD: vector vBloodPos; diff --git a/src/server/gamerules.qc b/src/server/gamerules.qc index bdfea3a..8e56ac9 100644 --- a/src/server/gamerules.qc +++ b/src/server/gamerules.qc @@ -57,7 +57,7 @@ HHDMultiplayerRules::PlayerDeath(base_player pl) if (pl.health < -50) { pl.health = 0; - FX_GibHuman(pl.origin); + FX_GibHuman(pl.origin, vectoangles(pl.origin - g_dmg_eAttacker.origin), g_dmg_iDamage * 2.0f); return; }