mirror of
https://github.com/Relintai/broken_seals.git
synced 2025-02-08 14:50:05 +01:00
Added a new editor chunk spawn range property to the world.
This commit is contained in:
parent
1c8b0cf5ed
commit
c8d6747e8c
@ -30,6 +30,8 @@ export(bool) var editor_generate : bool = false setget set_editor_generate, get_
|
||||
export(bool) var show_loading_screen : bool = true
|
||||
export(bool) var generate_on_ready : bool = false
|
||||
|
||||
export(int) var editor_chunk_spawn_range : int = 5
|
||||
|
||||
export(bool) var use_global_chunk_settings : bool = true
|
||||
|
||||
export(PropData) var test_prop : PropData
|
||||
@ -350,6 +352,8 @@ func set_editor_generate(value : bool) -> void:
|
||||
|
||||
if is_inside_tree() && Engine.editor_hint:
|
||||
if value:
|
||||
chunk_spawn_range = editor_chunk_spawn_range
|
||||
|
||||
library.refresh_rects()
|
||||
|
||||
level_generator.setup(self, current_seed, false, library)
|
||||
@ -450,5 +454,3 @@ func set_test_lod(val : int) -> void:
|
||||
var c : TerrainChunkDefault = chunk_get_index(i)
|
||||
|
||||
c.current_lod_level = test_lod
|
||||
|
||||
|
||||
|
@ -52,9 +52,11 @@ world_height = 100.0
|
||||
library = ExtResource( 1 )
|
||||
level_generator = ExtResource( 3 )
|
||||
voxel_scale = 3.0
|
||||
chunk_spawn_range = 10
|
||||
build_flags = 511
|
||||
num_lods = 5
|
||||
script = ExtResource( 2 )
|
||||
editor_chunk_spawn_range = 10
|
||||
test_prop = ExtResource( 5 )
|
||||
|
||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
|
||||
|
Loading…
Reference in New Issue
Block a user