Xonotic
|
#include "random.qh"
Go to the source code of this file.
Functions | |
ERASEABLE float | DistributeEvenly_Get (float weight) |
ERASEABLE float | DistributeEvenly_GetRandomized (float weight) |
ERASEABLE void | DistributeEvenly_Init (float amount, float totalweight) |
ERASEABLE float | gsl_ran_gaussian (float sigma) |
float | prandom () |
vector | prandomvec () |
void | psrandom (float seed) |
ERASEABLE void | RandomSelection_Add (entity e, float f, string s, vector v, float weight, float priority) |
ERASEABLE void | RandomSelection_Init () |
Variables | |
float | DistributeEvenly_amount |
float | DistributeEvenly_totalweight |
float | gsl_ran_gaussian_lastvalue |
float | gsl_ran_gaussian_lastvalue_set |
float | prandom_seed |
Definition at line 54 of file random.qc.
References DistributeEvenly_amount, DistributeEvenly_totalweight, ERASEABLE, and floor().
Referenced by Invasion_RoundStart(), kh_LoserTeam(), and kh_WinnerTeam().
Definition at line 65 of file random.qc.
References DistributeEvenly_amount, DistributeEvenly_totalweight, floor(), and random().
Definition at line 42 of file random.qc.
References DistributeEvenly_amount, DistributeEvenly_totalweight, ERASEABLE, ftos(), and LOG_TRACE.
Referenced by Invasion_RoundStart(), kh_LoserTeam(), and kh_WinnerTeam().
Definition at line 79 of file random.qc.
References cos(), gsl_ran_gaussian_lastvalue, gsl_ran_gaussian_lastvalue_set, log(), M_PI, random(), sin(), and sqrt().
Referenced by W_CalculateSpread().
float prandom | ( | ) |
Definition at line 100 of file random.qc.
References ftos(), LOG_TRACE, M_PI, prandom_seed, and strcat().
Referenced by prandomvec(), SND_GIB_SPLAT_RANDOM(), and turret_gibtoss().
vector prandomvec | ( | ) |
Definition at line 128 of file random.qc.
References ftos(), LOG_TRACE, prandom_debug, and prandom_seed.
Referenced by NET_HANDLE().
ERASEABLE void RandomSelection_Add | ( | entity | e, |
float | f, | ||
string | s, | ||
vector | v, | ||
float | weight, | ||
float | priority | ||
) |
Definition at line 14 of file random.qc.
References random(), RandomSelection_best_priority, RandomSelection_chosen_ent, RandomSelection_chosen_float, RandomSelection_chosen_string, RandomSelection_chosen_vec, RandomSelection_totalweight, and v.
Referenced by MUTATOR_HOOKFUNCTION().
Definition at line 4 of file random.qc.
References ERASEABLE, NULL, RandomSelection_best_priority, RandomSelection_chosen_ent, RandomSelection_chosen_float, RandomSelection_chosen_string, RandomSelection_totalweight, and string_null.
Referenced by bot_setnameandstuff(), buff_NewType(), CheatCommand(), CheatImpulse(), FixIntermissionClient(), GiveRandomWeapons(), invasion_PickMonster(), invasion_PickSpawn(), invasion_SpawnChosenMonster(), Item_FindTeam(), Item_Touch(), jumppad_push(), MapInfo_LoadMapSettings(), MapVote_CheckRules_2(), MUTATOR_HOOKFUNCTION(), NIX_ChooseNextWeapon(), RandomItems_GetRandomInstagibItemClassName(), RandomItems_GetRandomItemClassNameWithProperty(), RandomItems_GetRandomOverkillItemClassName(), RandomItems_GetRandomVanillaItemClassName(), Simple_TeleportPlayer(), Spawn_WeightedPoint(), spawnmonster(), SUB_UseTargets_Ex(), TeamBalance_FindBestTeam(), TeleportPlayer(), train_next_find(), and W_RandomWeapons().
float DistributeEvenly_amount |
Definition at line 38 of file random.qc.
Referenced by DistributeEvenly_Get(), DistributeEvenly_GetRandomized(), and DistributeEvenly_Init().
float DistributeEvenly_totalweight |
Definition at line 39 of file random.qc.
Referenced by DistributeEvenly_Get(), DistributeEvenly_GetRandomized(), and DistributeEvenly_Init().
float gsl_ran_gaussian_lastvalue |
Definition at line 76 of file random.qc.
Referenced by gsl_ran_gaussian().
float gsl_ran_gaussian_lastvalue_set |
Definition at line 77 of file random.qc.
Referenced by gsl_ran_gaussian().
float prandom_seed |
Definition at line 99 of file random.qc.
Referenced by prandom(), and psrandom().