X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fweapons%2Fspawning.qc;h=b493409b0296ebc8f122b473cecf8044b56b9d0a;hb=926c661916abe4e27456dd977025fe4c56042626;hp=579e6fdff74ea6793a760cebb27b43ced7940e72;hpb=42e255d014f2c6a1871177ea511f630624cdfb57;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/weapons/spawning.qc b/qcsrc/server/weapons/spawning.qc index 579e6fdff..b493409b0 100644 --- a/qcsrc/server/weapons/spawning.qc +++ b/qcsrc/server/weapons/spawning.qc @@ -1,9 +1,9 @@ #include "spawning.qh" #include "weaponsystem.qh" -#include "../mutators/all.qh" +#include "../mutators/_mod.qh" #include -#include +#include string W_Apply_Weaponreplace(string in) { @@ -29,17 +29,17 @@ void weapon_defaultspawnfunc(entity this, Weapon e) { if (e.spawnflags & WEP_FLAG_MUTATORBLOCKED) { - LOG_MAPWARNF("Attempted to spawn a mutator-blocked weapon rejected: prvm_edict server %i", this); + LOG_WARNF("Attempted to spawn a mutator-blocked weapon rejected: prvm_edict server %i", this); startitem_failed = true; return; } string s = W_Apply_Weaponreplace(e.netname); MUTATOR_CALLHOOK(SetWeaponreplace, this, e, s); - s = ret_string; + s = M_ARGV(2, string); if (s == "") { - remove(this); + delete(this); startitem_failed = true; return; } @@ -76,7 +76,7 @@ void weapon_defaultspawnfunc(entity this, Weapon e) } if (wpn == WEP_Null) { - remove(this); + delete(this); startitem_failed = true; return; } @@ -133,6 +133,9 @@ void weapon_defaultspawnfunc(entity this, Weapon e) if (g_pickup_weapons_anyway) this.pickup_anyway = true; + if(!this.owner) + this.glowmod = wpn.wpcolor; + GameItem def = wpn.m_pickup; _StartItem( this,