★ TimeGen4 Time Generator :: IruMoto Script Factory ★

IruMoto Script Factory and Tamita Motors

OpenSimulator virtual worlds

Proudly built and coded in Irukandji, the new TimeGen4 is the latest iteration of the IruMoto Time Generator, a very cool piece of kit that make your virtual world region come alive.

Function

Powerful and versatile, TimeGen4 divides each day on your region into 48 half-hour segments (in-world time). On a typical OpenSimulator region, where six in-world days occur every real-world day, that's nearly 300 time segments each calendar day.

Now your region can really come alive throughout the day and night, e.g. street lights coming on, clock tower chiming, bonfires, club lights, NPCs coming online etc. Basically any script that would otherwise do something in response to a touch or listen event will work perfectly with TimeGen4.

What this means in real terms is that your region can always have something happening, even if you aren't there to make it happen. Set and forget, and let TimeGen4 entertain your visitors automatically.

Read on for all the info. Yell out if you have any questions,
Andrew (Thommo) Thompson, a.k.a. Xay Tomsen

Follow Andrew Thompson on Instagram Follow Andrew Thompson on Pinterest Follow Andrew Thompson on Strava Follow Andrew Thompson on Facebook Andrew Thompson on YouTube

Andrew Thompson, Rockhampton

TimeGen4 comes with some common pre-configured scripts that you can use straight out of the box (with the tiniest bit of editing) or as a foundation for new scripts we haven't even thought of yet.

Also new to TimeGen4 is the ability to communicate with IruMoto NPC Engines, allowing you to keep your region clean of rogue avatars and unnecessary scripted objects.

The IruMoto Time Generator is suitable for use in virtual worlds running OpenSimulator 9.1 and later. It will also work in Second Life, however I have not placed any on that grid as at time of writing.

How to buy

You can purchase a TimeGen4 either online on Kitely Market, or teleport in-world to the IruMoto Script Factory to see the system in action before you buy.

Teleport to IruMoto Script Factory

If you have a viewer for OpenSimulator installed, click the landmark to teleport to IruMoto Script Factory.

teleport to IruMoto Script Factory

Variables

A single script powers the Time Generator. Its user-changeable variables are managed via the supporting timeGen4Config notecard.

Receiving scripts, e.g. the script in a lighthouse beam, will also contain a script to listen for updates from the Time Generator, either directly or through a conduit script. More details below.

Components

Component parts of the IruMoto Time Generator are:

Internal components:

Four other scripts control the digital time display on the TimeGen4 wall panel but these form part of the main unit and don't need to be touched.

External support scripts:

There are four types of script that the Time Generator communicates with:

Auxiliary objects:

In your pack, you would have noticed a TimeGen4 HUD. It looks like a cutdown version of the Time Generator but it isn't. Its purpose is so you can always see what time it is on your region, which is especially helpful when you are scripting objects to activate at a certain time of the day.

You win ten points if you just worked out the HUD contains an RO script, a config notecard, and four LO scripts for the digital display.

Also, TimeGen4 has a new feature that pings IruMoto NPC Engines, where the 'tgChan' variable of an NPC matches the region channel of your Time Generator. Note that this feature is intended to find engines, not NPCs, thus making it very helpful to locate missing invisible control units when NPCs can't/won't come online.

Interconnectivity is automatic since [.npcExist500.1z].

Quirks & Formats

Time is not regular in OpenSimulator, meaning that not every day is the same length. Additionally, day and night duration fluctuate with the seasons.

For this reason, TimeGen4 is the first version that I have made available to the public. It has been under development for over ten years, and each time that I thought I had ironed out all the bugs, a day would grow longer or shorter and skip one or even several time segments.

On a region level, the impact of this meant that an event which was due to happen at say 5.30 pm would not happen that day, e.g. the street lights would not turn on and the region would stay in darkness all night, etc.

Not to be discouraged, I kept tweaking the maths. Many, many, many, many times.

It' i's October 2025 as I write this, and TimeGen4 has been running for six years now without missing a single time segment. I'm not promising the Time Generator will never miss a time segment in the future, but if it skips one every fifty thousand, I can live with that.

Naming convention

Re file names, there is logic behind it.

This convention carries across every IruMoto product, and is for the sake of order in my Contents windows. Scripts are always at the top, followed by notecards, followed by animations. It keeps things neat and simple.

NPC engine contents card

Format

Before we set up your TimeGen4, you need to understand how it works.

Setup

In you pack, you will see two objects; the TimeGen4 and the TimeGen4 HUD.

TimeGen4 wall unit

Main Unit:

TimeGen4 is meant to be visibly reminiscent of a Tesla battery or similar, so rez it on a wall or somewhere vertical. Only rez one unit per region.

HUD:

