MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / randf

Function randf

Descent3/ambient.cpp:93–93  ·  view source on GitHub ↗

Computes a floating-point pseudo-random number. Returns value in the range 0..1, with the precision 1/D3_RAND_MAX

Source from the content-addressed store, hash-verified

91// Computes a floating-point pseudo-random number.
92// Returns value in the range 0..1, with the precision 1/D3_RAND_MAX
93static float randf() { return ((float)ps_rand()) / ((float)D3_RAND_MAX); }
94
95// Process an Ambient Sound Pattern
96static void ProcessASP(asp *asp) {

Callers 2

ProcessASPFunction · 0.85
InitAmbientSoundsFunction · 0.85

Calls 1

ps_randFunction · 0.85

Tested by

no test coverage detected