From: Lyberta Date: Fri, 1 Dec 2017 06:23:45 +0000 (+0300) Subject: target_give now uses new classnames. X-Git-Tag: xonotic-v0.8.5~2418^2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c47eca442cbc3f383fa220473159cd40fcb2e4ba;p=xonotic%2Fxonotic-data.pk3dir.git target_give now uses new classnames. --- diff --git a/qcsrc/server/compat/quake3.qc b/qcsrc/server/compat/quake3.qc index a85f4cca6..6a7f21aa6 100644 --- a/qcsrc/server/compat/quake3.qc +++ b/qcsrc/server/compat/quake3.qc @@ -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; diff --git a/qcsrc/server/weapons/spawning.qc b/qcsrc/server/weapons/spawning.qc index d33fdaac0..d47351cb3 100644 --- a/qcsrc/server/weapons/spawning.qc +++ b/qcsrc/server/weapons/spawning.qc @@ -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)