Difference between revisions of "00C0"

From GTAMods Wiki
Jump to navigation Jump to search
(page updates)
Line 1: Line 1:
{{Icon|trilogy}} '''SET_TIME_OF_DAY'''
+
{{OpCode
<hr />
+
| games      = {{Icon|t}}
'''Description'''
+
| command    = SET_TIME_OF_DAY
: Sets the current game clock
+
| description = Sets the current game clock
'''Syntax'''
+
| syntax1    = 00C0: set_current_time [''int1''] [''int2'']
: 00C0: set_current_time [''int 1''] [''int 2'']
+
| p1t        = [''int1'']
'''Parameter'''
+
| p1d        = Game hour
: [''int 1'']
+
| p2t        = [''int2'']
:: Game hours
+
| p2d        = Game minute
: [''int 2'']
+
| native      = [[SET_TIME_OF_DAY]]
:: Game minutes
+
}}
'''Native analog'''
 
: [[SET_TIME_OF_DAY]]
 
  
This sets the current game clock. The hours are from 0 to 23 and the minutes are from 0 to 59. You can set the numbers higher but the game will reset it to the appropriate time, like hour 25 will be hour 1 and minute 65 would be hour 1 and minute 5. In Vice City (probably all games), this opcode must be set at the beginning of the <code>[[main.scm]]</code>. If it is not set, time will speed forward similar in effect to inputting the "faster game clock" cheat.
+
This opcode sets the current game clock. Valid values for hours are between 0 and 23, and for minutes are between 0 and 59. In Vice City, it is not possible to set a time outside the range as the game takes the [[wikipedia:Modulo operation|modulo]] of 24 with the hour and modulo of 60 with the minute. Also in Vice City, this opcode must be set at least once when a new game is started or else time will speed forward similar in effect to inputting the "faster game clock" cheat.
  
==Keywords==
+
== Keywords ==
set, current, time, clock
+
set, current, time, clock, day
  
 
== See also ==
 
== See also ==
* [[00BF]] &ndash; gets time of day
+
* {{Icon|t}} [[00BF]], gets time of day
* [[00C1]] &ndash; gets minutes left to time
+
* {{Icon|t}} [[00C1]], gets minutes left to time
* [[Real Time Clock]]
 
 
 
[[Category:OpCodes]]
 

Revision as of 03:58, 24 November 2016

GTA III Vice City San Andreas SET_TIME_OF_DAY


Description
Sets the current game clock
Syntax
00C0: set_current_time [int1] [int2]
Parameter
[int1]
Game hour
[int2]
Game minute
Native analog
SET_TIME_OF_DAY

This opcode sets the current game clock. Valid values for hours are between 0 and 23, and for minutes are between 0 and 59. In Vice City, it is not possible to set a time outside the range as the game takes the modulo of 24 with the hour and modulo of 60 with the minute. Also in Vice City, this opcode must be set at least once when a new game is started or else time will speed forward similar in effect to inputting the "faster game clock" cheat.

Keywords

set, current, time, clock, day

See also

  • GTA III Vice City San Andreas 00BF, gets time of day
  • GTA III Vice City San Andreas 00C1, gets minutes left to time