diff options
author | Malfurious <m@lfurio.us> | 2022-09-14 04:38:20 -0400 |
---|---|---|
committer | Malfurious <m@lfurio.us> | 2022-09-14 04:53:17 -0400 |
commit | dfc6b2b98755fa583286395c2bf6a08b30bfa56f (patch) | |
tree | 070b8459b8ed61af706cbcc72ac2e905da720afc /water | |
parent | 38b247487309ca89bf2d94bb321f12059861db9d (diff) | |
download | godot_wildjam_49-dfc6b2b98755fa583286395c2bf6a08b30bfa56f.tar.gz godot_wildjam_49-dfc6b2b98755fa583286395c2bf6a08b30bfa56f.zip |
Extend water area to 10km x 10km
Horizon LOS in water should be typically around 5km, so extend the
dimentions of the water to allow 5km in any direction.
With regard to the wave shader, we extend the original MeshInstance to
2000x2000 using a reasonable tradeoff of virtex subdivisions. The
remainder of the area is covered by another water plane, subdivided to a
much lower level of detail. The area at the center of the large 'outer'
water plane is subtracted so that the two do not overlap.
Co-authored-by: dusoleil <howcansocksbereal@gmail.com>
Diffstat (limited to 'water')
-rw-r--r-- | water/Water.tscn | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/water/Water.tscn b/water/Water.tscn index 0cf4a50..3724e82 100644 --- a/water/Water.tscn +++ b/water/Water.tscn @@ -1,10 +1,10 @@ -[gd_scene load_steps=7 format=2] +[gd_scene load_steps=9 format=2] [ext_resource path="res://water/Wave.gdshader" type="Shader" id=1] [ext_resource path="res://water/Water.gd" type="Script" id=2] [sub_resource type="PlaneMesh" id=9] -size = Vector2( 500, 500 ) +size = Vector2( 2000, 2000 ) subdivide_width = 500 subdivide_depth = 500 @@ -29,6 +29,14 @@ shader_param/foam_amount = 0.6 shader_param/murkiness = 4.0 shader_param/noise = SubResource( 18 ) +[sub_resource type="PlaneMesh" id=19] +size = Vector2( 10000, 10000 ) +subdivide_width = 100 +subdivide_depth = 100 + +[sub_resource type="PlaneMesh" id=20] +size = Vector2( 2000, 2000 ) + [node name="Water" type="Spatial"] [node name="MeshInstance" type="MeshInstance" parent="."] @@ -44,3 +52,11 @@ wave2_direction = Vector2( 1, 0.6 ) wave3_steepness = 0.25 wave3_wavelength = 18.0 wave3_direction = Vector2( 1, 1.3 ) + +[node name="CSGMesh" type="CSGMesh" parent="."] +mesh = SubResource( 19 ) +material = SubResource( 11 ) + +[node name="CSGMesh" type="CSGMesh" parent="CSGMesh"] +operation = 2 +mesh = SubResource( 20 ) |