]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make corpses sink slowly in slime and lava
authorMario <mario@smbclan.net>
Sat, 4 Mar 2017 17:59:30 +0000 (03:59 +1000)
committerMario <mario@smbclan.net>
Sat, 4 Mar 2017 17:59:30 +0000 (03:59 +1000)
qcsrc/ecs/systems/physics.qc

index 0c18e58cf8a577335f67526aae0412c52534ad73..db59359b31abd8a22c08a5bb28f143be94356e1d 100644 (file)
@@ -52,7 +52,8 @@ void sys_phys_update(entity this, float dt)
        if (IS_DEAD(this)) {
                // handle water here
                vector midpoint = ((this.absmin + this.absmax) * 0.5);
-               if (pointcontents(midpoint) == CONTENT_WATER) {
+               int cont = pointcontents(midpoint);
+               if (cont == CONTENT_WATER || cont == CONTENT_LAVA || cont == CONTENT_SLIME) {
                        this.velocity = this.velocity * 0.5;
 
                        // do we want this?