]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
target_give now uses new classnames. 508/head
authorLyberta <lyberta@lyberta.net>
Fri, 1 Dec 2017 06:23:45 +0000 (09:23 +0300)
committerLyberta <lyberta@lyberta.net>
Fri, 1 Dec 2017 06:23:45 +0000 (09:23 +0300)
qcsrc/server/compat/quake3.qc
qcsrc/server/weapons/spawning.qc

index a85f4cca6429d8a84af6f287d50366009832aedc..6a7f21aa674d319bad7ece6abeb908b28b764d60 100644 (file)
@@ -95,31 +95,31 @@ void target_give_init(entity this)
 {
        IL_EACH(g_items, it.targetname == this.target,
        {
-               if (it.classname == "weapon_rocketlauncher" || it.classname == "weapon_devastator") {
+               if (it.classname == "weapon_devastator") {
                        this.ammo_rockets += it.count * WEP_CVAR(devastator, ammo);
                        this.netname = cons(this.netname, "devastator");
                }
-               else if (it.classname == "weapon_railgun") {
+               else if (it.classname == "weapon_vortex") {
                        this.ammo_cells += it.count * WEP_CVAR_PRI(vortex, ammo); // WEAPONTODO
                        this.netname = cons(this.netname, "vortex");
                }
-               else if (it.classname == "weapon_lightning") {
+               else if (it.classname == "weapon_electro") {
                        this.ammo_cells += it.count * WEP_CVAR_PRI(electro, ammo); // WEAPONTODO
                        this.netname = cons(this.netname, "electro");
                }
-               else if (it.classname == "weapon_plasmagun") {
+               else if (it.classname == "weapon_hagar") {
                        this.ammo_rockets += it.count * WEP_CVAR_PRI(hagar, ammo); // WEAPONTODO
                        this.netname = cons(this.netname, "hagar");
                }
-               else if (it.classname == "weapon_bfg") {
+               else if (it.classname == "weapon_crylink") {
                        this.ammo_cells += it.count * WEP_CVAR_PRI(crylink, ammo);
                        this.netname = cons(this.netname, "crylink");
                }
-               else if (it.classname == "weapon_grenadelauncher" || it.classname == "weapon_mortar") {
+               else if (it.classname == "weapon_mortar") {
                        this.ammo_rockets += it.count * WEP_CVAR_PRI(mortar, ammo); // WEAPONTODO
                        this.netname = cons(this.netname, "mortar");
                }
-               else if (it.classname == "item_armor_body")
+               else if (it.classname == "item_armor_mega")
                        this.armorvalue = 100;
                else if (it.classname == "item_health_mega")
                        this.health = 200;
index d33fdaac0d0a4c6592d6935056e3c117686a4d69..d47351cb37a727aab87f100d2ccb61ddd98a5824 100644 (file)
@@ -30,7 +30,7 @@ void weapon_defaultspawnfunc(entity this, Weapon e)
 {
        Weapon wpn = e;
        e = wpn = wpn.m_spawnfunc_hookreplace(wpn, this);
-       //this.classname = wpn.m_canonical_spawnfunc;
+       this.classname = wpn.m_canonical_spawnfunc;
        if (!Item_IsLoot(this) && !this.m_isreplaced)
        {
                if (e.spawnflags & WEP_FLAG_MUTATORBLOCKED)