Search Unity

[WIP] Ultimate Toon Water (Asset)

Discussion in 'Works In Progress - Archive' started by Gobla, Feb 16, 2014.

  1. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Ultimate toon water is an all-in-one solution for Cartoon/Toon water. Suitable for normal Windows/Linux/Mac/Web builds as well as mobile. The asset is almost completed. Will be submitted to the asset store this weeks. Please let me know what you think and if this assets needs a certain component not named in the features below.

    Asset store:
    Accepted in the asset store. You can get it over here: http://u3d.as/content/peculiar-developer/the-ultimate-toon-water/74C

    Current features:
    • Mix between a single color and textures
    • Mix between two texures
    • Automatic mesh generation based on size and Meshpoint distance
    • Multiple Dynamic waves (Wave size, Wave speed, Wave height, offset).
    • Custom scrollable texture settings
    • Shoreline FX (PRO only)
    • Basic boat controls
    • Floating objects support
    • Optional faux waves (like in Windwaker)
    • Lots more to come
    Upcoming features:
    • Splash FX
    • Automatic wave / weather control system
    • Water drag lines FX
    • And more
    Sandbox webplayer
    The demo scene that is included in the package can be found here (Highest quality):

    http://peculiardeveloper.com/u3d/UltimateToonWaterDemo/

    The mini game I'll be making with the package can be found here (Highest quality):
    http://peculiardeveloper.com/u3d/UltimateToonWater/

    Screenshot of the Sandbox




    Old sceenshots:







     
    Last edited: Nov 24, 2014
  2. NileSuperRiver

    NileSuperRiver

    Joined:
    Dec 14, 2013
    Posts:
    5
    This is some really great stuff! I will certainly buy this as soon as it is available! Upping the resolution of the texture (especially the particles) would greatly help it's look.
     
    Last edited: Feb 17, 2014
  3. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Thank you! I will replace the water-cell texture for one with a resolution of 2048x2048. The particles will also be upped when I release the package.
     
  4. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Breakthrough with the GPU rendering of the water. FPS improvement for big water masses is enormous.

    Edit: Webplayer updated with GPU .
     
    Last edited: Feb 27, 2014
  5. LPG_FIN_Markus

    LPG_FIN_Markus

    Joined:
    Jan 27, 2014
    Posts:
    19
    Nicee! i would buy it the instant it got relased if i had any money :p
     
  6. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Thank you. And don't worry it will be very affordable when it comes out ;).
     
  7. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Added steepness coloring.
    Improved the wave particles.
    Improved the boat physics (not done yet).

    These are all in the webplayer (http://peculiardeveloper.com/u3d/UltimateToonWater/).

    About the GPU rendering: The first two waveforms are being calculated by the GPU. If you add more, the CPU will have to come in. This is due to mobile support. However I will also write a shader that renders up to 4 waveforms in the GPU for desktop solutions.


     
  8. indiegamemodels

    indiegamemodels

    Joined:
    Jan 25, 2012
    Posts:
    269
    Very nice, the 2nd screenshot in your first post reminds me of the water in Zelda: The Wind Waker!
     
  9. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Thank you. That is one of the inspirations indeed.
    Also:

    - Replaced the dull boat
    - Added Alpha option to the water
    - Fixed rendering issue
    - Baseline color control
    - Shoreline color control
    - Underwater terrain for the alpha display
    - Some things more I've might forgotten...


     
  10. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    OK... So I am accidentally making a game out of this asset.

    Don't worry, the asset will come. But be sure to also try the start of this game as well...

    Try it here. Lets see if you can get a sub 27 seconds!

    http://peculiardeveloper.com/u3d/UltimateToonWater/
     
    Last edited: Mar 15, 2014
  11. Legi

    Legi

    Joined:
    Jul 25, 2013
    Posts:
    20
    Really enjoy it :)

    $rocket_time.png
     
  12. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Nice Score!
    I've created a bot now that can only accept the same input as a human would do (so up down left right shift) and the best time the bot has had so far is 24.68 seconds.

    I like where this is going.
     
    Last edited: Mar 16, 2014
  13. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Added in 2 AI boats for you to compete against as well as a longer track. Enjoy!
    Also the AI boats do not check for other players and so. So expect some weird behavior (other then racing with rocket boosted mechanical sharks).
     
    Last edited: Mar 16, 2014
  14. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    To get this more organized:

    The demo scene that is included in the package can be found here (Highest quality):
    http://peculiardeveloper.com/u3d/UltimateToonWaterDemo/

    The mini game I'll be making with the package can be found here (Highest quality):
    http://peculiardeveloper.com/u3d/UltimateToonWater/

    After the code has been cleaned, I will submit this package to the asset store. Expect this to be Wednesday or Thursday.

    A simpler version of the boat controller will be added with the example of how to create your own boat controller since the powerboat controller is not part of the package.

    Addition to the mini game, if you hit P, you can toggle the autopilot.
     
    Last edited: Mar 16, 2014
  15. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    The package is uploaded and awaiting review. Demo scenes will be updated later tonight.
    The first month it will be 20 dollars. After that it goes to up.
     
    Last edited: Mar 22, 2014
  16. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
  17. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    I'm busy on quite some fixes and changes for the next version. Here is a preview list:
    • Fixed "Material leaked into scene." bug.
    • Fixed Demo Boat from sinking with FPS drops.
    • Fixed Toggle waves and move texture checkboxes (they work now).
    • Added Config files where you can easily tweak, export and import your water settings.
    • Detached the EmitWaves part to a separate controller for more mobility.
    • Added "Steep Waves" option for realistic steep waves.
    • Better info with the editor.
    • Added gizmo's in the demo boat scene where you can see the forces, mass points, etc.
    • Partially in editor preview of how the waves look like during runtime.
    Expected to be published in 1.5 weeks.
     
  18. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Well The updates are almost completely tested.

    In the meanwhile: A new version (concept) of the sharkboat for the game I am making based upon Ultimate Toon Water.
     
  19. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Updated and submitted the newest package of Ultimate Toon Water.
    The demo scene: http://peculiardeveloper.com/u3d/UltimateToonWaterDemo/ was updated.

    For existing users, there is going to be an important change:
    A more modular and optimized version of UTW was introduced in this package. This will replace the old version over time. Migration is very simple and should take no more than 10 minutes (when taking things very very slow, read every detail there is, etc.). I hope you understand that this is necessary and will result in a better version. You are of course free to use the Legacy version that will be included in the package, but doesn't receive all the updates there are.

    The manual will contain the upgrade instructions to upgrade from legacy to the latest version. I have complete faith that the upgrade will go fine in most cases, but if there are any questions you are free to ask them here. I will answer these as soon as possible.



     
    Last edited: Nov 24, 2014
  20. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    There was a slight delay in the submission. It is finally uploaded now.

    For the next update I'll be working on a surface shader version allowing better looks and multi lighting support.
     
  21. hnp

    hnp

    Joined:
    Dec 9, 2014
    Posts:
    8
    It's very nice, especially the surface movement. But the '^' particles are really weird.
     
  22. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Thank you. The '^' Particles look better in the latest version (photo's are of the old version) and can be turned on and off if you like. You can also replace them for other particles. You can check the demo above to see the newest version..
     
  23. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
  24. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    It seems that Unity 5's rigidbody.AddForceAtPosition is broken. To be more precise, the torque created by the force seems to be miscalculated (wrong origin? not evenly distributed over time? perhaps even from the world origin or so?) resulting in popping, spinning, etc. This is so far out of my control to fix and regrettably we have to wait for a fix in Unity's Physics engine until this is resolved.

    Sorry for the inconvenience.
     
  25. 8924hagkowe

    8924hagkowe

    Joined:
    Apr 9, 2015
    Posts:
    2
    Hi,

    I'm using UTW in Unity 5 and there seems to be a problem with the shore foam: it shows up in repeating patterns in the middle of the water. Here's an example, the scene only has the water and the cube, with shore foam set to 5. You can see the foam on the front of the cube, but also all those bright spots:

    sf-5.jpg

    Here's the same thing but with shore foam amount set to 0:

    sf-0.jpg

    Any idea if this is something I could change in the script/shader?
     
  26. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Yes this is an issue that is caused by the difference in the rendering pipeline between U4 and U5.
    The official U5 update fixes this issue. This was submitted to unity for review. I am awaiting for accepting or feedback.

    In order to temporarily fix it in the meanwhile you have to change 2 things:
    In UltimateToonWaterC.cs (or legacy UltimateToonWater.cs)
    Change the y value of the Vector3 in "vertices[index] = new Vector3(...,0.0f,...);" to -100f in generateMesh() {.
    You can leave the x and z value unchanged here.

    In UltimateToonWater.shader
    Change the line
    v.vertex.y = 0; (or similar)
    to
    v.vertex.y += 100f;

    The shader was changed in the official update and no longer requires this temp fix and should be available once it is accepted. However I cannot post that without posting too much of the shader itself.
     
  27. 8924hagkowe

    8924hagkowe

    Joined:
    Apr 9, 2015
    Posts:
    2
    Wonderful, thanks!

    Btw, the change in the y component in UltimateToonWater[C].cs doesn't seem to do anything, so I just moved my water lower to compensate.
     
  28. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    It is the combination of both UltimateToonWater[C].cs and the UltimateToonWaterShader changes.
    Basically in the new render pipeline the water is registered in the depth buffer prior to the vertex offset resulting in the white marks. Changing the offset in the mesh to -100 and in the shader to +100 makes the initial depth buffer being registered at -100 units below the surface while displaying it at 0 to start with and thus fixing the depth buffer issue.
     
    Last edited: Jul 13, 2015
  29. Boercam

    Boercam

    Joined:
    Feb 25, 2015
    Posts:
    6
    Does the shore foam not work on mobile? It's showing in my editor but it's not visible on my android device.
     
  30. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Depending on your android device capabilities it should work. Tested and works with a Nexus 5 (using a Adreno 330 GPU).
     
  31. cjaube

    cjaube

    Joined:
    Jan 11, 2016
    Posts:
    1
    Just a note on the shore foam: It seems that a directional light needs shadows to be turned on for it to work. It took me quite a while comparing my scene to the example scene to figure that one out.
     
  32. Gobla

    Gobla

    Joined:
    May 28, 2012
    Posts:
    354
    Thanks. I will look into this.
     
  33. Charles-Van-Norman

    Charles-Van-Norman

    Joined:
    Aug 10, 2010
    Posts:
    86
    It doesn't work with WebGL, is that correct?
     
  34. piercew102

    piercew102

    Joined:
    Dec 24, 2012
    Posts:
    9
    Hi @Gobla

    I recently got UTW and so far the level of customization has blown me away. Keep up the great work! I was also wondering if there was an easy way to add fog to the water shader? I'm kind of a newbie at shader coding, so any advice would help.

    Thanks again for the awesome asset!
     
    Last edited: Aug 22, 2016