Skip to content

Commit

Permalink
Small fixes (#2079)
Browse files Browse the repository at this point in the history
* Adjust style cloning logic

* Emit Background Changed signal even when no Backgroundholder is present
  • Loading branch information
Jowan-Spooner authored Feb 9, 2024
1 parent b407bf8 commit b27f79b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion addons/dialogic/Modules/Background/subsystem_backgrounds.gd
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,12 @@ func update_background(scene := "", argument := "", fade_time := 0.0, transition
background_holder = dialogic.Styles.get_first_node_in_layout('dialogic_background_holders')
else:
background_holder = get_tree().get_first_node_in_group('dialogic_background_holders')

var info := {'scene':scene, 'argument':argument, 'fade_time':fade_time, 'same_scene':false}
if background_holder == null:
background_changed.emit(info)
return

var info := {'scene':scene, 'argument':argument, 'fade_time':fade_time, 'same_scene':false}

var bg_set := false

Expand Down
2 changes: 1 addition & 1 deletion addons/dialogic/Resources/dialogic_style.gd
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ func clone() -> DialogicStyle:
var style := DialogicStyle.new()
style.name = name
if base_scene != null:
style.base_scene = base_scene.duplicate()
style.base_scene = base_scene
style.inherits = inherits
style.base_overrides = base_overrides
for layer_idx in range(get_layer_count()):
Expand Down

0 comments on commit b27f79b

Please sign in to comment.