]> git.rm.cloudns.org Git - voretournament/voretournament.git/commitdiff
Require re-pressing the stomach kick key by default
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 10 Jul 2011 23:53:12 +0000 (02:53 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 10 Jul 2011 23:53:12 +0000 (02:53 +0300)
data/balanceVT.cfg
data/qcsrc/server/vore.qc

index a81ad7e93412ed70b787dd68cdf7a9ab7e2f090d..99cf11b475e439c1f35c1fcf72a5cca980b628eb 100644 (file)
@@ -216,6 +216,7 @@ set g_balance_vore_kick_damage_min 30 "minimum amount of damage you can do with
 set g_balance_vore_kick_damage_max 45 "maximum amount of damage you can do with a stomach kick"\r
 set g_balance_vore_kick_delay 0.6 "how many seconds must pass before you can perform another stomach kick"\r
 set g_balance_vore_kick_force 420 "predators are pushed by this amount when stomach kicked, in the direction their prey is facing"\r
+set g_balance_vore_kick_repress 1 "require pressing the fire key each kick rather than holding it down"\r
 set g_balance_vore_kick_scalediff 1 "if enabled, the damage / force of stomach kicks is affected by the size of the prey compared to the size of the predator"\r
 set g_balance_vore_kick_predator_punchangle 6 "your view gets tilted by this amount when receiving stomach kicks"\r
 set g_balance_vore_kick_prey_punchangle 6 "your view gets tilted by this amount when dealing stomach kicks"\r
index 9a3d94124fd76037b5dc387b1882b1cae3d3351c..531f95d0b010784d7d112bf6f6eec44c07bc4979 100644 (file)
@@ -518,11 +518,12 @@ void Vore_Teamheal()
        }\r
 }\r
 \r
+.float kick_pressed;\r
 void Vore_StomachKick()\r
 {\r
        // allows prey to kick the predator's stomach and do some damage or attempt to escape\r
 \r
-       if(time > self.stomachkick_delay)\r
+       if(time > self.stomachkick_delay && !self.kick_pressed)\r
        {\r
                float damage;\r
                vector force;\r
@@ -546,6 +547,8 @@ void Vore_StomachKick()
                        self.predator.regurgitate_prepare = 0;\r
 \r
                self.stomachkick_delay = time + cvar("g_balance_vore_kick_delay");\r
+               if(cvar("g_balance_vore_kick_repress"))\r
+                       self.kick_pressed = TRUE;\r
        }\r
 }\r
 \r
@@ -847,8 +850,13 @@ void Vore()
                Vore_Teamheal();\r
 \r
        // execute prey commands\r
-       if(self.BUTTON_ATCK && cvar("g_vore_kick"))\r
-               Vore_StomachKick();\r
+       if(self.BUTTON_ATCK)\r
+       {\r
+               if(cvar("g_vore_kick"))\r
+                       Vore_StomachKick();\r
+       }\r
+       else\r
+               self.kick_pressed = FALSE;\r
        if(self.BUTTON_JUMP)\r
                Vore_StomachLeave();\r
 \r