X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Flib%2Frandom.qc;h=a5ff69356a21f516ba290bac01761eac2a7cce88;hp=d39cfdcadcfef74b2b74e9513de62690f89ab659;hb=29ba411594428929a9e9a0e0baa620210213bec7;hpb=0bd99205bd154e058edc6b82995d24e3375f5f97 diff --git a/qcsrc/lib/random.qc b/qcsrc/lib/random.qc index d39cfdcad..a5ff69356 100644 --- a/qcsrc/lib/random.qc +++ b/qcsrc/lib/random.qc @@ -1,6 +1,6 @@ #include "random.qh" -[[eraseable]] +ERASEABLE void RandomSelection_Init() { RandomSelection_totalweight = 0; @@ -10,7 +10,7 @@ void RandomSelection_Init() RandomSelection_best_priority = -1; } -[[eraseable]] +ERASEABLE void RandomSelection_Add(entity e, float f, string s, vector v, float weight, float priority) { if (priority > RandomSelection_best_priority) @@ -38,7 +38,7 @@ void RandomSelection_Add(entity e, float f, string s, vector v, float weight, fl float DistributeEvenly_amount; float DistributeEvenly_totalweight; -[[eraseable]] +ERASEABLE void DistributeEvenly_Init(float amount, float totalweight) { if (DistributeEvenly_amount) @@ -50,7 +50,7 @@ void DistributeEvenly_Init(float amount, float totalweight) DistributeEvenly_totalweight = totalweight; } -[[eraseable]] +ERASEABLE float DistributeEvenly_Get(float weight) { float f; @@ -61,7 +61,7 @@ float DistributeEvenly_Get(float weight) return f; } -[[eraseable]] +ERASEABLE float DistributeEvenly_GetRandomized(float weight) { float f; @@ -75,7 +75,7 @@ float DistributeEvenly_GetRandomized(float weight) // from the GNU Scientific Library float gsl_ran_gaussian_lastvalue; float gsl_ran_gaussian_lastvalue_set; -[[eraseable]] +ERASEABLE float gsl_ran_gaussian(float sigma) { if (gsl_ran_gaussian_lastvalue_set)