Skip to content

Commit 6cae5dc

Browse files
authored
Merge pull request #1 from PHS-TSA/terrain
Terrain
2 parents 14c26e0 + 78183e4 commit 6cae5dc

File tree

111 files changed

+4800
-32
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

111 files changed

+4800
-32
lines changed

addons/terrain_3d/LICENSE.txt

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2023 Cory Petkovsek, Roope Palmroos, and Contributors.
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

addons/terrain_3d/README.md

+44
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

addons/terrain_3d/editor/brushes/.gdignore

Whitespace-only changes.
12.6 KB
Binary file not shown.
209 KB
Binary file not shown.
10.8 KB
Binary file not shown.
17 KB
Binary file not shown.
10.6 KB
Binary file not shown.
8.7 KB
Binary file not shown.
194 KB
Binary file not shown.
260 KB
Binary file not shown.
260 KB
Binary file not shown.
260 KB
Binary file not shown.
260 KB
Binary file not shown.
177 KB
Binary file not shown.
24.7 KB
Binary file not shown.
274 KB
Binary file not shown.
283 KB
Binary file not shown.
80.4 KB
Binary file not shown.
10.1 KB
Binary file not shown.
2.27 KB
Binary file not shown.
2.9 KB
Binary file not shown.
4.16 KB
Binary file not shown.
7.32 KB
Binary file not shown.
11.3 KB
Binary file not shown.
1.51 MB
Binary file not shown.
297 KB
Binary file not shown.
331 KB
Binary file not shown.
307 KB
Binary file not shown.
333 KB
Binary file not shown.
295 KB
Binary file not shown.
231 KB
Binary file not shown.
16.8 KB
Binary file not shown.
852 KB
Binary file not shown.
1.51 MB
Binary file not shown.
1.51 MB
Binary file not shown.
1.51 MB
Binary file not shown.
12.3 KB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
@tool
2+
extends ConfirmationDialog
3+
4+
var lod: int = 0
5+
var description: String = ""
6+
7+
8+
func _ready() -> void:
9+
set_unparent_when_invisible(true)
10+
about_to_popup.connect(_on_about_to_popup)
11+
visibility_changed.connect(_on_visibility_changed)
12+
%LodBox.value_changed.connect(_on_lod_box_value_changed)
13+
14+
15+
func _on_about_to_popup() -> void:
16+
lod = %LodBox.value
17+
18+
19+
func _on_visibility_changed() -> void:
20+
# Change text on the autowrap label only when the popup is visible.
21+
# Works around Godot issue #47005:
22+
# https://github.com/godotengine/godot/issues/47005
23+
if visible:
24+
%DescriptionLabel.text = description
25+
26+
27+
func _on_lod_box_value_changed(p_value: float) -> void:
28+
lod = %LodBox.value
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
[gd_scene load_steps=2 format=3 uid="uid://bhvrrmb8bk1bt"]
2+
3+
[ext_resource type="Script" path="res://addons/terrain_3d/editor/components/bake_lod_dialog.gd" id="1_57670"]
4+
5+
[node name="bake_lod_dialog" type="ConfirmationDialog"]
6+
title = "Bake Terrain3D Mesh"
7+
position = Vector2i(0, 36)
8+
size = Vector2i(400, 115)
9+
visible = true
10+
script = ExtResource("1_57670")
11+
12+
[node name="VBoxContainer" type="VBoxContainer" parent="."]
13+
anchors_preset = 15
14+
anchor_right = 1.0
15+
anchor_bottom = 1.0
16+
offset_left = 8.0
17+
offset_top = 8.0
18+
offset_right = -8.0
19+
offset_bottom = -49.0
20+
grow_horizontal = 2
21+
grow_vertical = 2
22+
23+
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer"]
24+
layout_mode = 2
25+
theme_override_constants/separation = 20
26+
27+
[node name="Label" type="Label" parent="VBoxContainer/HBoxContainer"]
28+
layout_mode = 2
29+
text = "LOD:"
30+
31+
[node name="LodBox" type="SpinBox" parent="VBoxContainer/HBoxContainer"]
32+
unique_name_in_owner = true
33+
layout_mode = 2
34+
size_flags_horizontal = 3
35+
max_value = 8.0
36+
value = 4.0
37+
38+
[node name="DescriptionLabel" type="Label" parent="VBoxContainer"]
39+
unique_name_in_owner = true
40+
layout_mode = 2
41+
autowrap_mode = 2

0 commit comments

Comments
 (0)