Bartek Dragon Docs
You are here: Bartek Dragon Docs » Dragon Water » Water Surface

Water Surface

MonoBehaviour component.


Geometry

Assign geometry type.
Each type has different configuration
It is recommended to enable wireframe mode to visualize how detailed your mesh is.

  • Rectangle - procedural rectangle mesh
    • width - X size of mesh
    • height - Z size of mesh
    • subdivisions - amount of subdivisions of longer side; shorter side is calculated automatically
  • Circle - procerual circle mesh
    • radius - radius of mesh
    • segments - amount of segments on outer ring; inner rings have segments calculated automatically
    • rings - amount of rings
  • Infinite Ocean - procedural infinite plane mesh
    • quality preset - they are defined in Dragon Water Config. It's quite advanced stuff so either experiment with them on your own or use predefined preset
    • attach to - by default it's attached to main camera and follows it's transform. You can change it to e.g. your character/ship if you use 3rd person view
  • Custom Mesh - use custom shaped mesh
    • mesh - mesh asset; it should be flat mesh with evenly distributed vertices

Renderer

Main configuration how's the surface actually rendered.

  • Wave Profile - assign Wave Profile
    • Synchronize World Origin - if selected, origin of wave profile will be synchronized with transform of this water surface. It allows surface to be dynamically moved without unwanted offset, but makes profile non-reusable between different surfaces (or at least very limited).
  • Material Profile - assign Material Profile
  • Underwater Profile - assign Underwater Profile

Cutout Water Volume

Enable to process cutout volumes for this surface.
Read more: Cutout Volumes

Use Ripple

Enable to process ripple for this surface.
Read more: Ripple Effect


Boundaries

If you have selected water surface object in hierachy, you will see wireframe bounding box rendered in scene view.
Here you can configurate height size of bounding box used for water detection.

  • Max Height - above this height surface will no longer be detected as “water that's below you”
    • in open space you want this value to be high, but in interiors - just to touch the roof of room
  • Max Depth - below this depth water is no longer detected and you have no underwater state
    • in open space you want this value to be high, but in interiors - actual depth of your pool

Physics

Configure extra modiffiers for Floating Body, that floats on this surface.
Read more: Floating Body

  • Buoyancy Factor - extra global multiplier for buoyancy force
  • Extra Drag - adds extra submerge drag
  • Extra Angular Drag - adds extra submerge angular drag

Default Water Surface

If set to true, this will be default surface for easier accessibility via API and automatic optimization for Water Sampler. \\You do not need to have a default surface, but if you want, you can have only one.
Read more: Water Sampler

Previous Next

Bartek Dragon Docs

Table of Contents

Table of Contents

  • Water Surface
    • Geometry
    • Renderer
      • Cutout Water Volume
      • Use Ripple
    • Boundaries
    • Physics
    • Default Water Surface

Dragon Water

  • About
  • Changelog
  • Getting Started

Documentation

  • Water Surface
  • Wave Profile
  • Material Profile
  • Underwater Profile
  • Dragon Water Config
  • Cutout Volumes
  • Ripple Effect
  • Local Wave Areas

URP

  • URP Render Feature

Physics

  • Floating Body

Scripting

  • Scripting API
  • Water Sampler
  • Water Behaviour

How-To

  • Build Optimization
  • Multiplayer Synchronization