# Resource[v13+] Unreal Time System 1.1.1

#### -FL-

##### Pokémon Island Creator
Member
-FL- submitted a new resource:

Unreal Time System - Time passes like Minecraft and Zelda: Ocarina of Time.

This script makes the time in game uses its own clock that only pass when you are in game instead of using real time (like Minecraft and Zelda: Ocarina of Time).

Tested on Essentials v13, v17.2, v18.1, v19.1 and v20. If this script isn't working on latest Essentials version, please...

#### TheDizzy1

##### Novice
Member
I’m starting work on my game again, and I absolutely love this and can’t wait to start it back up again. As I’m thinking of scenery, is it possible to set time of day events while using this amazing resource?

#### TechSkylander1518

##### Wiki Dweeb
Member
I’m starting work on my game again, and I absolutely love this and can’t wait to start it back up again. As I’m thinking of scenery, is it possible to set time of day events while using this amazing resource?
FL's got some instructions for this at the top of the Script.rb file -
# same thing, in fact, EXTRA_SECONDS/EXTRA_DAYS call these methods.
#
# 3. 'UnrealTime.advance_to(16,17,18)' advance the time to a fixed time of day,
# 16:17:18 on this example.

#### corvo00

##### Rookie
Member
Dosn't work in 20.1? I installed the script above main and dosn't work.

Sorry for my english

#### TechSkylander1518

##### Wiki Dweeb
Member
Dosn't work in 20.1? I installed the script above main and dosn't work.

Sorry for my english
You've got to describe the problem beyond just "it doesn't work".

#### corvo00

##### Rookie
Member
You've got to describe the problem beyond just "it doesn't work".
I get this when I open the game

#### TechSkylander1518

##### Wiki Dweeb
Member
I get this when I open the game
I'm not getting this error when I try it. Have you removed anything from the script? That error message is pointing to line 170, but the script doesn't reference pbGraphicsUpdate until line 271. And you're getting this error message because PokeBattle_Scene isn't a thing in v20, so there's no pbGraphicsUpdate to alias, but FL definitely accounted for that with the line PokeBattle_Scene = Battle::Scene if !defined?(PokeBattle_Scene).

#### corvo00

##### Rookie
Member
I'm not getting this error when I try it. Have you removed anything from the script? That error message is pointing to line 170, but the script doesn't reference pbGraphicsUpdate until line 271. And you're getting this error message because PokeBattle_Scene isn't a thing in v20, so there's no pbGraphicsUpdate to alias, but FL definitely accounted for that with the line PokeBattle_Scene = Battle::Scene if !defined?(PokeBattle_Scene).
I'm not getting this error when I try it. Have you removed anything from the script? That error message is pointing to line 170, but the script doesn't reference pbGraphicsUpdate until line 271. And you're getting this error message because PokeBattle_Scene isn't a thing in v20, so there's no pbGraphicsUpdate to alias, but FL definitely accounted for that with the line PokeBattle_Scene = Battle::Scene if !defined?(PokeBattle_Scene).
Ups! I had deleted a line unintentionally, what a fool... Thank you for responding and sorry for the inconvenience.

#### Westrah

##### Novice
Member
Is there a way to make this script work with Apricorns so that they respawn after "24 hours" of this scripts time?

#### -FL-

##### Pokémon Island Creator
Member
Is there a way to make this script work with Apricorns so that they respawn after "24 hours" of this scripts time?
An Apricorn system who works without this scripts should work with this script automatically.

#### Taiga

##### Rookie
Member
I kind of struggle to set the date to a specific time. I put in
Ruby:
pbGetTimeNow.year(2028)
pbGetTimeNow.mon(8)
pbGetTimeNow.day(1)
pbGetTimeNow.hour(8)
but it just gives me an error message.

#### TechSkylander1518

##### Wiki Dweeb
Member
I kind of struggle to set the date to a specific time. I put in
Ruby:
pbGetTimeNow.year(2028)
pbGetTimeNow.mon(8)
pbGetTimeNow.day(1)
pbGetTimeNow.hour(8)
but it just gives me an error message.
"An error message" could be anything, you need to share the full thing. But I'm guessing that the error is coming from the fact that pbGetTimeNow is supposed to return the current time, not set it. You should be using these commands -

#### SirWeibrot

##### Novice
Member
Hi, I just noticed that a caught Pokemon shows its date received based on Time.local, rather than the actual date it was received. Is there a way to change/fix this?

#### -FL-

##### Pokémon Island Creator
Member
Hi, I just noticed that a caught Pokemon shows its date received based on Time.local, rather than the actual date it was received. Is there a way to change/fix this?
The default Essentials use 'pbGetTimeNow' for pokémon caught date (search for 'pbGetTimeNow' on class Pokemon, should be a '@timeReceived = pbGetTimeNow.to_i'), so this may be some external script changing it.

If you want to change others 'Time.now' to use Unreal Time (or vice-versa):
Script said:
# If you wish to some parts still use real time like the Trainer Card start time
# and Pokémon Trainer Memo, just change 'pbGetTimeNow' to 'Time.now' in their
# scripts.
Do the reverse for the opposite effect if you want.