From: TimePath Date: Tue, 22 Mar 2016 01:07:36 +0000 (+1100) Subject: Check for null X-Git-Tag: xonotic-v0.8.2~1061 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c439027bb2f8abd307151395a730a110d20cb134;p=xonotic%2Fxonotic-data.pk3dir.git Check for null Closes #1702 --- diff --git a/qcsrc/server/weapons/weaponsystem.qc b/qcsrc/server/weapons/weaponsystem.qc index 1a2aaeafa..7cf26a459 100644 --- a/qcsrc/server/weapons/weaponsystem.qc +++ b/qcsrc/server/weapons/weaponsystem.qc @@ -152,7 +152,8 @@ void CL_ExteriorWeaponentity_Think() else if (this.owner.alpha != 0) this.alpha = this.owner.alpha; else this.alpha = 1; - this.glowmod = weaponentity_glowmod(PS(this.owner).m_weapon, this.owner.clientcolors); + Weapon wep = PS(this.owner).m_weapon; + if (wep) this.glowmod = weaponentity_glowmod(wep, this.owner.clientcolors); this.colormap = this.owner.colormap; CSQCMODEL_AUTOUPDATE(this);