Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

[RELEASED] Lux Water

Discussion in 'Assets and Asset Store' started by larsbertram1, Jun 18, 2018.

  1. bobadi

    bobadi

    Joined:
    Jan 3, 2019
    Posts:
    580
    this second thing comes from DWP2
    lux2a.gif

    and actually the first one also seems to be caused by DWP2 particle system

    it probably should be the foam caused by boat on water surface. do you know how to set these up properly?
     
    Last edited: May 6, 2023
  2. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    you should get rid of it. or make it way bigger so it covers the entire scene including the far ocean. but the reflections fropm this probe look kind of broken anyway.
     
  3. bobadi

    bobadi

    Joined:
    Jan 3, 2019
    Posts:
    580
    you probably missed the picture and description (the boat wake foam particle system is the cause) for the first issue. (if you don't know, I'll ask dwp author)

    one more thing. I haven't seen in the documentation: how do you control the ocean wave height?

    thanks for helping.
     
  4. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    oh, i do not know anything about these particles.
    https://docs.google.com/document/d/...m38h-u3Az-ozaaOX0/edit#heading=h.cz7ftkn4x2dk
     
    bobadi likes this.
  5. hulk2011

    hulk2011

    Joined:
    May 10, 2015
    Posts:
    2
    Hi,
    Can anyone help with an issue i have. Please see screenshot. There is a brown fog on the surface going into the distance. Ive spent 2 days trying to get rid of it with no success. Im not even able to change the color of it. Any help would be appreciated!
     

    Attached Files:

  6. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    that looks like unity's built in fog. do you use anything like aura or enviro? if so you will have to tweak the shaders as described in the documentation.
     
  7. hulk2011

    hulk2011

    Joined:
    May 10, 2015
    Posts:
    2
    Thank you for the response. I have enviro but fog is turned off. Is there a default unity fog ive missed?
     
  8. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    there might be, yes.
     
  9. bobadi

    bobadi

    Joined:
    Jan 3, 2019
    Posts:
    580
    Last edited: May 31, 2023
  10. Monil

    Monil

    Joined:
    Apr 24, 2012
    Posts:
    100
    Hi,
    I use this:

    Code (CSharp):
    1. Shader "Unlit/WaterCut"
    2. {
    3.     Properties
    4.     {
    5.         _Color("Main Color", Color) = (1,1,1,1)
    6.     }
    7.     SubShader
    8.     {
    9.         Tags { "RenderType"="Opaque+100" }
    10.         LOD 100
    11.         Cull Off
    12.         ZWrite On
    13.         ZTest Always
    14.         Blend Zero One
    15.         ColorMask 0
    16.         Lighting Off
    17.         Fog { Mode Off }
    18.        
    19.         Pass {
    20.             Color[_Color]
    21.         }
    22.     }
    23. }
     
  11. bobadi

    bobadi

    Joined:
    Jan 3, 2019
    Posts:
    580
    hey, thanks. this finally works.
     
  12. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    Hi,
    When I run the game in the editor it works fine but once compiled the ocean doesn't appear, there are just left and right parts when I press shift. what is it from?
    Unity 2022.3 - built-in
    thanks


     
  13. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    Now it doesn't work in game either. The ocean appears for 1/2 second then disappears.
     
  14. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    i never heard of something like this. it looks like a something writes into the depth buffer.
     
  15. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    it happened suddenly. The day before it was fine.
     
  16. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    I used Occlusion and the ocean came back in game but still not compiled.
    Unity amazes me every day, even after 10 years of use!
     
  17. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    might be missing depth. from the docs:

    Forward Rendering
    When using forward rendering you have to make sure that your camera renders a depth texture. Do so by adding the LuxWater_CameraDepthMode script to your camera. In case you do not use Metal and deferred rendering leave “Grab Depth Texture” unchecked.

    and please check the included demos if they have the same issue.
     
  18. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    it does not work. The ocean appears for only 1 second. Here are my settings.

     
  19. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    there is a lot of stuff on your camera.
    could you please check the included demo scenes and see if the water renders properly there?
    if so, go back to your scene and disable all additional component from your camera except the ones needed by lux water. then enable one ofter the other and see if any of these break the water.
    curious about "ms under water effect" e.g.
     
  20. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    MS Under water Effect is used to see R.A.M 2019 items underwater - River Auto Material
    I put the same parameters as in the demos.
    If I disable everything, the ocean still disappears.
     
  21. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    when I press shift to run it pops up a bit.

     
  22. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    please check the demos. altho you thin you are using the same params you might have missed something.
    again: i have never heard of anything like this before. so most likely you just have forgotten something :)
     
  23. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    it worked before. Then the next day, I had this defect.
    I put the same parameters as in the demos.
    On the other hand, if I advance towards the invisible ocean, I have the underwater effects.
     
  24. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,835
    sounds like something is messed up. have you checked the demo scenes already?
     
  25. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    It works but I don't know why. No doubt magic?
    I loaded an old scene where it was working, then reloaded the scene that had a problem and everything was back to normal.
    It wasn't just the ocean that had disappeared, but also a river created with RAM 2019 Auto River
    Unity remains a mystery sometimes.
     
  26. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    but it still does not work when the project is compiled!
     
    Last edited: Jul 14, 2023
  27. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    I'm coming back because the problem came back for no reason.
    I put the same parameters as in the demo. Here are the screens of my ocean and my camera. In game the ocean always disappears.
    When I started my project, I copied and pasted the ocean from the demo to my project. Could it be from this?



     
  28. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
  29. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    I created my ocean like this:
    I copied and pasted the infinite ocean from the demo. Could my problems come from there?
     
  30. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    I have this message with debug:
     
  31. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    :):):)
    the cause of my worries did not come from Lux Water but from the character that I had installed. This is the "Modular First Person Controller" Asset :mad:.
    I removed it and put a normal controller. The bug is gone! :p
     
    Last edited: Jul 26, 2023
  32. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    how to use Lux Water scripts to create an underwater effect for an ordinary body of water (no Lux Water) ? I tried several things but it didn't work.
     
  33. stigmamax

    stigmamax

    Joined:
    Jun 30, 2014
    Posts:
    218
    I'm sorry, I kinda wrecked your sub