Search Unity

SUIMONO - Customizeable Water System [RELEASED]

Discussion in 'Assets and Asset Store' started by chingwa, Aug 11, 2012.

Thread Status:
Not open for further replies.
  1. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Ahhh I see... well, it's most likely the water_presets component overriding your settings then. Try turning it off, or removing it from your water_surface entirely... If this is indeed what the problem is, you can either leave it off, or you can create your own preset with whatever your preferred settings are, and use that instead. Check out the creating your own preset tutorial here:

    http://tanukidigital.com/forum/index.php?topic=4.0
     
  2. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    I tried removing that to no avail! The only time it would stop doing it was taking it out of the water module itself but i found it strange because i tried disabling most of the scripts in there to see what was going on but it kept resetting, also tried breaking the prefab or making my own, still no luck

    Making my own preset is probably the best idea to be honest so thanks for that, the sun rises eventually so using your transition part of the preset component would be perfect, cheers
     
  3. AaronVictoria

    AaronVictoria

    Joined:
    Aug 21, 2010
    Posts:
    176
    Works great Chingwa, I figured out why I wasn't getting the same affect. I set up the rive mesh as a fork, so it was flowing the path of all the uv directions. When I separated the extensions, I get a good flow as you demonstrated. I'll use particles to add more detail. It seems to work great for us. I don't really see anything else we need, but I'll let you know if something comes up.
     
  4. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
  5. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    thanks lazygunn! I had used that post as a point of reference for the wave flowmaps, and it should still be relevant for water flow as well. I'll take a second look at the mentioned editor... :)
     
  6. RonHiler

    RonHiler

    Joined:
    Nov 3, 2011
    Posts:
    207
    Hey Chingwa,

    Can you tell me about the performance of Suimono in comparison to the pro-water that ships with Unity Pro? I'm having a severe draw call jump problem with pro-water with just a simple small pool in my level (draw calls in that spot in my level jump from 1130 with the water off to 3300 with the water on), which is causing my frame rate to drop precipitously.

    I was going to buy your water solution anyway (I love the ice and lava effects, both of which I will need later on, as well as the water, and if you can get the whole river thing worked out, WOW!), but if you can tell me it will also help with my performance issues, I will buy it today! :)

    [EDIT: Ah, I see someone asked this question already over on page 7, my apologies for reasking an already answered question]
     
    Last edited: Nov 2, 2012
  7. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi Ron, no problem, thanks for your interest! I actually had done some drawcall testing with various components of Suimono, which may interest you as well...

    First you can directly compare Suimono and Water4 using the same scene here (fps counter is in top left):

    Island Scene running Suimono:
    http://www.tanukidigital.com/suimono/demo/test_island3.html

    Island Scene running Water4:
    https://dl.dropbox.com/u/56593963/Unity/WebPlayer/WebPlayer.html


    the image below details the stats window info I get while running the Island Scene demo on my dev computer. As there are a few components with Suimono that can be turned on and off, I'm showing the differences in drawcalls for each component.

    The base water shader takes 9 drawcalls, and then it goes up depending on which components you add. Two of the components, the caustic effect projector and especially the dynamic reflection component are dependant on the scene that they are going in, the more complex the scene is, the more drawcalls these 2 components will take. However with each there are also options to disable certain layers and tweak the rendering distance resolution etc. that may decrease the drawcall count.

     
  8. dansav

    dansav

    Joined:
    Sep 22, 2005
    Posts:
    510
    Looks great.
    Really need an ios version.

    Can you explain how buoyancy is calculated?
     
  9. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    oop yep, i'd like to add to that, i bought this for SM3+ stuff but! a simple version for sm2 would be brlliant, especially if you could go for an almost cartoony appearance, shoreline flowmaps, some kind of surface animation (Asking for windwaker's a bit much but something more on a stylistic edge), or at least an ability to tweak it to cartoony in an sm2 environment
     
  10. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    @dansav - The buoyancy is calculated by a few user controllable settings. There aren't 3d waves in Suimono (at least not as of ver 1.32), so the buoyancy peak is based on the y-height of the water plane. once an object enters the water, if buoyancy is enabled, a force is applied to raise the object back to the water surface at a given time-frame. You can read more specifics about this on the documentation page here:
    http://www.tanukidigital.com/suimono/documentation/#_objectbuoyancy

    @lazygunn - I realize that even the basic shader is still classed as SM3. I'll have to take a look at that. The look of the water surface is mainly determined by the textures it's given, so you could certainly do a cartoony-look now using new textures.

    As far as iOS/Mobile is concerned, this is still not something I can commit to, but perhaps in the new year this will be more of a possibility.
     
  11. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi guys, this is just a heads-up to let you all know that I updated Suimono to version 1.4.
    This is mainly to fix a bug in the most current version of Unity 4 where refraction bleeding was occuring. Version 1.4 is available on the Asset Store right now.

    Ver 1.4 change list:
    NEW - added new script 'water_colorCalculations' - this script attaches to a Water_Surface prefab and automatically adjusts fog colors based on the game fog render settings. This is helpful to recalculate water fog color, if you're general game lighting and fog color is changing over time.
    FIX - Refraction Bleeding errors in released version of Unity4 have been fixed.
    CHANGE - edited shaders and ramp texture for a smoother specular / hot specular effect on all surfaces.
    CHANGE - edited default wave flowmap texture to Truecolor mode. This gives very smooth looking waves!
     
    Last edited: Nov 29, 2012
  12. Venged

    Venged

    Joined:
    Oct 24, 2010
    Posts:
    500
    Are there any pictures or video of what it looks like in the free version of Unity?

    Thanks

    Robert
    AKA Venged
     
  13. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi Robert, I don't have pictures posted anywhere, but you can try the demo...

    Suimono Demo (ver 1.32)

    By default it's set to Unity Pro, but there is a toggle in the UI where you can pick just "Unity". Toggling back and forth will show you the differences between the Pro version and the free version. ;)
     
  14. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    Your water (Unity free or Pro) is not showing (only a fucsia solid color is displayed on the water object) in my computer at job. It has an old Intel 82945G Express chipset on the graphics part but I have tested the Unity water 4 on it and it displays well, in the simplest settings.
     
  15. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    That's a pretty old graphics card... it only partially supports Shader Model 2, and as noted by lazygunn above Suimono is currently using Shader Model 3, even for the basic shader. For the next update I'll either be changing the basic shader to SM2, or supplying a further setting that supports SM2. I don't know if this will work on your card though, as I read online it doesn't have full hardware support of SM2.
     
  16. Venged

    Venged

    Joined:
    Oct 24, 2010
    Posts:
    500
    Thanks! I just tried the demo. This still looks great for the free version of Unity and encourages me to go Pro asap. This is must have for me. Great Job!!
     
  17. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Awesome! Thanks for the feedback Venged! I hope Suimono will suit your needs, both now and in the future! :)
     
  18. Venged

    Venged

    Joined:
    Oct 24, 2010
    Posts:
    500
    Wow this is just wonderful in Unity Free! I must grab this. Other packages don't have any under water effect. This is great

    Thanks
     
  19. bravo075

    bravo075

    Joined:
    Dec 7, 2012
    Posts:
    32
    Greetings, will this work in the standalone version of Unity?
     
  20. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    @venged - Thanks for the kind words Venged!

    @ bravo075 - Yes, it works with both standalone and webplayers for PC / MAC / LINUX... in both Unity and Unity Pro. :)
     
  21. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,756
    wow, how fast does it perform on android/ios ? got any stats on a regular iphone 3gs or nexus one for instance?

    also, is the mobile version available?
     
  22. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    version 1.5 will have SM2 compatible shaders included, but mobile currently isn't officially supported, thus I don't have benchmark info for you. Of course just like EskimoJoe you can modify the code to suit any specific needs you have in your projects.
     
  23. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,756
    Yep I was asking him since he just ported it :)
    Was it hard?

    Also, can you guys make big waves with this software? I only see flat river like demos, nothing with deep sea on a thunderstorm ;)
     
  24. WendygoGames

    WendygoGames

    Joined:
    Dec 11, 2012
    Posts:
    53
    This asset looks amazing! If I ever need to do anything with water, I definitely would want to do it with this.
     
  25. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    @creat327 - no this isn't really meant for ocean type water, with waves etc. Currently Suimono does not generate height wave effects (but in the future... who knows?) :)

    @StraightRainbow - thanks for the encouragement!
     
  26. Zozo2099

    Zozo2099

    Joined:
    Jul 15, 2012
    Posts:
    478
    Please can I know if it is compatible with Unity 4?
     
  27. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi Zozo, yes it works just fine in Unity 4, including DX11. :)
     
  28. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Just a quick note to let you guys know that Suimono version 1.45 is now on the Asset Store. This is a quick bug fix only, and 1.5 is still coming soon with a couple new features and improvements

    This specifically fixes a bug with exported builds not retaining shader information, which meant any water surfaces using the non-full shader would break once outside of the editor environment. This update adds a "shader References" attribute to the quality selector script which will now index all the available shaders on external builds.
     
  29. shwa

    shwa

    Joined:
    Apr 9, 2012
    Posts:
    461
    Hi,

    I've just done a web build, and adding Suimono to my scene added about 12 megs to my web player.
    Seems like alot to me.

    What's the best way to slim things down or really slim things down?

    For this project, i only need 1 choice of surface water and the underwater look/feel.
    I don't need splashes, or sounds, etc.

    thanks,

    shwa
     
  30. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    hi shwa, the heaviest part of the Suimono system are the textures... specifically there are two components that perform a texture swap every frame in order to provide an animated texture effect...

    1) "WaterModule_caustic Effect" which is on the WATER_Module prefab - this component contains an array of 32 textures which it cycles through at the given caustic fps and animation speed. You can either, reduce the number of textures in this array, reduce their resolution, or remove this component entirely. (if you remove this component, you may also want to remove the "caustics_projector" child object under your WATER_Surface objects.

    2) "Water_animation" which is on the WATER_Surface prefab - similar to above, this contains a cycled array of textures that enhance the wave animation effect of the water surface. Again, you can either reduce the number of textures, or reduce the resolution of each texture, or remove this component entirely

    This should reduce Suimono's download footprint quite a bit. Of course you can also reduce the resolution of some of the other textures as well if you still need it to be smaller (ex. tex_wave_norm, or tex_FlowMap if you are using it).

    Let me know if this helps!
     
  31. shwa

    shwa

    Joined:
    Apr 9, 2012
    Posts:
    461
    Thanks for this info and the speedy reply!
     
  32. MicrogameStudio

    MicrogameStudio

    Joined:
    Jan 9, 2013
    Posts:
    7
    Bought it and I'm happy, this water system is really awesome!
     
  33. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    It's great to hear this kind of feedback, thanks! :)
     
  34. Tinus

    Tinus

    Joined:
    Apr 6, 2009
    Posts:
    437
    Suimono looks really good, nice work! I'd like to purchase it, but there is one thing I want to make sure first.

    I'm building a skydiving game and am dealing with rather large draw distances (anywhere up to 10km) and am worried about performance impacts for water surfaces that large. Does the scale of a Suimono surface affect performance at all? Also, are there any artifacts (apart from z-fighting with other objects) that I should be worried about? I need to be able to view the water both from up close and from afar, and get decent results. :)

    Here's a gameplay video for reference (currently using Unity's default water):

     
  35. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi Tinus,

    The actual size of the water plane has no real affect on the performance of Suimono. The individual elements you choose to use, such as realtime reflection and attributes associated with it, will certainly affect performance, but the plane geometry that comes as a prefab in Suimono will scale to practically any size without any noticeable performance increase. If you set the water up at a size of 1km and are happy with the performance, then the performance should be the same whether you scale it to 50km or 0.25km.

    As far as up close vs long distance. I haven't run into any visual problems as of yet. There is a built in scale attribute which you can use to scale the water normals as you get closer/ far away if you need finer control over this. You can also scale the water textures directly. Take a look at the Suimono shader attributes at the link below for a good idea of the amount of control you have...

    http://www.tanukidigital.com/suimono/documentation/#_shd

    By the way, great work on Volo Airsport... I've been silently following your project for quite a while :D
     
  36. Tinus

    Tinus

    Joined:
    Apr 6, 2009
    Posts:
    437
    Thanks for the quick response, that sounds excellent!

    Very well, I'll be purchasing this week. Looking forward to having some proper water surrounding the BASE jumping locations. :)
     
    Last edited: Jan 16, 2013
  37. jsunandmax

    jsunandmax

    Joined:
    Jan 12, 2013
    Posts:
    17
    i'm having problems; i just downloaded the lastest from Asset Store, and running Unity Pro.

    When i drop WATER_Module into my scene (as suggested in readme), it immediatly borks my scene. I've got at least (4) NullReferenceException errors, in waterModule_quality.Start () (at Assets/SUIMONO - WATER SYSTEM/SCRIPTS/waterModule_quality.js:58)

    and 3 other errors like this in waterModule_underwaterEffect.js, waterModule_causticEffect.js etc.



    whats' going on? I'm not even USING these scripts in my scene; why are they killing the game?

    thanks in advance,
     
  38. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi jsunandmax, not exactly sure what is giving you this error, but it's possible these errors are being generated because it's looking for a game object it can't find... probably a camera (maybe?). Make sure your scene has a camera and that this camera's tag is set to "MainCamera".

    If this still doesn't help, you can go into those three scripts and disable the following line, near the top of each script....

    "@script ExecuteInEditMode()"

    change this to...

    "//@script ExecuteInEditMode()"

    ...and this should prevent you from seeing these errors in the editor. Again, not exactly sure here, just guessing. You can email me a screenshot of the exact errors your getting if the above doesn't help... send any emails to konnichiwa[at]tanukidigital.com

    Let me know of this helps.
     
  39. jsunandmax

    jsunandmax

    Joined:
    Jan 12, 2013
    Posts:
    17
    thanks chingwa, you fixed my problem via. email. great product and great support! Highly recommended!
     
  40. ineteye

    ineteye

    Joined:
    Sep 12, 2012
    Posts:
    35
    Refraction plane makes problem with 1st camera look like this:

    $rafractplane.png

    replacing plane with other object makes different effect...
     
  41. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi ineteye. Hmm, that's rather strange. I can't tell exactly what is going on in this screenshot, but it seems like the refraction plane isn't positioning itself correctly for your camera. question: do you have multiple cameras in your scene?

    you can try editing the positioning code, and see if this gives you better results... look at the following two lines in the "waterModule_underwaterEffect" script...

    edit: these 2 lines are 140 and 141...
    Code (csharp):
    1. underwaterRefractPlane.transform.localPosition = Vector3(0.0,0.0,(setCamera.camera.nearClipPlane+0.02));
    2. underwaterRefractPlane.transform.localEulerAngles = Vector3(270.0,0.0,0.0);
    This sets the positioning correctly for most camera objects. try editing the rotation code on the second line especially, it seems like something is rotating your camera slightly off, or if you have multiple cameras perhaps it's calculating based on the wrong camera.

    Try the above and see if it helps, otherwise please email me at konnichiwa[at]tanukidigital.com, and give me as much info about your setup as possible. :)
     
    Last edited: Feb 1, 2013
  42. ineteye

    ineteye

    Joined:
    Sep 12, 2012
    Posts:
    35
    Thanks... i resolve first problem with refraction... i use Ultimate Fps Preset... and it is comes 180 camera rotation by default... i set that to zero and plane problem solved... but still some strange blue overlays...

    $Another_Refraction.png

    1.And by the way in unity 4 i did not see "effect_underwater_debris" at all is it just my problem or it unity 4??
    2.How make refraction and underwater effect enabled on start-up, when character starts underwater?
     

    Attached Files:

    Last edited: Feb 2, 2013
  43. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hmm... yeah the debris particles don't seem to be showing up in the latest version (!) I'll take a look at fixing that permanently in the next update, but for now, try changing the position and scale settings on the "effect_underwater_debris" object under "WATER_Module"...

    change the position to be 0,0,0
    change the rotation to be 0,0,0
    change the scale to be 2,2,2

    This fixed it for me, though the particles are a bit hard to see.... you can also make them darker/lighter by changing the color in the particle material renderer.

    the screenshot you posted, is that under the water? I think the blue plane is the effect_refract_plane.... but it's still rotated the wrong way. try changing the rotation.x value on line 141 of the script mentioned above... typically it is set to be 270.0, but if your camera is being positioned by another script this might need to be changed...? Honestly this is the first I've seen this problem, but it seems like it's a simple rotation issue.

    In order to start underwater without a delay, try changing the line 39 in the waterModule_underwaterEffect script...

    Code (csharp):
    1. InvokeRepeating("checkWaterTransition", 2, 0.05);
    change the "2" on this line to be something really small, such as "0.01"... that should set it up to start right away. :)
     
  44. ineteye

    ineteye

    Joined:
    Sep 12, 2012
    Posts:
    35
    I fix those strange overlays... added Bloom and lens flare ... strange.. )) Thanks...

    By the way i think you should take a look at this screen of underwater game... debris should more like on screen i think.. same as Sun ray effect i think ))




    Also in video really good shows "caustics_projector"

     
    Last edited: Feb 2, 2013
  45. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Great, glad to hear you were able to get things working! The water in those examples is really amazing! I've started improving underwater effects and other features for Suimono Version 2.0... (release TBD). These are a great inspiration for that, thanks!
     
  46. jcolemorr11

    jcolemorr11

    Joined:
    Dec 13, 2012
    Posts:
    5
    Hey Chingwa,

    FIrst off, Suimono is great.

    I'm having some issues I was wondering if you could help me sort out?

    1. Whenever I drop my camera under water, but mainly when I start it under water, there's a very noticeable delay in how long it takes the reflect plane to show up on the camera. (i.e. so when the game is started, you see underwater for about 1 or 2 seconds before the reflect plane pops up).

    2. I'm trying to figure out a draw call problem that's happening with the system. I have a city that, without suimono active, creates about 400 to 500 draw calls. However, when I activate suimono, and view that city through a camera with the "MainCamera" tag, the draw call jumps to 2000+!! I've noticed that if I use a camera without the "MainCamera" tag, the draw calls stay at 400 to 500 and I can still see a "plainer" version of the water.

    What I find odd about this hiccup is that when the city is in the main camera's view, the water isn't even within the camera's view. So why is it jumping the draw call up so much?

    Thanks!
     
  47. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi jcolemorr11,

    This is actually undocumented, but you can change or remove this initial delay by changing a bit of code.... in the waterModule_underwaterEffect script on line 41 you'll see the initial start code...
    Code (csharp):
    1. InvokeRepeating("checkWaterTransition", 2, 0.05);
    Change the "2" to be something really small like 0.1, and this will fix this issue for you. I initially had this delay to make sure all the system's were up and running before initiating the underwater surface. But I think I'll drop it to 0.1 by default in the next version.

    As for the drawcall issue... this is caused by the Water_reflection Mirror script on your Water Surface. this script calculates a reflection texture in real-time and then adds it to the water shader. It does this by re-rendering your scene from a different angle, which is why you are getting the drawcall jump. It uses the mainCamera tag by default... so if your camera is not set with the mainCamera tag this script won't activate... thus smaller drawcalls, but no reflections.

    It works by determining the camera's view frustrum... so even if you don't actually see the water(or pieces of your city are hiding it from view), if the camera is pointing in the direction of the water plane it will attempt to render.

    This script can be optimized a bit by changing the Texture Size it renders to, or by selecting only the specific layers you need to be reflected for your scene. You can also remove this script from your water surface and you should see a big performance boost, but you won't have real-time reflections :( to Compound this, currently if you have multiple water surfaces with this component, each one will attempt to render it's own reflection texture... I'm working on a way to optimize this for future releases, so stay tuned!

    the Suimono shader does include 2 texture slots for cubemap reflections, so if you find this realtime reflection script is just too much of a performance hog you can include your own custom cubemap reflections instead. Depending on your scene, and how you're using the water, this may be completely fine, and will definitely give you better performance then having real-time reflections.
     
  48. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Hi All, this is just a heads up to let everyone know that a bug-fix has been submitted to the asset store as version 1.46

    This fixes a bug with surface-height calculation which was brought to my attention over on the Suimono help forum by mastajapp. if your water surface is a simple flat plane, then this bug fix really won't change anything for you, however if you're plane is on an angle, or if you are using a custom mesh that has a range of heights to it, then this solves an issue with the underwater transition, sound effects, and splash effects not rendering at the correct Y position.
     
    Last edited: Mar 7, 2013
  49. chingwa

    chingwa

    Joined:
    Dec 4, 2009
    Posts:
    3,790
    Version 1.46 is now live on the Asset Store. :)
     
  50. SevenBits

    SevenBits

    Joined:
    Dec 26, 2011
    Posts:
    1,953
    Hello, I was wondering what sort of computer hardware is required to get an effect as good as the one seen in the video. What are the specs of the computer you used to record your intro video, and what are the minimum specifications to get an effect as good as the one displayed.
     
Thread Status:
Not open for further replies.