|
Molly
|
 |
« on: January 28, 2010, 06:47:01 am » |
|
I managed to catch Thotter, when he peeked out of his hole, and forced him to code the DG_scripts part of seasons and Moon Phases. So all Builders will now be able to work with these variables in their zones and quests, which could add some extra spice to them.
For example Werewolvs can now turn at the appropriate time, and stay in the wolf shape as long as the full moon lasts, fruits can ripe on trees in autumn, birds can lay eggs in spring and fledlings can hatch in summer. And magic herbs for potions can be collected when the moon is in the waning crescent phase, for better effect.
Below is some code info about how ro use the new feature:
To get the current season, do %time.season%. The seasons are: winter (month 0-3), spring (month 4-7), summer (month 8-12) and autumn (month 13-16). Note that the total amount of months is 17, and that summer has 5 months. All other seasons have 4 months.
To get the current moon phase, do %time.moon%. The moon phases are: "full", "waning gibbous", "last quarter", "waning crescent", "new", "waxing crescent", "first quarter" and "waxing gibbous". For example, if something in a script should only happen if the moon is waning gibbous, do if %time.moon% == waning gibbous %echo% leprechauns take over the world end Keep in mind that %time.moon% will return the current moon phase even if it's daytime.
This should be implemented fully now. (See the post in the scripting board). It has not yet been tested in praxis though, but I am about to do that soon.
|
|
|
|
« Last Edit: December 02, 2010, 06:23:17 am by Molly »
|
Logged
|
|
|
|
|
Molly
|
 |
« Reply #1 on: December 02, 2010, 06:40:47 am » |
|
Here is some basic info about how the Time system is set up in 4D.
hour = 0-23 /day day = 1-35 /month week = 7 days month = 0-17 /year year = 560 days moon phases (see below) seasons (see below)
(Not sure how many weeks in a month though, but that probably doesn't matter, since they don't have names, like the days and months and years).
Moon phases: full / waning gibbous / last quarter / waning crescent / new / waxing crescent / first quarter / waxing gibbous
Months and Seasons: Winter Season: Snow / Wolf / Frost Giant / Old Forces Spring Season: Grand Struggle / Buds / Nature / Futility Summer Season: Dragon / Sun / Heat / Battle Fall Season: Dark Shades / Shadows / Long Shadows / Ancient Evil / Great Evil ----
Each pulse = 0.1 second 1 tic = 72 seconds, 24 tics/day, 35 days/month = 840 T 17 months/year = 14280 T so there are 24 tics for every mud day which equals about 29 rl minutes
Or approximately: 30 rl min = 1 mud day = 25 tics 1 rl hour = 2 mud days = 50 ticks 2 rl hour = 4 mud days = 100 ticks 5 rl hour = 10 mud days = 250 ticks 10 rl hours = 20 mud days = 500 ticks
20 ticks = 1400 seconds = 22 minutes, 8 seconds 100 ticks = 7000 seconds = 117 minutes, 4 seconds = 1 hour, 57 min 1028 tics = 20 rl hours 500 ticks = 10 rl hours 200 ticks = 4 rl hours 100 ticks = 2 rl hours
Just to complete this info, could one of you coder guys please post the names of the days in the week?
|
|
|
|
« Last Edit: February 14, 2011, 09:54:17 am by Molly »
|
Logged
|
|
|
|
|
Tocharaeh
|
 |
« Reply #2 on: December 02, 2010, 02:52:25 pm » |
|
This was the best post ever, Just sayin' 
|
|
|
|
|
Logged
|
-Tocharaeh D'Araesth The Dirty Ol'' Drow that time left behind in fear of obliteration!
|
|
|
|
Prometheus
|
 |
« Reply #3 on: February 24, 2011, 04:49:59 pm » |
|
I talked to Molly and she said it is okay to post Moon Phase days and lengths.
So here goes: New Moon (1 to 4) (4 days) Waxing Crescent (5 to 9) (5 days) First Quarter (10 to 13) (4 days) Waxing Gibbous (14 to 17) (4 days) Full Moon (18 to 22) (5 days) Last Quarter (23 to 26) (4 days) Waning Gibbous (27 to 30) (4 days) Waning Crescent (31 to 35) (5 days)
|
|
|
|
|
Logged
|
|
|
|
|
Tocharaeh
|
 |
« Reply #4 on: February 25, 2011, 01:16:13 am » |
|
wow, interesting. So now we are actually seeing time pass by. Neato.
|
|
|
|
|
Logged
|
-Tocharaeh D'Araesth The Dirty Ol'' Drow that time left behind in fear of obliteration!
|
|
|
|
Asmodeus
|
 |
« Reply #5 on: February 27, 2011, 09:44:54 am » |
|
It would be nice to have a help file on the moon phases, where it lists what Prom just posted. I've been having to come back here all the time to look it up, so it would just make life easier.
|
|
|
|
|
Logged
|
|
|
|
|
Tocharaeh
|
 |
« Reply #6 on: February 28, 2011, 03:32:10 pm » |
|
it shall be done.
|
|
|
|
|
Logged
|
-Tocharaeh D'Araesth The Dirty Ol'' Drow that time left behind in fear of obliteration!
|
|
|
|
Tocharaeh
|
 |
« Reply #7 on: February 28, 2011, 05:26:09 pm » |
|
it has been done.
|
|
|
|
|
Logged
|
-Tocharaeh D'Araesth The Dirty Ol'' Drow that time left behind in fear of obliteration!
|
|
|
|
Asmodeus
|
 |
« Reply #8 on: February 28, 2011, 06:56:23 pm » |
|
If this were facebook, I would like that post.
|
|
|
|
|
Logged
|
|
|
|
|
Prometheus
|
 |
« Reply #9 on: March 02, 2011, 06:00:38 pm » |
|
Now moon phases are in the help files. There is an odd bug in when the code writes the help file it whacks the permissions making additional changes not save till the file permissions get "reset" which I have been doing. And I have a feeling if the game crashes before the permissions are fixed the help file won't get written. Now I or another coder needs to figure out why the code writes the file the wrong way 
|
|
|
|
|
Logged
|
|
|
|
|
Tocharaeh
|
 |
« Reply #10 on: March 03, 2011, 01:42:41 am » |
|
heh oh well. Least it got in after I made it 
|
|
|
|
|
Logged
|
-Tocharaeh D'Araesth The Dirty Ol'' Drow that time left behind in fear of obliteration!
|
|
|
|