Day/nigt in wads
Day/nigt in wads
Is there a wad with a working (or simulated) day/night cycle? Or something which actually shows that time flows from day to night and it has consequences on the map and/or gameplay?
- Ryan Cordell
- Posts: 4349
- Joined: Sun Feb 06, 2005 6:39 am
- Preferred Pronouns: No Preference
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia (Modern GZDoom)
- Location: Capital of Explodistan
Code: Select all
SCRIPT << 0 >> OPEN
{
switch(timer())
{
case 0:
ChangeSky("SKY1NIGH","");
fadeto(0,0,0,0.0,1300);
break;
case 360:
ChangeSky("SKY1DAWN","");
fadeto(0,0,0,0.3,1100);
delay(1500);
break;
case 600:
ChangeSky("SKY1DAY","");
fadeto(0,0,0,0.5,1000);
delay(1500);
break;
case 960:
ChangeSky("SKY1DAWN","");
fadeto(0,0,0,0.2,980);
delay(1500);
break;
}
}It works more by real time, so you'll have to wait a lenghty while for the sky to change.
It doesn't work for the whole game, as in a global script, it resets on each level.
The timer used for that is also included here:
Code: Select all
SCRIPT 302 ENTER
{
int t;
while(TRUE)
{
t = Timer() / 35;
HudMessage(d:t/60, s:":", d:(t%60)/10, d:t%10;
HUDMSG_PLAIN, 300, CR_RED, 0.95, 0.95, 2.0);
delay(1);
}
}- Bio Hazard
- Posts: 4019
- Joined: Fri Aug 15, 2003 8:15 pm
- Location: ferret ~/C/ZDL $
- Contact:
- Bio Hazard
- Posts: 4019
- Joined: Fri Aug 15, 2003 8:15 pm
- Location: ferret ~/C/ZDL $
- Contact:
- Bio Hazard
- Posts: 4019
- Joined: Fri Aug 15, 2003 8:15 pm
- Location: ferret ~/C/ZDL $
- Contact:
Aha!
That'll be it then.
Code: Select all
//Commented Out by Tormentor667, Reason: It looks odd in outdoor areas, if the
//light of the sky changes, but the sectors light itself stays, someone might
//reactivate this feature, if he wants to apply this to 1000's of sectors :)
/*script 999 open // Time of day script
{
light_fade (32,110,2625);
delay (2625);
light_fade (32,200,2625);
delay (2625);
Restart;
}*/- Ultraviolet
- Posts: 1152
- Joined: Tue Jul 15, 2003 9:08 pm
- Location: PROJECT DETAILS CLASSIFIED.
It's a lot easier if you don't detail stuff Tormentor-style. 
Could be pretty good in GZDoom if you're primarily using dynamic lights and don't have any stepping-lit sectors. You keep the outdoor sectors at one light level, the indoor sectors that have light coming in from outside at a slightly lower level, and the closed indoor sectors at a very low light level. That's three tags for sectors without any other effects, and for each one with its own unique effect, you'd need another tag... But it ends up better than if you were using sector-based lighting.
It's too bad there's not a way to set up a flag system like DMFlags for determining sector effects. You could lay out a flag table in, I don't know, MAPINFO or something, with arbitrary help-text by each definition, and then have some special bit set that tells the sector to use what you've specified in the tag field as a flag sum instead. Then a plugin or config or whatever for whichever editor could make the various bits available as checkboxes with your arbitrary MAPINFO names beside them. Passing thought...
Could be pretty good in GZDoom if you're primarily using dynamic lights and don't have any stepping-lit sectors. You keep the outdoor sectors at one light level, the indoor sectors that have light coming in from outside at a slightly lower level, and the closed indoor sectors at a very low light level. That's three tags for sectors without any other effects, and for each one with its own unique effect, you'd need another tag... But it ends up better than if you were using sector-based lighting.
It's too bad there's not a way to set up a flag system like DMFlags for determining sector effects. You could lay out a flag table in, I don't know, MAPINFO or something, with arbitrary help-text by each definition, and then have some special bit set that tells the sector to use what you've specified in the tag field as a flag sum instead. Then a plugin or config or whatever for whichever editor could make the various bits available as checkboxes with your arbitrary MAPINFO names beside them. Passing thought...
- Project Shadowcat
- Posts: 9369
- Joined: Thu Jul 14, 2005 8:33 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia with Vulkan support
- Location: Blacksburg, SC USA
- Contact:
I thought about doing that through Ultra-Voilet's method all the way throughout my (20% complete) mod, but with a real time clock (and even a chronometer tucked away in the top-right of the screen). Time could step forward significantly through the author's ability to get a player from one area to another; however the author wants to do their intermissions.
It does sound easy, just a bit time-consuming and making sure all of the tags are correct.
I don't know. It seems cool on paper, but would one notice, even if the clock was slightly accelerated (ala The Sims, Grand Theft Auto III and beyond)?
It does sound easy, just a bit time-consuming and making sure all of the tags are correct.
I don't know. It seems cool on paper, but would one notice, even if the clock was slightly accelerated (ala The Sims, Grand Theft Auto III and beyond)?
