]> git.xonotic.org Git - voretournament/voretournament.git/commitdiff
Amplify digestion damage for dead prey
authorMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 31 Jul 2011 18:32:19 +0000 (21:32 +0300)
committerMirceaKitsune <sonichedgehog_hyperblast00@yahoo.com>
Sun, 31 Jul 2011 18:32:19 +0000 (21:32 +0300)
data/balanceVT.cfg
data/qcsrc/server/vore.qc

index 4589e01ab66523a847dd5e6a04f6a12e8fbcb2a3..95fd1446d976561e2894bc0e61cc4ca81b30d3f2 100644 (file)
@@ -210,7 +210,8 @@ set g_balance_vore_regurgitate_predatorforce 450 "players are pushed back by thi
 set g_balance_vore_regurgitate_delay 0.5 "regurgitation delay"\r
 set g_balance_vore_regurgitate_punchangle 12 "your view gets tilted by this amount when regurgitating someone"\r
 set g_balance_vore_digestion_damage 4 "amount of damage applied to victims during digestion"\r
-set g_balance_vore_digestion_limit -25 "prey can be digested down to this amount of health"\r
+set g_balance_vore_digestion_damage_death 2 "amplify digestion damage by this amount when the prey is dead"\r
+set g_balance_vore_digestion_limit -100 "prey can be digested down to this amount of health"\r
 set g_balance_vore_digestion_limit_regurgitate 1 "the predator automatically regurgitates prey that has reached the digestion limit"\r
 set g_balance_vore_digestion_vampire 1 "amount of health you gain from digestion"\r
 set g_balance_vore_digestion_vampire_stable 150 "maximum amount of health you can gain from digestion (best kept equal or less than g_balance_health_rotstable)"\r
index e2919fc9077ddb5cf401e352fca2763778b61c05..27ea63de078585c531f3acabc49fcc8c9eb540de 100644 (file)
@@ -431,20 +431,22 @@ void Vore_Digest()
        if(time > self.digestion_step)\r
        {\r
                // if distributed digestion is enabled, reduce digestion strength by the amount of prey in our stomach\r
-               float vore_offset;\r
-               vore_offset = 1;\r
+               float damage, damage_offset;\r
+\r
+               damage_offset = 1;\r
                if(cvar("g_balance_vore_digestion_distribute")) // apply distributed digestion damage\r
-                       vore_offset *= self.predator.stomach_load / self.predator.stomach_maxload;\r
+                       damage_offset *= self.predator.stomach_load / self.predator.stomach_maxload;\r
                if(cvar("g_healthsize") && cvar("g_balance_vore_digestion_scalediff")) // apply player scale to digestion damage\r
-                       vore_offset *= pow(self.scale / self.predator.scale, cvar("g_balance_vore_digestion_scalediff"));\r
-               vore_offset = ceil(vore_offset);\r
+                       damage_offset *= pow(self.scale / self.predator.scale, cvar("g_balance_vore_digestion_scalediff"));\r
+               damage_offset = ceil(damage_offset);\r
 \r
-               float damage;\r
-               damage = cvar("g_balance_vore_digestion_damage") / vore_offset;\r
+               damage = cvar("g_balance_vore_digestion_damage") / damage_offset;\r
+               if(cvar("g_balance_vore_digestion_damage_death") && self.deadflag != DEAD_NO) // amplify digestion damage for dead prey\r
+                       damage *= cvar("g_balance_vore_digestion_damage_death");\r
 \r
                Damage(self, self.predator, self.predator, damage, DEATH_DIGESTION, self.origin, '0 0 0');\r
                if(cvar("g_balance_vore_digestion_vampire") && self.predator.health < cvar("g_balance_vore_digestion_vampire_stable"))\r
-                       self.predator.health += cvar("g_balance_vore_digestion_vampire") / vore_offset;\r
+                       self.predator.health += damage * cvar("g_balance_vore_digestion_vampire");\r
 \r
                if (self.predator.digestsound_finished < time)\r
                {\r