Shore Generator logo
Version 20210410170000  


This asset for Unity 3D terrains will help the user generate at runtime a nice customizable shore following the curves of a choosen terrain.


Back to top


The Shore Generator package is composed of the following :

  • com.heparo.terrain.shore : the Shore Generator package (main folder hierarchy) [0 file(s)]
    • demonstration : contains the demonstration scene [2 file(s)]
      • materials : the materials used in the scene [n file(s)]
      • terrains : the terrain used in the scene [1 terrain]
      • textures : the textures used in the scene [n file(s)]
    • documentation : contains the HTML documentation of the Shore Generator package (normally the page you are presently reading... Isn't it ?) [1 file(s)]
      • css : the CSS file of the documentation [1 file(s)]
      • images : contains all the images used in the present documentation [n file(s)]
    • editor : contains the Shore Generator custom editor [1 file(s)]
    • scripts : contains all the Shore Generator core classes [1 file(s)]


Back to top

Getting started

Getting started with Shore Generator is quite easy : associate a terrain with a classical plane will generate at runtome the desired shore asset.

Step 1 : create and modify a terrain to fit your needs

Step 2 : add a standard "plane" object to the scene and scale it centered on your terrain

Step 3 : I have renamed my plane to "shore" in this example and positionate it at the desired Y position

Step 4 : attach the C# script [ShoreGenerator] to our plane, we can now configure our final shore

Step 5 : now configure our generator

  • Debug : to draw or not to draw the shorline and related vertices at runtime (in red for the shoreline and yellow for the triangles of the terrain used to generate the shore)


  • Layer : the objects of the layer the shore is generated for (using vertical raycast)

    TIP : it can be a good idea to place your shore in a different layer particulary if ou have several shores in the same scene !!


  • Generate collider : will the generated shore object have a collider component ? (usefull if you want to use it as a platform)


  • Resolution : the plane will be cut down into [resolution x resolution vertex] in order to generate the shore


  • Width : the size of the shore


  • Earth / Water sides ratio : the percentile of the width reserved for the water side (the rest is for the earth side - here 65% is for water side)


  • Slope : in degrees (from 0 horizontal to 85) to indicate the slope of the generated shore (carefull : not centered on the shore line) - Below with 45 degrees


  • At runtime : if checked the generator works at runtime - see step 6


Step 6 : finally press [PLAY] and look at the result !! (this is the result obtained with the demonstration scene)


Back to top

In Edit mode !

In Edit mode, the script works as previously but after uncheck the "At runtime" attribute, you will be able to generate a new separated GameObject with a dedicated mesh.
The source object remains untouched.
You can then generate as much objects as you want as the new generate shore is totally "clean".
The dedicated mesh oject can be incorporated in a previously existing prefab too...

Step 1 : uncheck the "At rutime" attribute

Step 2 : click the button !

Step 3 : the object is now cloned (same exact position - but not the transform) and also a new mesh exists as an asset

Step 4 : hide the source object and select your new clone (note the generator script is gone, the collider is generated if option is checked too)

Step 5 : note the mesh ready to be used in a previously existing Prefab...


Back to top

Known bugs or malfunctions

None at the moment.


Back to top


Version 20210410170000

  • Uploaded version for LTS unity editor version (2020.3.2 at the moment)
  • By personal choice (and because of toooo many versions), I won't upload packages anymore for older versions of Unity : I will stick to the latest LTS version available. My deepest apologies for the inconvenience...
  • Tested as imported custom package with no errors in a fresh HDRP project and URP one ! (in fact the asset was naturally compatible, what a relief !)
  • The previous packages are kept as is for compatibility purpose

Version 20190927170000

  • Added the ability to work in Edit mode and generate as many shores as desired avoiding the "At runtime" computation (see updated Manual)
  • As is, the script still works as initially released for compatibility purpose

Version 20190612114000

  • In order to generate the shore, the user must now choose a layer : all the objects will now be used (vertical raycast)
  • Compatible with Unity 5, 2017, 2018, 2019 (but NOT COMPATIBLE with HRP and LRP)

Version 20180515170000

  • Simple actualized version - No modification
  • Compatible with Unity 5, 2017, 2018 (but NOT COMPATIBLE with HRP and LRP)

Version 20171120140000

  • Better demonstration scene with two examples of use
  • Updated visuals (documentation + store)

Version 20170315210000

  • Initial released version


Back to top


Also, for any issue / problem / bug / question relative to this asset, please feel free to send me an email at :

Please, do not forget to place [ShoreGenerator] at the beginning of your mail subject.

  • I speak english
  • Hablo español
  • Je parle français

Thank you for puchasing and using this asset !

Kind regards,


All material included in the [Shore Generator] package was made by me except when mentioned explicitly


Asset Store Terms of Service and EULA
Please refer to : Asset Store Terms of Service and EULA

Back to top