]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Other half of the fix
authorMario <mario@smbclan.net>
Tue, 18 Oct 2016 07:22:23 +0000 (17:22 +1000)
committerMario <mario@smbclan.net>
Tue, 18 Oct 2016 07:22:23 +0000 (17:22 +1000)
qcsrc/common/wepent.qc

index fa6c37d7a351ab14edcadf4d1e70f040cd5062db..1b6e407786eca23a479b716e6597181702895199 100644 (file)
@@ -119,13 +119,21 @@ MACRO_END
        #undef X
        }
 
+       bool wepent_customize(entity this, entity client)
+       {
+               //entity e = WaypointSprite_getviewentity(client);
+               .entity weaponentity = this.owner.weaponentity_fld;
+               return client.(weaponentity) == this.owner;
+       }
+
        void wepent_link(entity wep)
        {
                entity e = new(wepent_sender);
                e.owner = wep;
                setthink(e, wepent_think);
                e.nextthink = time;
-               e.drawonlytoclient = wep.owner;
+               //e.drawonlytoclient = wep.owner;
+               setcefc(e, wepent_customize);
                Net_LinkEntity(e, false, 0, wepent_send);
        }