]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mutators/mutator/damagetext/sv_damagetext.qc
Merged master.
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mutators / mutator / damagetext / sv_damagetext.qc
index 770b1c078ec2063eeb74ccc6a711bba93ab04fce..8daf920307d96c3d533e6b0586f699b3d6a46fed 100644 (file)
@@ -16,7 +16,6 @@ MUTATOR_HOOKFUNCTION(damagetext, PlayerDamaged) {
     const float armor = M_ARGV(3, float);
     const int deathtype = M_ARGV(5, int);
     const float potential_damage = M_ARGV(6, float);
-    const vector location = hit.origin;
     FOREACH_CLIENT(IS_REAL_CLIENT(it), LAMBDA(
         if (
             (SV_DAMAGETEXT_ALL()) ||
@@ -34,10 +33,7 @@ MUTATOR_HOOKFUNCTION(damagetext, PlayerDamaged) {
 
             msg_entity = it;
             WriteHeader(MSG_ONE, damagetext);
-            WriteEntity(MSG_ONE, hit);
-            WriteCoord(MSG_ONE, location.x);
-            WriteCoord(MSG_ONE, location.y);
-            WriteCoord(MSG_ONE, location.z);
+            WriteByte(MSG_ONE, etof(hit));
             WriteInt24_t(MSG_ONE, deathtype);
             WriteByte(MSG_ONE, flags);