]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Survival: Added plasma and fuel rewards.
authorLyberta <lyberta@lyberta.net>
Mon, 28 Aug 2017 06:51:03 +0000 (09:51 +0300)
committerLyberta <lyberta@lyberta.net>
Mon, 28 Aug 2017 06:51:03 +0000 (09:51 +0300)
qcsrc/server/mutators/mutator/gamemode_survival.qc
survival.cfg

index c206dafa3bfd4f0fbe63f350d9f64fc5468d8033..34ba7cdba1ef6df40dd6e1471a368c1d91adfb9c 100644 (file)
@@ -91,6 +91,10 @@ int autocvar_g_surv_defender_attacker_frag_bullets;
 int autocvar_g_surv_defender_attacker_frag_rockets;
 /// \brief How many cells do defenders get when they frag an attacker.
 int autocvar_g_surv_defender_attacker_frag_cells;
+/// \brief How much plasma do defenders get when they frag an attacker.
+int autocvar_g_surv_defender_attacker_frag_plasma;
+/// \brief How much fuel do defenders get when they frag an attacker.
+int autocvar_g_surv_defender_attacker_frag_fuel;
 /// \brief How much health do defenders get when they frag cannon fodder.
 int autocvar_g_surv_defender_cannon_fodder_frag_health;
 /// \brief How much armor do defenders get when they frag cannon fodder.
@@ -103,6 +107,10 @@ int autocvar_g_surv_defender_cannon_fodder_frag_bullets;
 int autocvar_g_surv_defender_cannon_fodder_frag_rockets;
 /// \brief How many cells do defenders get when they frag cannon fodder.
 int autocvar_g_surv_defender_cannon_fodder_frag_cells;
+/// \brief How much plasma do defenders get when they frag cannon fodder.
+int autocvar_g_surv_defender_cannon_fodder_frag_plasma;
+/// \brief How much fuel do defenders get when they frag cannon fodder.
+int autocvar_g_surv_defender_cannon_fodder_frag_fuel;
 
 /// \brief A stat that is used to track the time left in the round.
 .float surv_round_time_stat = _STAT(SURV_ROUND_TIME);
@@ -2063,6 +2071,10 @@ MUTATOR_HOOKFUNCTION(surv, PlayerDies, CBC_ORDER_FIRST)
                                        autocvar_g_surv_defender_attacker_frag_rockets);
                                GiveResource(attacker, RESOURCE_CELLS,
                                        autocvar_g_surv_defender_attacker_frag_cells);
+                               GiveResource(attacker, RESOURCE_PLASMA,
+                                       autocvar_g_surv_defender_attacker_frag_plasma);
+                               GiveResource(attacker, RESOURCE_FUEL,
+                                       autocvar_g_surv_defender_attacker_frag_fuel);
                                break;
                        }
                        case SURVIVAL_ROLE_CANNON_FODDER:
@@ -2079,6 +2091,10 @@ MUTATOR_HOOKFUNCTION(surv, PlayerDies, CBC_ORDER_FIRST)
                                        autocvar_g_surv_defender_cannon_fodder_frag_rockets);
                                GiveResource(attacker, RESOURCE_CELLS,
                                        autocvar_g_surv_defender_cannon_fodder_frag_cells);
+                               GiveResource(attacker, RESOURCE_PLASMA,
+                                       autocvar_g_surv_defender_cannon_fodder_frag_plasma);
+                               GiveResource(attacker, RESOURCE_FUEL,
+                                       autocvar_g_surv_defender_cannon_fodder_frag_fuel);
                                break;
                        }
                }
index 1b0fd9237e14d2b3798bd71b56a56f2412babab5..b98f2cc749462253ec65aa38bb065961c38cbece 100644 (file)
@@ -115,9 +115,13 @@ set g_surv_defender_attacker_frag_shells 0 "How many shells do defenders get whe
 set g_surv_defender_attacker_frag_bullets 0 "How many bullets do defenders get when they frag an attacker"
 set g_surv_defender_attacker_frag_rockets 0 "How many rockets do defenders get when they frag an attacker"
 set g_surv_defender_attacker_frag_cells 0 "How many cells do defenders get when they frag an attacker"
+set g_surv_defender_attacker_frag_plasma 0 "How much plasma do defenders get when they frag an attacker"
+set g_surv_defender_attacker_frag_fuel 0 "How much fuel do defenders get when they frag an attacker"
 set g_surv_defender_cannon_fodder_frag_health 0 "How much health do defenders get when they frag cannon fodder"
 set g_surv_defender_cannon_fodder_frag_armor 0 "How much armor do defenders get when they frag cannon fodder"
 set g_surv_defender_cannon_fodder_frag_shells 0 "How many shells do defenders get when they frag cannon fodder"
 set g_surv_defender_cannon_fodder_frag_bullets 0 "How many bullets do defenders get when they frag cannon fodder"
 set g_surv_defender_cannon_fodder_frag_rockets 0 "How many rockets do defenders get when they frag cannon fodder"
 set g_surv_defender_cannon_fodder_frag_cells 0 "How many cells do defenders get when they frag cannon fodder"
+set g_surv_defender_cannon_fodder_frag_plasma 0 "How much plasma do defenders get when they frag cannon fodder"
+set g_surv_defender_cannon_fodder_frag_fuel 0 "How much fuel do defenders get when they frag cannon fodder"