No announcement yet.

[TUTORIAL] Quick Time-of-Day Setup

  • Filter
  • Time
  • Show
Clear All
new posts

    AlexW88, the TOD v. 1.2 was still looking as intended as far as the lighting and shadows go, even in 4.8. I could always go back to that version and post some screens if needed. I'll also investigate more on my end and make sure the lights match up inside the new v. 1.4 BP to the way I had my original lights in the scene that were used in v. 1.2.

    Edit: I can confirm that v. 1.3 keeps the lighting matching the editor and while playing too, brightly lit with shadows. I think it's due to the fact the Sun and Moon directional lights (along with a Sky Light) are contained in the BP for v. 1.4. I messed around with the light settings in the BP for 1.4 and could not recreate what I wanted. So keeping the 2 directional lights outside of the BP works for me for now. I also don't have a sky light in my current scene.
    Last edited by RHopperArchimage; 06-24-2015, 07:44 PM.


      That's strange, in my testing the fact that the lights were in the blueprint didn't make any difference. Are you sure the skylight in the blueprint isn't washing out the shadows?
      Fully dynamic Time of Day System blueprint: Download it for free now!


        I think that might be the case Greg...I'll look into that.


          Hai Greg, Thanks a ton for providing this to us. It fulfills everything I need in a Day-Night cycle system.
          I am though wondering how I would go about making a light turn on at a specific time of day.
          Would really appreciate some help!


            You would need to check if the CurrentMinute is greater than a specified value (not equals, since it's a float). So say you wanted streetlights to turn on at 6PM, you could do "if CurrentMinute > 1080, turn on lights", 1080 being the number of minutes that correspond to 18 hours (18 hours from midnight is 6:00pm)
            Fully dynamic Time of Day System blueprint: Download it for free now!


              Thank you for sharing, great work!! Anyone know how to block sun light in a cave?
              Last edited by Asukitex; 07-10-2015, 02:01 PM.


                This is great! I have been trying a lot of different day night cycles and this one is solid. One tip, change your auto exposure Minimum up to around 1 in Post Process so you can get a nice moonlit night.


                  Hi gregdumb,

                  so cool - thanks a lot for this contribution! I Implemented your Day Night cycle in my project and it works like a charm. Just one question: When running a "Map check" I get the following error:

                  "BP_DayCycle_SkyDome_C1 Large actor receives a pre-shadow and will cause an extreme performance hit unless bcastDynamicShadow is set to false"

                  I do have some really large meshes in my level, but if they were the problem, this message should be reffering to one of those meshes and not your blueprint setup, right? Is there anything in your blueprint, which could cause this error? I'm using your 1.4 Version.

                  Any hints much appreciated! Thanks a lot

                  Edit: Using Engine 4.8.3
                  Last edited by andtheand; 08-07-2015, 06:20 AM.


                    Hey Greg, this is great stuff! I'm having a few issues though (v1.4):

                    No stars or clouds.
                    Blueprint Compile error, I've compiled everything multiple times, message log isn't giving me more info than TimeOfDayTemplate failed to compile.

                    Using 4.9.2



                      Amsome work man, I am using this system as the basis of a day night cycle system in my current project, I'm going to extensively edit it but it has gone a long way in helping me solve a few of the more difficult problems I was having. Thanks alot


                        This is awesome work! Been trying to make one for 4 weeks now, but this has everything one could ever possibly need!
                        Only thing I'm wondering about is that the sun rises in the west and sets in the east. Thought it was the other way around. At least where I live haha.
                        Is there an easy way to change/fix this? Thanks for the help in advance


                          Found it already, just change rotatevectoraroundaxis from x=1 to x=-1 and the direction offset from 180 to 0 in set sunpitch. That way the sun is in the south and rises and sets from east to west.
                          Now I need to find a way to turn the moon off/on. And prevent the unlit mode during nights. Any thoughts on this anyone? Thanks!


                            The tutorial on the wiki works perfectly. Thanks.

                            However I tried running 1.4 in UE 4.9 and when I load up the included level, I get an error since I need to replace an reference variable called "Unknown" in the level blueprint. What exactly am I supposed to put there?


                            There are also two directional lights called "To delete" and "To delete as well", am I supposed to delete them? Are there some other steps required to get this to run?
                            Last edited by Gmi; 10-31-2015, 10:27 AM.


                              Works perfectly in UE4.9 thanks a lot for this!

                              Edit: One small thing I noticed, started off using the default 3rd person template and copied the floor and just moved it up as a roof. With the time set at 12 so the sun is straight above me the South side of the building has light leaking in the top corner all the way across.

                              Screenshot to show what I am talking about:

                              As I walk toward that wall the light will eventually disappear but when I back up away from the wall the light comes back.
                              Last edited by Echosyp; 11-02-2015, 08:07 PM.


                                Hey Greg,

                                I set up your day night cycle seeing as it was better than my own which used timelines to change the time. And I ran into a snag that I cannot seem to debug. The clouds and sun move perfectly fine, however the actual lighting cast upon the scene is the reverse of what time of day it is. For example the sun will /rise/ visually and everything will be getting darker from here the sun will fully rise and be high in the sky visually and the actual light available in the scene will be completely dark! Any fix or ideas?
                                Rule#117: "Be polite, be professional, but have a plan to kill everyone you meet."