]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add support for target_relay and weapon_railgun in target_give
authorMario <mario@smbclan.net>
Sun, 5 Nov 2017 15:28:02 +0000 (01:28 +1000)
committerMario <mario@smbclan.net>
Sun, 5 Nov 2017 15:28:02 +0000 (01:28 +1000)
qcsrc/common/triggers/trigger/relay.qc
qcsrc/server/compat/quake3.qc

index 794f4dc112d017a4e9759dbe84095d628662602e..a82034edcf017d5abad297540444f5111f62110d 100644 (file)
@@ -8,4 +8,6 @@ spawnfunc(trigger_relay)
        this.use = SUB_UseTargets;
        this.reset = spawnfunc_trigger_relay; // this spawnfunc resets fully
 }
+
+spawnfunc(target_relay) { spawnfunc_trigger_relay(this); }
 #endif
index 2e2301d0bdec150704ae2b6f297beddbda5870a2..d6c7bbb2e7f3662492d337e6da2e7798027d2714 100644 (file)
@@ -120,6 +120,10 @@ void target_give_init(entity this)
                        this.ammo_rockets += it.count * WEP_CVAR(devastator, ammo);
                        this.netname = cons(this.netname, "devastator");
                }
+               else if (it.classname == "weapon_railgun") {
+                       this.ammo_cells += it.count * WEP_CVAR_PRI(vortex, ammo); // WEAPONTODO
+                       this.netname = cons(this.netname, "vortex");
+               }
                else if (it.classname == "weapon_lightning") {
                        this.ammo_cells += it.count * WEP_CVAR_PRI(electro, ammo); // WEAPONTODO
                        this.netname = cons(this.netname, "electro");