]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
spawnfuncs: suppress some now visible warnings on init
authorTimePath <andrew.hardaker1995@gmail.com>
Fri, 1 Sep 2017 09:31:50 +0000 (19:31 +1000)
committerTimePath <andrew.hardaker1995@gmail.com>
Fri, 1 Sep 2017 09:53:55 +0000 (19:53 +1000)
qcsrc/common/weapons/all.qc

index afbf79eb54777d0e2852366e9d44956ff69c3966..6605f00c26d2a2e48378f519f9a9fc86c314a7cb 100644 (file)
@@ -530,7 +530,9 @@ void CL_WeaponEntity_SetModel(entity this, string name, bool _anim)
        int compressed_shotorg = compressShotOrigin(this.movedir);
        // make them match perfectly
 #ifdef SVQC
-       this.movedir = decompressShotOrigin(this.owner.stat_shotorg = compressed_shotorg);
+    // null during init
+    if (this.owner) this.owner.stat_shotorg = compressed_shotorg;
+       this.movedir = decompressShotOrigin(compressed_shotorg);
 #else
        this.movedir = decompressShotOrigin(compressed_shotorg);
 #endif