]> de.git.xonotic.org Git - voretournament/voretournament.git/blobdiff - data/qcsrc/server/g_violence.qc
Properly calculate falling damage based on player scale. Don't just offset the damage...
[voretournament/voretournament.git] / data / qcsrc / server / g_violence.qc
index 5665ff4365a374dee3a31774076e7d2739e6cee5..0fce11eab2c9f140ca49b062004613c736c2814f 100644 (file)
@@ -6,7 +6,8 @@ float Violence_GibSplash_SendEntity(entity to, float sf)
        WriteShort(MSG_ENTITY, floor(self.origin_x / 4)); // not using a coord here, as gibs don't need this accuracy\r
        WriteShort(MSG_ENTITY, floor(self.origin_y / 4)); // not using a coord here, as gibs don't need this accuracy\r
        WriteShort(MSG_ENTITY, floor(self.origin_z / 4)); // not using a coord here, as gibs don't need this accuracy\r
-       WriteShort(MSG_ENTITY, self.oldorigin_x); // acrually compressed velocity\r
+       WriteShort(MSG_ENTITY, self.oldorigin_x); // actually compressed velocity\r
+       WriteCoord(MSG_ENTITY, self.scale); // size of the gibs\r
        return TRUE;\r
 }\r
 \r
@@ -29,6 +30,7 @@ void Violence_GibSplash_At(vector org, vector dir, float type, float amount, ent
        e.state |= 8 * self.species; // gib type, ranges from 0 to 15\r
        setorigin(e, org);\r
        e.velocity = dir;\r
+       e.scale = gibowner.scale;\r
 \r
        e.oldorigin_x = compressShortVector(e.velocity);\r
 \r