Hi again.
I would like to tell Uru to set automatically the fog of an Age depending of a precise number of hour, in order to have a daytime/nighttime cycle.
It would set the line "Graphics.Renderer.Fog.SetDefColor" (and "Graphics.Renderer.Setyon" if possible).
Gira, Kemo and Payiferen already use it, but it seems it doesn't use any Python file for this. Is it in the PRP and how can I reproduce it ? Thanks a lot.
Automatic fog settings
Re: Automatic fog settings
I don't think the fog is changing for those ages, but however, they have an animated sun. To get the sky to change color dramatically they also use a plLayerSDLAnimation that changes the ambient color of the layer.
The plLayerSDLAnimation is possible if you're using PlasmaMax, but I'm not entirely sure if it possible in the main branch of PyPRP (It's in GPN's contrib though). The animated sun is a very easy and doable thing to do with PyPRP; just insert keyframes for the sun's intensity, color, and/or position and rotation. For the time of day to affect the animation, use a ageglobalanim. http://www.guildofwriters.com/wiki/Animations should explain that. I've used animated suns before and they're pretty great, however, you must be careful to have your outdoors areas completely dynamically lit (no lightmaps or shadelessness). A tip for making the outdoors realistically lit at night or during the day is setting all your objects to have their vertex paint black (or, the darkest you ever want the objects to get). Hopefully this was helpful.
If you just want to change the fog, you'd need to set up a python file with a timer callback that updates the color of the fog according to the time of day SDL.
The plLayerSDLAnimation is possible if you're using PlasmaMax, but I'm not entirely sure if it possible in the main branch of PyPRP (It's in GPN's contrib though). The animated sun is a very easy and doable thing to do with PyPRP; just insert keyframes for the sun's intensity, color, and/or position and rotation. For the time of day to affect the animation, use a ageglobalanim. http://www.guildofwriters.com/wiki/Animations should explain that. I've used animated suns before and they're pretty great, however, you must be careful to have your outdoors areas completely dynamically lit (no lightmaps or shadelessness). A tip for making the outdoors realistically lit at night or during the day is setting all your objects to have their vertex paint black (or, the darkest you ever want the objects to get). Hopefully this was helpful.
If you just want to change the fog, you'd need to set up a python file with a timer callback that updates the color of the fog according to the time of day SDL.
Currently getting some ink on my hands over at the Guild Of Ink-Makers (PyPRP2).
-
- Deep Island Admin
- Posts: 2972
- Joined: Mon May 05, 2008 5:50 am
- MOULa KI#: 0
- Location: Germany
Re: Automatic fog settings
Actually, there is an age with time-depending fog in MOUL, it's Negilahn. The nglnFogTweener is controlling that. The source seems to be general enough to work for other ages, too - it takes the "Battery Updated SDL" as first argument and registers for that SDL, but never actually uses it.
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
Re: Automatic fog settings
Hmmm... yes, I saw a few time something as "VAR Agetimeofday" in the SDLs...
But my problem with animated Suns is... well... In fact I used "/fogcolor 0 0 0" in Ae'Gura and was wondering if I could have the MOUL's fog (a bit brighter than in CC) going gradually to this one and then to the original one again... (another problem with your method is that the city is already wide enough, and it would increase lags)
That's since I heard about the Pellets and algae cycle that we could never saw as Cyan removed the Light Meter.
About Negilahn fog tweener, I don't know how it really controls the fog as I never saw any kind of "night time" there. But I'll see.
Thanks to both of you.
But my problem with animated Suns is... well... In fact I used "/fogcolor 0 0 0" in Ae'Gura and was wondering if I could have the MOUL's fog (a bit brighter than in CC) going gradually to this one and then to the original one again... (another problem with your method is that the city is already wide enough, and it would increase lags)
That's since I heard about the Pellets and algae cycle that we could never saw as Cyan removed the Light Meter.
About Negilahn fog tweener, I don't know how it really controls the fog as I never saw any kind of "night time" there. But I'll see.
Thanks to both of you.
Re: Automatic fog settings
Sirius wrote:I would like to tell Uru to set automatically the fog of an Age depending of a precise number of hour, in order to have a daytime/nighttime cycle.
Of course, I do not know how to do



-
- Deep Island Admin
- Posts: 2972
- Joined: Mon May 05, 2008 5:50 am
- MOULa KI#: 0
- Location: Germany
Re: Automatic fog settings
Well, it is not fog settings
.- Gira uses "nomal" SDL animations for layers and objects and lights to accomplish this astonishing effect.
The only ages with dynamic fog are Negilahn (time-dependant) and Minkata (where the fog gets denser as you get farer away from the cage, and is disabled when you enter a cave).

The only ages with dynamic fog are Negilahn (time-dependant) and Minkata (where the fog gets denser as you get farer away from the cage, and is disabled when you enter a cave).
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
Re: Automatic fog settings
Thank you for the explanations Diafero. Each day I learn a bit more! 

Re: Automatic fog settings
Hey, I got it working !
I used a fog setting based on Negilahn. So, I have a fog going from 0 0 0 (midnight) to .4 .3 .1 (noon). The sunset is .3 .25 .1, and the sundown .35 .2 .05 (however, the fog settings are not only these four - they are going from one to another smoothly).
In Negilahn, the fog is updated every 10 seconds. In the city... well, on each link in. Is there a way to update it more often ?
I used a fog setting based on Negilahn. So, I have a fog going from 0 0 0 (midnight) to .4 .3 .1 (noon). The sunset is .3 .25 .1, and the sundown .35 .2 .05 (however, the fog settings are not only these four - they are going from one to another smoothly).
In Negilahn, the fog is updated every 10 seconds. In the city... well, on each link in. Is there a way to update it more often ?
-
- Deep Island Admin
- Posts: 2972
- Joined: Mon May 05, 2008 5:50 am
- MOULa KI#: 0
- Location: Germany
Re: Automatic fog settings
Using a timer, this should be possible. You will need some changes in the Python as the city does not have an AGETIMEOFDAY.
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
"Many people's horizon is a circle with a radius of zero. They call it their point of view."
Deep Island Shard | Offline KI
Re: Automatic fog settings
AGETIMEOFDAY, ok. In which Python file the other changes should be located ? Is it only in the FogTweener, or also in the default python file ?