clock

Methods

set_clock_time

SET_CLOCK_TIME(12, 34, 56);

function native.clock.set_clock_time(hour: int, minute: int, second: int): void

pause_clock

function native.clock.pause_clock(toggle: bool, unused: int): void

_pause_clock_this_frame

function native.clock._pause_clock_this_frame(toggle: bool): void

advance_clock_time_to

function native.clock.advance_clock_time_to(hour: int, minute: int, second: int): void

add_to_clock_time

function native.clock.add_to_clock_time(hours: int, minutes: int, seconds: int): void

get_clock_hours

Gets the current ingame hour, expressed without zeros. (09:34 will be represented as 9)

function native.clock.get_clock_hours(): int

get_clock_minutes

Gets the current ingame clock minute.

function native.clock.get_clock_minutes(): int

get_clock_seconds

Gets the current ingame clock second. Note that ingame clock seconds change really fast since a day in RDR is only 48 minutes in real life.

function native.clock.get_clock_seconds(): int

_set_milliseconds_per_game_minute

function native.clock._set_milliseconds_per_game_minute(ms: int): void

_get_seconds_since_base_year

Base year is 1898.

function native.clock._get_seconds_since_base_year(): int

set_clock_date

function native.clock.set_clock_date(day: int, month: int, year: int): void

get_clock_day_of_week

Gets the current day of the week.

0: Sunday 1: Monday 2: Tuesday 3: Wednesday 4: Thursday 5: Friday 6: Saturday

function native.clock.get_clock_day_of_week(): int

get_clock_day_of_month

function native.clock.get_clock_day_of_month(): int

get_clock_month

function native.clock.get_clock_month(): int

get_clock_year

function native.clock.get_clock_year(): int

get_milliseconds_per_game_minute

function native.clock.get_milliseconds_per_game_minute(): int

get_posix_time

function native.clock.get_posix_time(year: ptr int, month: ptr int, day: ptr int, hour: ptr int, minute: ptr int, second: ptr int): void

_get_posix_time_struct

Same as GET_POSIX_TIME except that it takes a single pointer to a struct.

function native.clock._get_posix_time_struct(out_time: ptr int): void

_add_time_to_date_time

function native.clock._add_time_to_date_time(in_date_time: ptr int, time_to_add: ptr int, out_date_time: ptr int): void