[PAID] [Standalone] [Lua] World Time

What is World Time?
World Time is a new resource that is being constantly developed as a new way to manage time in the GTA world. World Time adds a new element to dates, sub days, sub days refer to the individual day cycles within the world of San Andreas. The day cycles can be configured in this resource, with the ability to change a day cycle to be 1 hour, 2 hours, 3 hours or even 8 hours depending on your likes. The server keeps track of each day cycle and the current time in the San Andreas world. The resource keeps track of 3 times, the system time, the server time which is set in the config, and the GTA world time. The server time is used to know what time its meant to be in the city and enables day cycles to occur at the same time everyday.

That’s great, but what does that all mean?

  • Day cycles occur at the same time every day based on the set server time
  • Day cycles can be configured
  • Each day cycle can be referenced using this resource
    • Can be used for jail scripts, allowing a more immersive experience
    • Allows for Police reports to be referenced by that day cycle rather than other methods
    • Time can be better referenced to allow for more emersion and a wider understanding of the data and time within a server
  • Time and date is synced between all the players

Are there any Export / Config options?

Config is listed below:

config.debug                = false
config.examples             = true
config.usecallbacks         = false
config.callbackscript       = "kimi_callbacks"
config.sync                 = 60000
config.timedifference       = 28800
config.timemillilength      = 7500
config.searchrange          = 43200 * 8

Exports are listed below:

Clock_Request_System
    Inputs  -> None
    Returns -> Current System Time (Box time)
        Format -> {hour = int, minute = int, day = int, month = int, year = int}

Clock_Request_Server
    Inputs  -> None
    Returns -> Current Server Time (SystemTime + config.timedifference)
        Format -> {hour = int, minute = int, day = int, month = int, year = int}

Clock_Request_GTATime
    Inputs  -> None
    Returns -> Current GTA Time
        Format -> {hour = int, minute = int, day = int, subday = int, month = int, year = int}

Game_CalculateClock
    Inputs -> (TimeData, AdvanceData)
        Format TimeData     -> {hour = int, minute = int, day = int, subday = int, month = int, year = int}
        Format AdvanceData  -> {negative = bool, minutes = int, hours = int, subdays = int, days = int}
    Returns -> Future/Past GTA Time
        Format -> {hour = int, minute = int, day = int, subday = int, month = int, year = int}
    
Game_CompareClocks
    Inputs -> (TimeDataA, TimeDataB) | ORDER MATTERS
        Format TimeDataA     -> {hour = int, minute = int, day = int, subday = int, month = int, year = int}
        Format TimeDataB     -> {hour = int, minute = int, day = int, subday = int, month = int, year = int}
    Returns -> 
        True    -> if times match exactly
        False   -> if time is out of range (Try flipping the inputs as InputA might be after InputB)
        int     -> if the time is found, the int returned is the minutes [GTA TIME] until the time listed in TimeDataB is reached

What is the intended use of the resource?
The resource is able to be used right after the purchased with minimal configuration, however it is best used when integrated with resources with the included exports.

What can I expect from World Time in the future?
The resource is already compatible with callbacks, as well functions are constantly being imagined and starting to be implemented to improve the resource. All updates are included with the purchase as well as support.

Have an idea?
Please pitch your ideas and I will do my best to implement them!

Notes:

  • Time is not able to be changed [GTA Time] as this resource was created to go through the same day cycles each day to create the most realism possible in GTA.
  • Support information is provided in the readme + support is provided here on the forums

NO LONGER AVALIBLE

Code is accessible Yes
Subscription-based No
Lines (approximately) 600+
Requirements None
Support Yes
2 Likes

Resource Update [1.0.2]:

  • Adjusted folder system to make it more clear what files are encrypted
  • Added new config option to define what months a season occurs in
  • Added new export & callback for getting current season (Based on server time)

General Notes:

  • Forgot to add it in the original post, resource basically sits at 0ms client side. Everything is done on the server.
  • All updates to the script will be in unencrypted files (Apart from updates to parts in the encrypted files)
1 Like

ty.
how do I set utc+1? 28800 → 28100?

Excellent question!

28800 refers to UTC+8, you get 28800 by 8 * (60 * 60), I made a error in the readme. It should be the offset in seconds not minutes. So you UTC+1 you would do 1 * (60 * 60) which is 3600 or a offset of 3600 seconds.

I am pushing the updated readme to keymaster now :slight_smile:

1 Like

Also, the resource will always print out the starting values in the server console. If you looks at the system one and the server one. You know it is setup correctly when the server time is matched with the timezone you are wanting to match with, in your case you would want the server to be printing UTC+1

1 Like

Issue with customers not gaining access to the asset on keymaster has been resolved.

Original message is no longer relevant

New version available here: [Paid] [Standalone] [C#] World Time

Existing customers already have access to the new version. New customers need to decide which version to buy

Price adjusted to $5USD + Sales tax

All existing purchases made at a higher price have been modified to reflect the change