|
Development Forum |
 |
|

Geek2Nurse
 

|
6/1/2012 | |
SEAN tells me what season it currently is in my world, but is there any way to tell me (other than long-term monitoring) how long it has been winter, or how long until springtime?
---
Optimist: the glass is half full.
Pessimist: the glass is half empty.
Engineer: the glass is twice as big as it needs to be. |

Malkin
     Manager

|
6/1/2012 | |
from my game variables cos:
* Set time lengths
setv game "engine_LengthOfDayInMinutes" 20
setv game "engine_LengthOfSeasonInDays" 4
setv game "engine_NumberOfSeasons" 4
|
So it looks like there's 80 minutes to a season.
My TCR Norns |

Geek2Nurse
 

|
6/1/2012 | |
Yep, I found that much. But suppose I query SEAN and find it's winter. I don't know how long it's BEEN winter. It could be winter for another 80 minutes, or maybe it's already been winter for 79 minutes and will be springtime in just another minute. I'm just wondering if there's a way to know when it will be springtime, or do I just have to wait and see?
---
Optimist: the glass is half full.
Pessimist: the glass is half empty.
Engineer: the glass is twice as big as it needs to be. |

Malkin
     Manager

|
6/1/2012 | |
If there are 1200 ticks in a minute, we can surmise that there are 96000 ticks in a season - could that help, at all?
My TCR Norns |

Moe
  

|
6/1/2012 | |
You can use the DATE command to call the current day within a season. That should at least narrow down what you're looking for, since we know there are only 4 days and how long each day is. Then you can use TIME to figure out what time of day it is within that day. That should narrow it down further.
The problem with figuring out what the exact time into a season you are is due to the way the game processes seasons. It doesn't just add to numbers, it takes the whole world tick and determines the season, day and time based on the variables Malkin mentioned.
If what I've read is correct, you could change the variables Malkin mentioned, and the entire calendar would change. It's retroactive.
With that in mind, knowing how long each season is, and how long each day is, you could, with a little bit of simple math, determine how far you are from the next season, within an acceptable margin of error. |

Geek2Nurse
 

|
6/1/2012 | |
Is the DATE command actually for game dates? When I briefly tested it, it looked like it returned real-world info, so I skipped right past it. I'll give it another look.
I don't have to know *exactly* how far into a season it is...I just want to have a rough idea. I'll check out DATE and see what I can do with it. Thanks for the input!
---
Optimist: the glass is half full.
Pessimist: the glass is half empty.
Engineer: the glass is twice as big as it needs to be. |

Moe
  

|
6/1/2012 | |
It should return the date within the current season. You have to use RTIM to parse for real date values. |

Geek2Nurse
 

|
6/2/2012 | |
Yep, it's working great! I don't know where my head was when I looked at it the first time and thought it didn't do what I want!
---
Optimist: the glass is half full.
Pessimist: the glass is half empty.
Engineer: the glass is twice as big as it needs to be. |

AquaShee
   
|
6/5/2012 | |
You could do some math on the WTIK variable to find out exactly what season it is, what time it is in said season and even which year it is. The length of a day is counted in ticks, not actually minutes. The variable just uses minutes for readability.
So if 50 milliseconds are a tick, one minute would be 1200 ticks. 20 minutes then becomes 24000 ticks.
So:
1 day = 24000 ticks
1 season = 96000 ticks
1 year = 384000 ticks
I think, not sure, that the game uses a similar method to calculate a creature's age for display, since the only commands used to retrieve a creature's age are also in ticks.
The Community Scribble: make (y)our own metaroom! |