mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 16:45:20 +02:00
drawing range updater update and myrand() (but not usage of it)
This commit is contained in:
@@ -88,4 +88,18 @@ const v3s16 g_26dirs[26] =
|
||||
// 26
|
||||
};
|
||||
|
||||
static unsigned long next = 1;
|
||||
|
||||
/* RAND_MAX assumed to be 32767 */
|
||||
int myrand(void)
|
||||
{
|
||||
next = next * 1103515245 + 12345;
|
||||
return((unsigned)(next/65536) % 32768);
|
||||
}
|
||||
|
||||
void mysrand(unsigned seed)
|
||||
{
|
||||
next = seed;
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user