Make jump pads account the scale gravity of players, so macros can reach their destin...
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Mon, 19 Mar 2012 12:26:03 +0000 (14:26 +0200)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Mon, 19 Mar 2012 12:26:03 +0000 (14:26 +0200)
data/qcsrc/server/t_jumppads.qc
docs/Release notes.txt
docs/TODO.txt

index 906e63d..b875c21 100644 (file)
@@ -121,8 +121,12 @@ vector trigger_push_calculatevelocity(vector org, entity tgt, float ht)
        }\r
        vs = sdist / trigger_push_calculatevelocity_flighttime;\r
 \r
+       // apply size-based weight to jump pads\r
+       float scalefac;\r
+       scalefac = (cvar("g_healthsize") && other.classname == "player") ? pow(other.scale, cvar("g_healthsize_weight") * 0.5) : 1;\r
+\r
        // finally calculate the velocity\r
-       return sdir * vs + '0 0 1' * vz;\r
+       return sdir * vs + '0 0 1' * vz * scalefac;\r
 }\r
 \r
 void trigger_push_touch()\r
index 26cdc9c..bc3457e 100644 (file)
@@ -344,4 +344,6 @@ Bug fixes:
 \r
 Features:\r
 \r
+- ?\r
+\r
 Known bugs:\r
index dd4d822..8632a53 100644 (file)
 \r
 - +0.8: Some sort of bullet time feature in single player, by setting the slowmo cvar\r
 \r
+- 0.8: Does the wind trigger brush need to account scale based gravity?\r
+\r
 - 0.8: Make some g_healthsize cvars g_balance_healthsize, and move them to balanceVT.cfg\r
 \r
 - 0.8: Make player fatness depend on frags, using a trick I heard about with shaders\r