GBDK 2020 Docs
4.1.1
API Documentation for GBDK 2020
rand.h
Go to the documentation of this file.
1
6
#ifndef RAND_INCLUDE
7
#define RAND_INCLUDE
8
9
#include <
types.h
>
10
#include <
stdint.h
>
11
28
#if defined(__PORT_sm83) || defined(__PORT_mos6502)
29
void
initrand
(
uint16_t
seed)
OLDCALL
;
30
#elif defined(__PORT_z80)
31
void
initrand
(
uint16_t
seed)
Z88DK_FASTCALL
;
32
#endif
33
34
#define RAND_MAX 255
35
#define RANDW_MAX 65535
36
48
extern
uint16_t
__rand_seed
;
49
54
uint8_t
rand
()
OLDCALL
;
55
60
uint16_t
randw
()
OLDCALL
;
61
71
#if defined(__PORT_sm83) || defined(__PORT_mos6502)
72
void
initarand
(
uint16_t
seed)
OLDCALL
;
73
#elif defined(__PORT_z80)
74
void
initarand
(
uint16_t
seed)
Z88DK_FASTCALL
;
75
#endif
76
81
uint8_t
arand
()
OLDCALL
;
82
83
#endif
OLDCALL
#define OLDCALL
Definition:
types.h:21
Z88DK_FASTCALL
#define Z88DK_FASTCALL
Definition:
types.h:46
rand
uint8_t rand() OLDCALL
initarand
void initarand(uint16_t seed) OLDCALL
arand
uint8_t arand() OLDCALL
__rand_seed
uint16_t __rand_seed
initrand
void initrand(uint16_t seed) OLDCALL
randw
uint16_t randw() OLDCALL
stdint.h
uint8_t
unsigned char uint8_t
Definition:
stdint.h:51
uint16_t
unsigned short int uint16_t
Definition:
stdint.h:52
types.h