Advanced Day Night Cycle

Another thing. As I understand it, your blueprint takes complete control of the two directional light (sun and moon) intensity, overriding any value I set in the editor. In this way (without editing the blueprint) I cannot change the sun light intensity, which stays at quite low values (2.something if I remember correctly). Why not take the value we set in the editor as the max sunlight and moonlight values?

Hello ,

With Color Grading Intensity set to above 0.5 , it is quite difficult to get the result you want , as those Look up textures override the default sky brightness. In my post process blendables pack , there is one Diffuse Light shader that is going to achieve the color grading effect and also keep the sky brightness as desired. Back at the time when I created Daylight system I had no idea how to create Blendable materials , but since you mentioned the issue , I am going to add the Diffuse light shader with Daylight System in later release , so that you have more control towards diffuse and ambient color and intensity.

Thanks! Yesterday, I was able to improve a the color of the sky in the direction I wanted by manipulating the color curves.

Another thing: how can I change the time and date at runtime? I tried both to change the value of ā€œGame Date Timeā€ in the editor, and the value of the same variable using a blueprint, and the simulation did not update itself.

Make sure to set ā€œUse system date timeā€ to false, and then from your own BP , take a reference to the daynightcycle BP , and then set game date time variable accordingly. That should work.

I think I did precisely that, but it does not work. This is my level blueprint:

A trigger volume activates the event, that then should change the time from night to mid day - but the change has no effect. ā€œuse system date timeā€ is set to false.

Hey ,

See this is the code getting executed in the daynight BP

You can collapse the entire code into a function , say Set Current UTC , and after you are setting your datetime value , just call this function.

Bringing it back from the dead :slight_smile:

I just found out this plugin while don’t research in order to make the exact same thing myself and while I have no problem creating most of the functionality, I really liked the lookup tables and that’s something I hadn’t even thought myself. So I’m really interested in buying this.

But before I do, I have a question. From what I saw on the YouTube video, while the sun and moon are moving fine, the stars remain stationary for the whole night. Is that changed in later versions? Or I’ll need to create a new star map and calculate its movement myself to get that functionality? I’m trying to make a sailing simulation of the 18th century or so and as such being able to use a sextant to find your position is quite important to me and that’s not possible with stationary stars :slight_smile:

The stars are just from the default sky material ue4 provides.
You can definitely add your own starmap with panning logic and plug it in the sky material.

Thanks for the reply… I’ll probably get it in 2-3 weeks or so…

guys!
help me plz.
nothing happened,no way to compile,many warnings.i can’t find the problem,i don’t know what to do.have anyone ever met such a problem.

Looks like you broke some of the logic somehow. I’d recommend reinstalling the plugin to your project.

Hi Sameek - Nice plugin and its proving quite handy for my archaeological PhD project. However is it possible to implement a feature to switch the year into BC to allow for dates in antiquity? I’ve attempted a negative year number but this doesn’t carry through to execution. I’m currently trying to understand the maths behind the plugin to see if this is possible to insert.

Also as an aside could you list the equation(s) used in your sun position algorithm? It would really help in my write up (full credit will be given to yourself of course).

Hey , since it t akes Julian Day , I guess it should work for BC upto a certain limit , but the following website contains a ppt which covers the necessary formula that will give you a better idea -