Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

[RELEASED] UniStorm 4.2 - AAA Procedural Volumetric Clouds, Weather, Sky, Cloud Shadows, & More!

Discussion in 'Assets and Asset Store' started by BHS, Jan 27, 2012.

  1. batonPiotr

    batonPiotr

    Joined:
    Apr 8, 2016
    Posts:
    5
    Thanks for the response!

    I have checked the value and it was set to 1. When I set it back to 1.72 it will be reseted as soon I enter the play mode. When I tested this on both projects, the asset was downloaded directly from the asset store in both cases. Strangely I didn't touch this value before and it looked correct in editor and on iOS build. Only Android seems to have issues.
     
  2. neshius108

    neshius108

    Joined:
    Nov 19, 2015
    Posts:
    109
    Hello @BHS: I have a question about the sun/moon altitude and angles.

    I am trying to make an Arctic world, so I would need to be able to make the moon, say, be move in a different way than "normal". Or for example, I would need to make the sun rise later and set earlier. Is that possible?

    In the documentation (maybe outdated? https://unistorm-weather-system.fandom.com/wiki/Documentation ) I see some settings called DayLengthHour and NightLengthHour, are those anywhere? Basically being able to tell UniStorm to have the sunrise at 8AM but show the sun above the horizon from 11AM (3 hours long sunrise) till 2PM and then have a 3 hours long sunset till 6PM when the night begins.

    I am using these tools for the data:
    - https://www.mooncalc.org/#/80.0672,95.4492,3/2020.02.29/00:00/1/3
    - https://www.suncalc.org/#/80.5176,94.5352,3/2020.02.29/20:21/1/3

    Thanks and great work!
     
    Last edited: Apr 20, 2020
  3. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Thanks for the info and screesnhots. I'll look into this and figure out a solution.
     
  4. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Strange, the last time I tested Android, everything was working correctly. I'll look into this and get a solution out as soon as possible.
     
  5. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Those docs are very outdated. The DayLengthHour was originally used to determine the hour the system would start using the day length variable. For now, you can adjust the sun angle, which allows the sun and moon to be closer to the horizon. You cannot specifically control the latitude and longitude, but I do plan on adding this at some point. You could also control length in which a sunrise and sunset will be, you could use a HourEvent to change the over all speed of the in-game time to give the appearance of longer sunrises and sunsets.

    Code (CSharp):
    1. ---
    2.  
    3. public int SunRiseLength = 60;
    4. public int SunSetLength = 60;
    5. public int NormalDayLength = 30;
    6.  
    7. void Start
    8. {
    9.    UniStorm.UniStormSystem.Instance.OnHourChangeEvent.AddListener(() => ChangeDayLength());
    10. }
    11.  
    12. void ChangeDayLength ()
    13. {
    14.    //Set the DayLength according to SunRiseLength
    15.    if (UniStorm.UniStormSystem.Instance.Hour == 8)
    16.    {
    17.       UniStorm.UniStormManager.Instance.SetDayLength(SunRiseLength);
    18.    }
    19.    else if (UniStorm.UniStormSystem.Instance.Hour == 11 || UniStorm.UniStormSystem.Instance.Hour == 18)
    20.    {
    21.       UniStorm.UniStormManager.Instance.SetDayLength(NormalDayLength);
    22.    }
    23.    else if (UniStorm.UniStormSystem.Instance.Hour == 16)
    24.    {
    25.       UniStorm.UniStormManager.Instance.SetDayLength(SunSetLength);
    26.    }
    27. }
    28.  
    29. ---
     
    KillerKahuna likes this.
  6. batonPiotr

    batonPiotr

    Joined:
    Apr 8, 2016
    Posts:
    5
    Thank you! I will test around a bit too. I'll let you know if I find the source of the issue.
     
  7. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    Hello I have a problem with flipped camera .
    I use this code to flip camera and the cloud and the sky doesn't work.
    Any idea how to fix this?


    Code (CSharp):
    1.  
    2. using UnityEngine;
    3. [RequireComponent(typeof(Camera))]
    4. [ExecuteInEditMode]
    5.  
    6. public class Reverse_Camera : MonoBehaviour
    7. {
    8.     new Camera camera;
    9.     public bool flipHorizontal;
    10.     void Awake()
    11.     {
    12.         camera = GetComponent<Camera>();
    13.     }
    14.     void OnPreCull()
    15.     {
    16.         camera.ResetWorldToCameraMatrix();
    17.         camera.ResetProjectionMatrix();
    18.         Vector3 scale = new Vector3(flipHorizontal ? -1 : 1, 1, 1);
    19.         camera.projectionMatrix = camera.projectionMatrix * Matrix4x4.Scale(scale);
    20.     }
    21.     void OnPreRender()
    22.     {
    23.         GL.invertCulling = flipHorizontal;
    24.     }
    25.  
    26.     void OnPostRender()
    27.     {
    28.         GL.invertCulling = false;
    29.     }
    30. }
    31.  
     
  8. Astaelan1

    Astaelan1

    Joined:
    Sep 29, 2015
    Posts:
    192
    infinitypbr likes this.
  9. dajyareo

    dajyareo

    Joined:
    Dec 7, 2014
    Posts:
    8
    Hello @BHS
    I just picked UniStorm up the other day and ran into an issue with what appears to be a rendering refresh rate issue of some kind. Occasionally the clouds will just pixelate up and freeze for a moment before continuing to render. It seems to be random, but is easier to reproduce if I move the camera round a lot (I think). It looks like this image:

    frozen clouds.png

    Are you aware of this issue, and if not, what information can I provide to help narrow it down?
    Thanks!
     
  10. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    I'm not exactly sure, but I would recommend looking into the UniStormClouds.cs, renderClouds.shader, or volumetricClouds.shader files to see if these may be stopping your flip camera script from behaving correctly as they modify the cloud dome's position.
     
  11. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Strange, I don't believe I've seen this issue before. If possible, could you please PM a video of the issue so I can get a better idea of what's happening?
     
  12. sandBucket2

    sandBucket2

    Joined:
    Mar 26, 2016
    Posts:
    29
    Hey BHS,

    I'm trying the heavy rain setting at night time. The skybox is dark but there is no rain effect
    the rain effect only happens at times other than night
    any help would be appreciated and thanks!
     
  13. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    The rain material has a slider that controls how much the ambient lighting can affect it. Try adjust this to see if it helps.
     
  14. PerunCreative

    PerunCreative

    Joined:
    Nov 2, 2015
    Posts:
    109
    Any ETA regarding 4.2?
     
  15. ChoChick

    ChoChick

    Joined:
    Jul 18, 2016
    Posts:
    39
    I have Motion Blur enabled in Post Processing.
    I want to prevent Volumetric Clouds from being affected by Motion Blur, but I don't know how.
    I confirmed that Motion Vectors of Clouds is Force No Motion.
     
  16. ASIM-SENYUVA

    ASIM-SENYUVA

    Joined:
    Apr 29, 2013
    Posts:
    71
    Is it working with High Definition Render Pipeline ( HDRP ) ? I installed bu not working atm. any patch around ?
    Unity3d 2019.3.11f1 / HDRP 7.3.1
     
  17. sandBucket2

    sandBucket2

    Joined:
    Mar 26, 2016
    Posts:
    29
    That didn't work :\ I've tried adjusting the ambient blend strength slider from 0 to 1. I've also tried adjusting the Soft Particles Factor, that didn't work either. Does night time rain work on your side?

    Also the lightning is behaving differently in the build vs editor. When the lightning strikes, all my point lights turn off temporarily until the lighting has finished. Any help is appreciated and thanks!
     
  18. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    can you share some current progress o 4.2 , I can't wait? :)
     
  19. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    He told us that currently there is no enough plugin/resource to upgrade unistrom to HDRP.
     
  20. Tornado77

    Tornado77

    Joined:
    Nov 14, 2018
    Posts:
    83
    @BHS will 4.2 improve the celestial system? I made a review on the asset store that cover most of the problems with the celestial system. It might help you for the next update.
     
  21. franky_li

    franky_li

    Joined:
    Aug 8, 2016
    Posts:
    158
    Hi BHS,
    I have some Problems with UniStorm (Unity 29.3.12f1 Windows 10 64 bit)
    1. UniStorms doesn't starts with some preselected weathers, e.g. when I select Thunderstorm for start weather it starts with Rain.
    2. It shows a border between horizon and skybox. (This wasn't the case in the previous versions)
    3. I have a heavy frame drop when US is active.
    Direct light:
    upload_2020-5-11_17-8-25.png

    UniStorm no clouds, weather type Clear: Look at the visible line on the horizon and at the frame rate.
    upload_2020-5-11_17-9-9.png
     
  22. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    May be you was accidentally zoom the game window .So it will looks like pixel
     
  23. Sp4rk

    Sp4rk

    Joined:
    Sep 24, 2012
    Posts:
    10
    Hello @BHS . I've been having troubles for a while now. I finally gave up and came asking for help!
    I'm having a problem that could be the same from the above quote. For some reason that I can't seem to figure out alone, Cloud Shadows show above even my fog. And it isn't nice.
    Also, my grass (from the FAE package, the same one you show in the Asset Store page to showcase the Stylized cloud), shows this strange square around it when Cloud Shadows are enabled.
    Have you ever got a solution for that problem?


    Also, the "horizon" line isn't quite right. You can see it in the above picture, but it really sucks when we are talking about any stormy weather:

    I've tried to lower the "Cloud Height" parameter, I even edited a little bit the code to make it possible to enter values below 500, but it showed no difference at all.

    Since I'm already bugging you, does Unistorm have any option to make the Cloud Shadows harder? More... Edgy? I've tried to set the Resolution to a lower number, but I haven't got the result I was looking for. I was looking for a more cartoonish look, something like this:


    Sorry for the long post! I'm using Unity 2018.4.15f1
    Thank you for such an amazing asset
     
  24. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    I'm hoping for the end of this month.
     
  25. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    What I would try is to use two cameras as explained here: https://forum.unity.com/threads/rel...oud-shadows-more.121021/page-108#post-4928939

    Have a separate image effect profile for your UniStorm camera that doesn't include the motion blur. The main camera will render everything else as normal. It would just exclude UniStorm and its clouds.
     
  26. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    I've just been working on finalizing some additional features which include an option to apply dithering to UniStorm's clouds and atmospheric fog to reduce banding and make the fog and sky look a lot smoother, an option to make fog and cloud colors adjustable for each weather type, an option to allow the sun to update based on customizable seconds which allow much cleaner looking shadows, and more. I've also been working on redoing the demo system's lighting and colors to more closely resemble that AAA look.
     
  27. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Thanks for the suggestions. 4.2's focus is the addition of atmospheric fog and a few requested features to the UniStorm editor, as well as improving the included system's lighting and colors. I can certainly make improvements to the UniStorm's celestial system as you've suggested with the following update.
     
  28. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Hey there, Are you receiving any errors when this is happening? This typically happens when UniStorm cannot find a player and camera within the scene. Did you set your player and camera's tags through the UniStorm editor under the Player & Camera tab?
     
  29. ChoChick

    ChoChick

    Joined:
    Jul 18, 2016
    Posts:
    39
    I tried following the link instructions, but the clouds are still motion blurred.
    1. Create MainCamera and UniStormCamera.
    2. Created UniStormLayer. UniStormLayer is set for UniSorm Volumetric Clouds, UniStorm Stars, and UniStorm Moon Object.
    3. Set UniStormCamera tag to UniStormCamera. Clear Flags to Skybox. Depth 0. Added only UniStormLayer to Culling Mask.
    4. Set MainCamera tag to MainCamera. Clear Flag is Depth Only. Depth 1. Removed UniStormLayer from Culling Mask.
     
  30. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    The cloud shadows sometimes cause artifacts on custom shaders. I believe I've fixed this with the updated cloud shadows with version 4.2. I'm not sure why it would be drawing over the fog. You can try adjusting the placement/order of the cloud shadows image effect on the camera to see if it helps. I would try putting it above all other image effects.

    The horizon line will be fixed with 4.2 when using UniStorm's new atmospheric fog as it blends the clouds with the skybox.

    The cloud shadow shader is based on a texture directly from the generated clouds. So, if you use a cleaner or softer cloud profile, it should give you more control over how the cloud shadows look. You can also increase the cloud shadow intensity within each weather type object.
     
  31. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Are you using the Post Processing Stack v2? You could try excluding the UniStorm objects' layer using a Post Process Layer.
     
  32. ChoChick

    ChoChick

    Joined:
    Jul 18, 2016
    Posts:
    39
    PostProcessingStackV2 (Ver2.1.7) is used.
    PostProcessLayer component is added to MainCamera.
    Volume blending Layer [Postprocess].
    Post-process Volume object's Layer [Postprocess].
    I have not added the PostProcessLayer component to the UniStorm camera.
     
  33. sandBucket2

    sandBucket2

    Joined:
    Mar 26, 2016
    Posts:
    29
    Hello,

    I'm still having issues with the lightning behaving differently in the build vs editor. When the lightning strikes, all my point lights turn off temporarily until the lighting has finished.
     
  34. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Hey there,

    This is because you need to increase your Quality’s Pixel Light Count as shown, as the first setting under the Rendering section, to a higher value to handle all the lights you have in your scene.

    452F9E5C-126A-474A-99C7-4A99B9421747.png
     
  35. RZGames_Jethro

    RZGames_Jethro

    Joined:
    Jul 6, 2017
    Posts:
    28
    hey @BHS we integrated Unistorm in our project, It looks quite nice, congrats on the asset.
    One thing we are having problems with it water, it doesn't seem to react to the day night cycle.
    Is there a particular setup or particular water system u recommend to make reflection and such work with Unistorm?
     
  36. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Thanks! It depends on the water system you are using. Some water systems have an option to take into account the color of the skybox. If yours doesn't, you will need to control the color or tint of the water manually through the water material. This can be done with something like the following code:

    Code (CSharp):
    1. public Gradient WaterColor; //Create a gradient variable that will control the color of the water for each time of day, similar to UniStorm's gradient colors.
    2.  
    3. void Update ()
    4. {
    5.    //Update the water continuously based on UniStorm's internal time and the WaterColor gradient.
    6.    TheWaterMaterial.SetColor("TheWaterColorVariableName", WaterColor.Evaluate(UniStorm.UniStormSystem.Instance.m_TimeFloat));
    7. }
     
  37. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    hi, haven't used unistorm in a long time, nice to see development is still going, so i'm working on a new project and i understand that HDRP is not supported, but what about Universal? and also is there a way to control the cloud speed with time ie if i skip 5 hours it will show the clouds moving faster, at the moment the cloud speed doesn't look like it does much
     
  38. RZGames_Jethro

    RZGames_Jethro

    Joined:
    Jul 6, 2017
    Posts:
    28
    ok thanks and yes thats what i did.
    Although are there some packages out there that react to your system? Like Weather changes or is it the saame should we implement it ourselfs in the water shader? we are using the Unity water shaders (trying the water4 ones) for now.
     
  39. PerunCreative

    PerunCreative

    Joined:
    Nov 2, 2015
    Posts:
    109
    Hi,

    what is the current status of the 4.2 version? We are mainly looking for the optimization compared to the current version

    Thanks
     
  40. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    URP mostly works, but there's a few materials that need to be updated through Unity's "Upgrade Project Materials to URP Materials" button.

    Cloud speed will need to be controlled manually through code if you want to increase it during runtime. This can be done using the following code:

    Code (CSharp):
    1. Material m_CloudsMaterial = FindObjectOfType<UniStorm.Utility.UniStormClouds>().skyMaterial;
    2. m_CloudsMaterial.SetFloat("_uCloudsMovementSpeed", YourCloudSpeed);
     
  41. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    There are some water systems that have options to take some of their color from the skybox source. Unity's Water4 does not have this option.

    Each weather type has options to adjust the sun intensity so this will most likely be taken into account for weather changes and the water shader. Adjusting the water color for each time of day should allow it to shade properly.
     
  42. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Hey there,

    4.2 is just about finished. I plan on submitting it today or first thing tomorrow.
     
    Weblox and PerunCreative like this.
  43. Autarkis

    Autarkis

    Joined:
    Oct 10, 2011
    Posts:
    299
    Hi,
    I've seen some issues reported with single-pass instanced for VR builds with Unistorm.
    I just wanted to check if there's been any progress on a fix ( if it's possible.)
    With URP, I need to use single-pass to get shadows to show up in both eyes, but that breaks unistorm in the right eye ( nothing shows up.)
     
  44. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    I just submitted UniStorm 4.2 and I will be addressing the issue with single-pass with the very next update. I hope to have this out as soon as possible.
     
  45. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Hey everyone!

    Version 4.2 has been submitted and is awaiting approval. My apologies for the 4.2 update taking so long. It ended up being quite a bit more work than I expected.

    In addition to the new atmospheric fog feature and improved cloud performance, I have also rewrote a decent portion of UniStorm's cloud shader to provide improved shapes and shading to more accurately resemble clouds.

    I have also addressed all issues with Linear Color Space. A new default UniStorm system has been added that uses the exact same settings from the new UniStorm Demo Video. If possible, it is recommended that Linear Color Space is used instead of Gama Color Space.

    Here's an updated video of UniStorm 4.2's improved clouds, lighting, and fog all using Linear Color Space.


    Release Notes
    • Added custom atmospheric fog which takes into account the sun and moon's light direction and color which is applied to the scene, UniStorm clouds, and the skybox.
    • Added Radial Distance option for UniStorm's Fog to the UniStorm Editor.
    • Added Dithering option to the UniStorm Editor to remove banding with UniStorm fog.
    • When using UniStorm's new atmospheric fog, the blending of the horizon and the lower part of the skybox is seamless and shaded to match UniStorm current fog color, even where the sun or moon are affecting it.
    • Performance with version 4.2 has been significantly improved to that of 4.1. Version 4.1's Ultra ran at about 350~ (using a GTX 1080 with Vsync disabled), but with occasional performance spikes. This has been addressed and resolved with version 4.2's Ultra running at a more consistent ~800 fps (using a GTX 1080 with Vsync disabled and also using UniStorm's new atmospheric fog).
    • Performance has also been drastically improved for both Mobile and VR versions of UniStorm.
    • Added improved support for Linear Color Space as some internal settings needed to be adjusted for this option. Linear Color Space is now highly recommended as it provides the best results.
    • Added a Linear Color Space UniStorm System which uses the same settings as seen in the new UniStorm Demo Video.
    • Added Linear Color Space support for all weather effects.
    • Added settings to control UniStorm's sun light shafts to the UniStorm editor.
    • Added settings to control UniStorm's moon light shafts to the UniStorm editor.
    • Added the ability to alter fog color per weather type instead of using a global variable from with the UniStorm editor.
    • Added the ability to alter cloud color per weather type instead of using a global variable from with the UniStorm editor.
    • Added an option to the Weather Type editor to adjust the height of the fog on UniStorm's clouds.
    • Rewrote a decent portion of UniStorm's cloud shader to look less "poofy", have more intricate cloud shapes, improved shading at the upper portions of the clouds, and added detail to the base of clouds to give them more texture. This all greatly improves the looks of the clouds allowing them to look more realistic.
    • Added an option to increase convergence speed to allow the clouds to be updated quicker. This allows them to look clearer and look clearer during movement, at the cost of using more performance.
    • Updated all particle effects' materials to use the lit particle option allowing for improved visuals for weather effects.
    • Tweaked all particle effects to look better and be more evenly distributed around the player.
    • Added Hazy weather type to showcase UniStorm's atmospheric fog.
    • Added an easy to use update to 4.2 feature for all previous versions of UniStorm. All you have to do is press the "Update to Version 4.2" with the UniStorm Editor.
    • New and improved terrain for demo scenes.
    Fixes
    • Improved the clouds so they initialize faster on Start.
    • Improved screen space cloud shadows shader to shade more accurately and minimize artifacts that sometimes happened.
    • Fixed an issue that didn't allow the stars to follow the player correctly.
    • Fixed an editor scaling issue when using 4k monitors.
    • Fixed an issue that sometimes didn't allow the Weather Type editor to properly save the values entered.
    • Fixed an issue that sometimes didn't allow the Cloud Profile editor to properly save the values entered.
    • Fixed an issue with the UniStorm Editor's menu buttons and Unity 2019.3+.
    • Fixed an issue with the rain shader value that didn't allow it to reach the max rain shading value.
    • Increased lightning brightness on clouds.
    • Lowered the default intensity of UniStorm's moon light shafts as they were too bright.
    • Switch Wind Zone to Directional.
     
    Last edited: Jun 19, 2020
  46. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    Thank you for do the hard work. The v.4.2 is very Brilliant.
    By the way it is already released now , right?
     
    Last edited: Jun 16, 2020
  47. RandAlThor

    RandAlThor

    Joined:
    Dec 2, 2007
    Posts:
    1,277
    Congratulation on releasing.

    Can you please tell me if there is a solution in UniStorm to set the weather on special days like a calender where i can plan not only seasons but also each day if i wish, or some days?

    Then i want to ask if i have bioms like areas where i can set special weather for different areas? For example if i get higher on the mountain it gets colder but also on a flat terrain there is good weather at the most places but on some areas there is bad weather.

    Also will this work with floating point error fix? For multiple streaming terrains if i use world streamer for example?
     
  48. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,264
    Thanks and you're welcome. No, I forgot to mention in the post (which I've now updated) that this was to inform everyone that the 4.2 update has been submitted. It should be live sometime tomorrow.
     
    nu51313932 likes this.
  49. reptilebeats

    reptilebeats

    Joined:
    Apr 28, 2012
    Posts:
    272
    Hi thanks, sorry for late reply, i don't seem to get notifications anymore, yes i noticed a few things are not supported, for the most part though everything works fine, lightshafts not working is a shame but i can work around the few niggles, still a hell of a lot quicker than trying to make my own.
    would just drop to legacy but I want to get a better handle on some of the new features that are locked to render pipelines
     
  50. nu51313932

    nu51313932

    Joined:
    Oct 28, 2016
    Posts:
    46
    Hello.I just tested the version 4.2.

    1.How can I decrease the sun light range around the sun spot or remove it?. it is too big for my video game project that use low camera field of view.(THe low sun spot quality in version 4.1 is match to my project)

    https://sv1.picz.in.th/images/2020/06/19/qMDfTE.png
     
    Last edited: Jun 19, 2020
unityunity