From: Mario Date: Mon, 6 Apr 2015 15:21:22 +0000 (+1000) Subject: Change buff random spawn flag to prevent old items setting it X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=aa2b03f5cada719a59e2775d40657cd1b6c8cf8c;p=xonotic%2Fxonotic-data.pk3dir.git Change buff random spawn flag to prevent old items setting it --- diff --git a/qcsrc/server/mutators/mutator_buffs.qc b/qcsrc/server/mutators/mutator_buffs.qc index 16892eded..a0a8f91a5 100644 --- a/qcsrc/server/mutators/mutator_buffs.qc +++ b/qcsrc/server/mutators/mutator_buffs.qc @@ -270,7 +270,7 @@ void buff_Think() if(autocvar_g_buffs_randomize) buff_NewType(self, self.buffs); - if(autocvar_g_buffs_random_location || (self.spawnflags & 1)) + if(autocvar_g_buffs_random_location || (self.spawnflags & 64)) buff_Respawn(self); } @@ -318,7 +318,7 @@ void buff_Reset() buff_Waypoint_Reset(); self.buff_activetime_updated = false; - if(autocvar_g_buffs_random_location || (self.spawnflags & 1)) + if(autocvar_g_buffs_random_location || (self.spawnflags & 64)) buff_Respawn(self); } @@ -379,7 +379,7 @@ void buff_Init(entity ent) setmodel(self, BUFF_MODEL); setsize(self, BUFF_MIN, BUFF_MAX); - if(cvar("g_buffs_random_location") || (self.spawnflags & 1)) + if(cvar("g_buffs_random_location") || (self.spawnflags & 64)) buff_Respawn(self); self = oldself; @@ -1046,7 +1046,7 @@ void buffs_DelayedInit() for(i = 0; i < autocvar_g_buffs_spawn_count; ++i) { entity e = spawn(); - e.spawnflags |= 1; // always randomize + e.spawnflags |= 64; // always randomize e.velocity = randomvec() * 250; // this gets reset anyway if random location works buff_Init(e); }