]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
make shield reduce force as well (unless selfpush)
authorMartin Taibr <taibr.martin@gmail.com>
Mon, 5 Feb 2018 02:14:11 +0000 (03:14 +0100)
committerMartin Taibr <taibr.martin@gmail.com>
Mon, 5 Feb 2018 02:14:11 +0000 (03:14 +0100)
balance-mario.cfg
balance-nexuiz25.cfg
balance-overkill.cfg
balance-samual.cfg
balance-xdf.cfg
balance-xonotic.cfg
balance-xpm.cfg
qcsrc/server/autocvars.qh
qcsrc/server/g_damage.qc

index 28100182ea5fe41b0b1d028b020a93503228c9f5..830270043f96ad512774435973ef5c2e5b642c2d 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.33 // only 1/3rd damage is taken
+set g_balance_powerup_invincible_takeforce 1
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 37099c1226dfa6ff992a97b74ef1217b91111b31..f11edbfa8f9d75fb359027b9a45c44d85bed3c9b 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.2
+set g_balance_powerup_invincible_takeforce 1
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 4
index 3a321ce53d461b2eca19452f5ad420975f9f2c12..cb15afb2f29919a238bad8c7a1552d8b37c6535d 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.33 // only 1/3rd damage is taken
+set g_balance_powerup_invincible_takeforce 0.33
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 48c68d81be66e77c96cf8f55c417fd4b8565fe0f..d5ba21361119a0d7f3e11f4666138c26c9444dec 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.25 // only 1/4th damage is taken
+set g_balance_powerup_invincible_takeforce 1
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 562506283c44ad965d5d7d0f641a96a910aa11d3..2b123ff89463fe972055b05f7aaa012938a12d9d 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.33 // only 1/3rd damage is taken
+set g_balance_powerup_invincible_takeforce 0.33
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 32924a72d2cee7cca9d636330661abe49047f404..90734fdde5586bfac0dd07a2021c4453b2f68552 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.33 // only 1/3rd damage is taken
+set g_balance_powerup_invincible_takeforce 0.33
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 6901eda28a8c130622dc43db632f7475965050d3..b9fa6f6a7a3286ff3a618a36733aff6f5df680f8 100644 (file)
@@ -198,6 +198,7 @@ set g_maxpushtime 8.0 "timeout for kill credit when your damage knocks someone i
 
 // {{{ powerups
 set g_balance_powerup_invincible_takedamage 0.33 // only 1/3rd damage is taken
+set g_balance_powerup_invincible_takeforce 0.33
 set g_balance_powerup_invincible_time 30
 set g_balance_powerup_strength_damage 3
 set g_balance_powerup_strength_force 3
index 80da3f403ac97c025274b109d1ede8f5c8c8ea83..61fd12fbfedbfd2a1c0171867dca91969d01316a 100644 (file)
@@ -79,6 +79,7 @@ float autocvar_g_balance_pause_health_rot_spawn;
 float autocvar_g_balance_portal_health;
 float autocvar_g_balance_portal_lifetime;
 float autocvar_g_balance_powerup_invincible_takedamage;
+float autocvar_g_balance_powerup_invincible_takeforce;
 //float autocvar_g_balance_powerup_invincible_time;
 float autocvar_g_balance_powerup_strength_damage;
 float autocvar_g_balance_powerup_strength_force;
index 029660c2bf05c2e98975f609e8c35d943d4f168d..75bf81f8a6c99ecc6ccea2b61dd767d2085e30a4 100644 (file)
@@ -800,7 +800,13 @@ void Damage (entity targ, entity inflictor, entity attacker, float damage, int d
 
                        // apply invincibility multiplier
                        if (targ.items & ITEM_Shield.m_itemid)
+                       {
                                damage = damage * autocvar_g_balance_powerup_invincible_takedamage;
+                               if (targ != attacker)
+                               {
+                                       force = force * autocvar_g_balance_powerup_invincible_takeforce;
+                               }
+                       }
                }
 
                if (targ == attacker)