GetTime: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
__NOTOC__
__NOTOC__
{{Server client function}}
{{Server client function}}
This function is used to get the current time in the game.
This function is used to get the current time in the game. If you want to get the real server time, use [[getRealTime]].


==Syntax==
==Syntax==

Revision as of 23:28, 17 December 2007

This function is used to get the current time in the game. If you want to get the real server time, use getRealTime.

Syntax

int int getTime ()

Returns

Returns two ints that represent hours and minutes.

Example

local hour, mins = getTime ()
outputChatBox ( "The current time is " .. hour .. ":" .. mins )

See Also