]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Actually fix it (we apparently still need owner for the trace)
authorMario <mario@smbclan.net>
Wed, 25 Jan 2017 07:20:34 +0000 (17:20 +1000)
committerMario <mario@smbclan.net>
Wed, 25 Jan 2017 07:20:34 +0000 (17:20 +1000)
qcsrc/common/vehicles/vehicle/raptor.qc
qcsrc/common/vehicles/vehicle/spiderbot.qc

index 7bbc39e89740146fd953dd40b38a976ad351142a..b05dd9812e4443e6332e5d81d9364b9f3b6246f9 100644 (file)
@@ -84,7 +84,6 @@ void raptor_land(entity this)
 void raptor_exit(entity this, int eject)
 {
        entity player = this.owner;
 void raptor_exit(entity this, int eject)
 {
        entity player = this.owner;
-       this.owner = NULL;
 
        this.tur_head.exteriormodeltoclient = NULL;
 
 
        this.tur_head.exteriormodeltoclient = NULL;
 
@@ -127,6 +126,7 @@ void raptor_exit(entity this, int eject)
                setorigin(player, spot);
        }
 
                setorigin(player, spot);
        }
 
+       this.owner = NULL;
        antilag_clear(player, CS(player));
 }
 
        antilag_clear(player, CS(player));
 }
 
index 7634e7680fc59022282c1471c9dbfe015074457f..a5411e843474927583544807a07ef7ce58dd151b 100644 (file)
@@ -319,7 +319,6 @@ bool spiderbot_frame(entity this, float dt)
 void spiderbot_exit(entity this, int eject)
 {
        entity player = this.owner;
 void spiderbot_exit(entity this, int eject)
 {
        entity player = this.owner;
-       this.owner = NULL;
 
        IL_EACH(g_projectiles, it.owner == player && it.classname == "spiderbot_rocket",
        {
 
        IL_EACH(g_projectiles, it.owner == player && it.classname == "spiderbot_rocket",
        {
@@ -333,7 +332,10 @@ void spiderbot_exit(entity this, int eject)
        set_movetype(this, MOVETYPE_WALK);
 
        if(!player)
        set_movetype(this, MOVETYPE_WALK);
 
        if(!player)
+       {
+               this.owner = NULL; // reset owner anyway?
                return;
                return;
+       }
 
        makevectors(this.angles);
        vector spot;
 
        makevectors(this.angles);
        vector spot;
@@ -366,6 +368,7 @@ void spiderbot_exit(entity this, int eject)
        }
 
        antilag_clear(player, CS(player));
        }
 
        antilag_clear(player, CS(player));
+       this.owner = NULL;
 }
 
 void spiderbot_headfade(entity this)
 }
 
 void spiderbot_headfade(entity this)