Right-click the HUD and choose 'Wear'. It will appear in the top left corner of your screen. If you want to mount it somewhere else on the screen, that's fine. The digital display should change to 0000. When the time generator updates next, the time on your HUD will change to your region's current time.

Both the main unit and your HUD required a copy of the .timeGen4Config notecard. Make sure the details for each are identical or as listed below.

In edit mode, click on the Content tab and open the .timeGen4Config notecard.

.timeGen4Config notecard

Follow the instructions precisely. Everything you enter in the notecard is changeable in the future so don't over-think it.

Time Generator timeGen4Config notecard

  1. #COMMS CHANNEL: Give your TimeGen4 a unique communications channel. Make it a large negative number that isn't used for anything else on your region. If you are also using IruMoto NPC Engines, this same comms channel will need to be entered in their .npc500Config notecards as well, under the #TIMEGEN CHANNEL heading.
  2. #HOVERTEXT: Leave off unless you are stripping the script and card from the shell provided and building your own. This is the only reason I've left this option in the notecard as the digital display looks heaps better than hovertext.
  3. #TIME OFFSET: Leave this for now because you have no way of knowing if it's an issue or not yet. This feature allows you to adjust the time zone to match your region. The default value I've set is 4.0 which reflects my own situation, not yours. For me, living right on top of the Tropic of Capricorn in east coast Australia, I wanted last light to be around 7.30 pm, but my region wanted to give me last light at 3.30 pm, so I added 4. Tweak it as you see fit, but remember the number must be positive with one decimal place. No negatives allowed for this variable or your TimeGen4 will break.
  4. #METHOD: Don't touch. This is just a bit of future-proofing, and also if I ever decide to have separate versions for Second Life and Open Sim.
  5. #CHAT: If you have this turned on, whenever the time changes, generally every few minutes, the Time Generator will say the time for anyone nearby to hear. It is really annoying, so it is off by default. However, I do recommend turning it on for your HUD while you set things up as it can be a handy tool when you're trying to work out what time of day things are happening, e.g. what time do you turn the lights on? Match it up with the chat from your HUD - Nice and simple.
  6. #PING: yes by default. If you don't run IruMoto NPC Engines, ignore it. Feel free to turn it off if you want. Will be hard-coded to yes in a future update.

Once the above is done, still in the Content tab of the edit window, click the Reset Scripts button. TimeGen4 will determine the current time and your digital display will change. Remember, you need to update the config card for both the main unit and the HUD, and then reset both. The HUD's digital display might not update for several minutes until it receives its first sync from the main unit.

Conduit scripts

Conduit scripts also rely on a .timeGen4Config notecard, so you will need to drop this into your object and update the channel number to match your TimeGen4. This is the only line of information used by this script at this stage, so the other lines don't matter. Once done, drop in the conduit script and you're ready to go.

RO (remote object) scripts

Like conduits, RO scripts listen directly to the Time Generator, however their use is very specific and less versatile than a conduit. As such, the scripts are full perm and do not rely on a config notecard. Instead, you enter the channel number directly into the integer chan variable in the script header.

LO (linked object) scripts

Linked object scripts are where the action happens, e.g. a light turns on. They do not need to reference the channel number as they only listen to a conduit script or RO script. All these little guys want to know is what time the action kicks off and when it ends. To make things even more exciting, they are full perms so you get to edit the scripts directly and see how it all works!

Inside each LO script are two main variables; one will be startEvent and the other endEvent or similar terminology. The values that startEvent and endEvent are looking for is the time.

Remember the time format we discussed earlier? "Time1800" etc? You need to enter a value in this exact format into both the startEvent and endEvent values. If you're unsure of what I mean about the format, look in the chat from your HUD. You will see the exact message that your TimeGen4 is transmitting to the region with every update.

IruMoto sign

FAQ

Q. How many TimeGens should I install on my region?
A. You only need one TimeGen per region regardless of whether it's a standard region or huge var-region.

Q. I have many regions. Can I use the same channel for all my regions?
A. Yes. Just remember that you will need to install one time generator per region as it will not (theoretically) transmit across sim boundaries.

Q. Which communication method is best?
A. Conduit scripts do all the heavy lifting, and since there is only one conduit in every linkset instead of dozens of listener scripts, it is a very economical way to communicate. This ability is the fundamental strength of TimeGen4. RO scripts exist to fill the gap when conduits can't do the task. RO scripts are ideal where an object moves around or it is not part of a greater linkset. Just remember that one RO script, given its small scope of ability, uses the same amount of resources as a conduit script but delivers a lot less.

Q. How do tenants on my region plug into the time generator?
A. Give them copies of the RO, LO and Conduit scripts to use in their own devices. These scripts are full perm, so anyone can use them and tweak them to suit their needs.

Q. My tenant has their own TimeGen and wants to use it. Will this cause problems?
A. No, so long as they use a different comms channel. That said, there really is no point having two units on one region. They might as well plug into yours instead.