The function get_char_pressed in src/c/functions/raylib_functions.ml returns the Key.t type instead of an unicode char.
GetKeyPressed returns a keycode (correct)
GetCharPressed returns an unicode char (wrong in the ocaml code)
int GetKeyPressed(void);
// Get key pressed (keycode), call it multiple times for keys queued, returns 0 when the queue is empty
int GetCharPressed(void);
// Get char pressed (unicode), call it multiple times for chars queued, returns 0 when the queue is empty
let get_key_pressed = foreign "GetKeyPressed" (void @-> returning Key.t)
let get_char_pressed = foreign "GetCharPressed" (void @-> returning Key.t)
The function
get_char_pressed
insrc/c/functions/raylib_functions.ml
returns theKey.t
type instead of an unicode char.GetKeyPressed returns a keycode (correct) GetCharPressed returns an unicode char (wrong in the ocaml code)