From: Mario Date: Sun, 12 Mar 2017 22:04:58 +0000 (+1000) Subject: Possible fix for buff random selection X-Git-Tag: xonotic-v0.8.2~66 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c6da70e6d89688d9ead11e26e2fa8216794e1cd6;p=xonotic%2Fxonotic-data.pk3dir.git Possible fix for buff random selection --- diff --git a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc index 7048e541f..f6fedde84 100644 --- a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc +++ b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc @@ -220,7 +220,7 @@ void buff_NewType(entity ent) FOREACH(Buffs, buff_Available(it), { // if it's already been chosen, give it a lower priority - RandomSelection_AddEnt(it, 1, max(0.2, 1 / it.buff_seencount)); + RandomSelection_AddEnt(it, max(0.2, 1 / it.buff_seencount), 1); }); entity newbuff = RandomSelection_chosen_ent; newbuff.buff_seencount += 1; // lower chances of seeing this buff again soon