Stylized Water 2 documentation

📣 UNITY 6

Reminder: this asset is developed for use with Unity 2020-2023.

Stylized Water 3, for Unity 6, is available now!

If you have purchased a license for Stylized Water 2, after September 1th 2024, you are able to update for FREE! (upgrades are a fixed system, no exceptions can be made by either me or Unity staff)

A 25% upgrade discount will remain in effect.

Stylized Water 2

Stylized Water 2
Version: 1.6.9
Review

3.Getting Started #

At all times you must ensure your project is free of any console errors. Unresolved code errors will prevent this asset’s code from compiling as well, the shader may display as pink in this case.

Initial project set up

Before using the shader, ensure your project is in fact using the Universal Render Pipeline.

Go to Edit->Project Settings->Graphics to check if a pipeline asset has been assigned (name may differ)

If this is not the case, materials will be pink, please refer to the URP documentation for setup instructions.

Note: the choice of render pipeline should be a well-informed decision early in a project. Switching to URP mid-production means other custom shaders may fail to work. Realistically, you should already be using URP before buying/using this asset.

All the materials and demo content are based on the linear color space. For new projects, Gamma-space is used by default. It is recommend to use Linear-space instead for a number of reasons. See the related Unity docs page for more details.

Universal Render Pipeline setup

Double-click the pipeline asset and verify these options are enabled

The depth texture is used for a variety of effects. Should it be disabled, the depth and intersection effects fail to work. Building on Android with this disabled results in the water turning invisible. The opaque texture is used for the refraction effect, and is required when it is enabled.

Should these options not be enabled, yet the shader is using features that require either one of them, a warning and quick-fix button will be displayed in the material UI:

Note that each individual camera can override these settings. If the effects aren’t visible in a specific scene, or for a specific camera. Verify that the options aren’t set to “Off”

If you’re using different pipeline settings, per quality level. Ensure these options are also enabled on them. Otherwise you may notice some water effects not working when building the project, and running the game on a lower quality scale.

Tip: you can double-click the assigned asset to open it in the inspector

Adding water to your scene

It is strongly advised to create and use your own materials (or duplicate the ones in the package), so your settings are not accidentally overridden when updating the asset.

It’s best to consider the included materials examples and starting points.

Option 1

  • Drag one of the prefabs found under Assets/StylizedWater2/Prefabs into your scene.
  • Adjust the material properties to your liking.

Option 2

  • Go to the GameObject->3D Object->Water->Object menu option. A new Mesh Renderer will be created in view.

Option 3:

  • Create a plane mesh in the scene
  • Create and assign a new material to your water mesh and assign the shader found under StylizedWater2/Default.
  • Add a Water Object component to your mesh through Add Component->Stylized Water 2->Water Object. This is only necessary if you wish to use Planar Reflections, though this has no negative impact otherwise!

Every material parameter has a tooltip that explains its function (if not obvious). Hover over it with the mouse to view a description.

Yes No Suggest edit
Last updated on October 5, 2023
22 of 22 users found this section helpful
Suggest Edit