I forgot to say this, but if your changing the color of the moon texture and the glow, you probably want to change the color of the directional light that the moon is using. This ensures that the clouds have accurate coloring based of the moon texture.
How to make a clock or slider, when we move it, we also change the time? I tried to do, but the way it always moves, my changes were immediately reset. That is, I set 5 hours, but after that time the sun immediately returns to where it was
Is there a proper way to update the solar time during runtime? You can change the variable solartime and tell it to update the sun, set date, etc and nothing happens. what am i missing? This works in the editor with no issues, the problem happens once you hit play and then changes the values in blueprints during runtime. Just does whatever it was set to do in the editor.
I might do that in the future (no guarantees though :-) ). What specifically do you mean with randomized clouds during the time of day? Random speeds? Random directions? Is there anything specific you have in mind?
Oh that's great! I was thinking to have the clouds changing randomly like, intensity, speed, direction, maybe even color to have darker clouds near a storm. Next step will be to have the rain and lightnings. 😅
I've been trying to do, but I couldn't get to rotate the moon light correctly faster than the sun to match a moon cycle (28 days). But it should not be that difficult, you need to rotate the moon a bit faster than the sun, so just add a bit of speed to it so every day it gains an offset. Then you should calculate the degree distance of the Sun and the Moon to input into a mask to turn part of the moon black (could easily be a black circle passing through it). But I've been thinking about the rotational problem. The sun rotation is calculated by a C++ class that does all sorts of calculations, it could output directly as well the positions for the Moon, but that's beyond my expertise right now. meh
Oh yeah, now it looks cool. I won't torment you, but if you want, you can finish the material and add textures of different phases of the moon, because the moon's binding to time and date has already been in previous lessons, the same binding can be used to change the texture. Although of course I haven't seen this in any game yet.🌚
Haha don't worry about tormenting me, I like hearing more suggestions. For the moon phases, I might do that in the future, since I think another sphere mask could be used to make that. I'm finishing the day night cycle after the video I'm releasing tomorrow (automatic lights that turn on or off based on the day night), but I that doesn't mean that I can't make more videos that add features to it :-).
@InsertNameHereGameDev thank you so much for these videos. I love your teaching style. There is one thing though i must comment on. Up to this point we have a day/night cycle and nice looking moon for a whole year. but one thing is missing and breaks immersion for me and that is its always a FULL moon. Can you do a video tutorial on how to implement the phases of the moon based on the month variable? Also if its not to much trouble adding a layer to the atmosphere down at the horizon level or some kind of material mask to the moon that makes the moon appear more yellow when its lower on the horizon due to dust in the atmosphere like in real life
amazing tutorials, direct to the point, easy to follow and it works! But I would love to see an idea on how to make the moon cycle going crescent and such, probably that would require a calculation to offset the moon light source during the time and add some kind of block mask circle to cut out the moon right?
That is almost precisely what is needed. For the moon offset though, while you can do that effort, for real time games you can probably just mask of the moon in a light function and reduce it's brightness to simulate that (although it's not gonna be perfect). I had another comment that asked about this, and I said that I might do this in the future, but I can't give a timeframe when that would be done. :-)
Please bro make a tutorial on shooting stars and if you want as a bonus how to add niagara effects to the time. I want to add particle affects top the sky but I dont know how to add thaI dont how to add that to our sky.
Check that the correct light index was used with the light direction node at 5:19 (directional light index 1 is the moon in my day/night cycle, so if you use 0 then the glow will be on the sun). If that doesn't work, try multiplying the the mask value form the Skybox Image node with RadialGradientExponential output shown at 11:40 .
@@InsertNameHereGameDev I had the correct light index in the direction node but the glow still shows up on both the moon and the sun. My workaround was to multiply the glow with the SkyAtmospshereLuminance result that's used to make the stars fade away during the day. Your latter suggestion works though and is a cleaner solution, thanks!
there is a black box around my moon. double checked all the steps and dont know whats causiing it ans when i remove the moveglow box from the second lerp we added it disappears
if i want to expand this to add seasons should i add an post process volume inside of my DaynightCycle and add some logic to chage stuff inside of it depending of months right?
Thanks, this tutorial is awesome and really easy to follow. If you're thinking about coming back to this type of tutorial, could you do a tutorial on adding moon phases?
I followed your method to create the Glow around the moon, but after completing it, the Glow still appears in the sky during the daytime. Can you help me identify where I might have gone wrong?"
Try multiplying the the mask value form the Skybox Image node with RadialGradientExponential output shown at 11:40. That's an error on my part, sorry. :-(
I meant timestamps in the video :-), but here is an idea of what you should do (this code should be added in the moon glow code): drive.google.com/file/d/1gyOc2YrAocEBwEZWyV_XgbtVuzpIZzyu/view?usp=sharing
Oh, I greatly appreciate your patience. After using the method you provided, it's effective. There's a somewhat strange phenomenon: the Glow of the moon is active in the play mode, but when viewed in the editor window, it doesn't have Glow. Is this normal?@@InsertNameHereGameDev
However, there's an interesting thing. 😀Due to my misunderstanding that 11:40 is the time of the day-night transition, it unexpectedly led me to another method: I used the moon's descent time to obscure its Glow. I created an animation in the Blueprint Timeline, passed it to the "Scalar Parameter Value," and created a "Material Parameter Collection" to call it. All of this happened before your latest reply. I believe your method is more concise. Is the approach I mentioned more resource-intensive?@@InsertNameHereGameDev
I forgot to say this, but if your changing the color of the moon texture and the glow, you probably want to change the color of the directional light that the moon is using. This ensures that the clouds have accurate coloring based of the moon texture.
How to make a clock or slider, when we move it, we also change the time? I tried to do, but the way it always moves, my changes were immediately reset. That is, I set 5 hours, but after that time the sun immediately returns to where it was
Is there a proper way to update the solar time during runtime? You can change the variable solartime and tell it to update the sun, set date, etc and nothing happens. what am i missing? This works in the editor with no issues, the problem happens once you hit play and then changes the values in blueprints during runtime. Just does whatever it was set to do in the editor.
I use UE for animation/rendering and this was by far the best tutorial I found to make a sky system to light my outdoor environments thank you!!!
Now we need to have the clouds moving randomly with the time of the day. 😃
Many thanks for your great video.
I might do that in the future (no guarantees though :-) ). What specifically do you mean with randomized clouds during the time of day? Random speeds? Random directions? Is there anything specific you have in mind?
Oh that's great! I was thinking to have the clouds changing randomly like, intensity, speed, direction, maybe even color to have darker clouds near a storm. Next step will be to have the rain and lightnings. 😅
Awesome tutorial, cheers 😁
One feature I'd be really interested in is phases of the moon, would you happen to have looked into that before?
I've been trying to do, but I couldn't get to rotate the moon light correctly faster than the sun to match a moon cycle (28 days). But it should not be that difficult, you need to rotate the moon a bit faster than the sun, so just add a bit of speed to it so every day it gains an offset. Then you should calculate the degree distance of the Sun and the Moon to input into a mask to turn part of the moon black (could easily be a black circle passing through it). But I've been thinking about the rotational problem. The sun rotation is calculated by a C++ class that does all sorts of calculations, it could output directly as well the positions for the Moon, but that's beyond my expertise right now. meh
Oh yeah, now it looks cool. I won't torment you, but if you want, you can finish the material and add textures of different phases of the moon, because the moon's binding to time and date has already been in previous lessons, the same binding can be used to change the texture. Although of course I haven't seen this in any game yet.🌚
Haha don't worry about tormenting me, I like hearing more suggestions. For the moon phases, I might do that in the future, since I think another sphere mask could be used to make that. I'm finishing the day night cycle after the video I'm releasing tomorrow (automatic lights that turn on or off based on the day night), but I that doesn't mean that I can't make more videos that add features to it :-).
great tutorial, can you do an extra tutorial for the rotation of the cloud? thank you
Can you create a Random Dynamic Weather system with this setup. Ive been struggling to create one.
I might do that in the future, but it won't be the near future.
@@InsertNameHereGameDev Alright! I shall try my best then.
@InsertNameHereGameDev thank you so much for these videos. I love your teaching style. There is one thing though i must comment on. Up to this point we have a day/night cycle and nice looking moon for a whole year. but one thing is missing and breaks immersion for me and that is its always a FULL moon. Can you do a video tutorial on how to implement the phases of the moon based on the month variable? Also if its not to much trouble adding a layer to the atmosphere down at the horizon level or some kind of material mask to the moon that makes the moon appear more yellow when its lower on the horizon due to dust in the atmosphere like in real life
Would it be possible to add moon phases, new moon, full moon, waxing and waning?
When the moon is up at zenith in the sky , the moon texture rotate 180° , why ?
amazing tutorials, direct to the point, easy to follow and it works! But I would love to see an idea on how to make the moon cycle going crescent and such, probably that would require a calculation to offset the moon light source during the time and add some kind of block mask circle to cut out the moon right?
That is almost precisely what is needed. For the moon offset though, while you can do that effort, for real time games you can probably just mask of the moon in a light function and reduce it's brightness to simulate that (although it's not gonna be perfect). I had another comment that asked about this, and I said that I might do this in the future, but I can't give a timeframe when that would be done. :-)
When I apply the Glow to the moon, the mask doesn't work, which makes the moon have a black square around it.
use the file on the description :)
I am impressed.
Thanks :-)
Please bro make a tutorial on shooting stars and if you want as a bonus how to add niagara effects to the time. I want to add particle affects top the sky but I dont know how to add thaI dont how to add that to our sky.
I believe I did everything correctly, but the moon glow somehow appears on the sun as well
Check that the correct light index was used with the light direction node at 5:19 (directional light index 1 is the moon in my day/night cycle, so if you use 0 then the glow will be on the sun). If that doesn't work, try multiplying the the mask value form the Skybox Image node with RadialGradientExponential output shown at 11:40 .
@@InsertNameHereGameDev I had the correct light index in the direction node but the glow still shows up on both the moon and the sun. My workaround was to multiply the glow with the SkyAtmospshereLuminance result that's used to make the stars fade away during the day. Your latter suggestion works though and is a cleaner solution, thanks!
Thanks for pointing out that the solution works. It might help someone out in the future when they watch the tutorial :-).
there is a black box around my moon. double checked all the steps and dont know whats causiing it ans when i remove the moveglow box from the second lerp we added it disappears
use the file on the description :)
if i want to expand this to add seasons should i add an post process volume inside of my DaynightCycle and add some logic to chage stuff inside of it depending of months right?
Thanks, this tutorial is awesome and really easy to follow. If you're thinking about coming back to this type of tutorial, could you do a tutorial on adding moon phases?
thanks for this wonderful three parted tutorial! I'm very new to unreal engine, I wonder how you've learnt all of this stuff :0
Thank you for the tutorial!
I followed your method to create the Glow around the moon, but after completing it, the Glow still appears in the sky during the daytime. Can you help me identify where I might have gone wrong?"
Try multiplying the the mask value form the Skybox Image node with RadialGradientExponential output shown at 11:40. That's an error on my part, sorry. :-(
Thank you for your answer. But I don't know how to control time in the material.@@InsertNameHereGameDev
I meant timestamps in the video :-), but here is an idea of what you should do (this code should be added in the moon glow code):
drive.google.com/file/d/1gyOc2YrAocEBwEZWyV_XgbtVuzpIZzyu/view?usp=sharing
Oh, I greatly appreciate your patience. After using the method you provided, it's effective. There's a somewhat strange phenomenon: the Glow of the moon is active in the play mode, but when viewed in the editor window, it doesn't have Glow. Is this normal?@@InsertNameHereGameDev
However, there's an interesting thing. 😀Due to my misunderstanding that 11:40 is the time of the day-night transition, it unexpectedly led me to another method: I used the moon's descent time to obscure its Glow. I created an animation in the Blueprint Timeline, passed it to the "Scalar Parameter Value," and created a "Material Parameter Collection" to call it. All of this happened before your latest reply. I believe your method is more concise. Is the approach I mentioned more resource-intensive?@@InsertNameHereGameDev