diff --git a/addons/dialogic/Core/DialogicResourceUtil.gd b/addons/dialogic/Core/DialogicResourceUtil.gd index f20a8d18b..a86356cbf 100644 --- a/addons/dialogic/Core/DialogicResourceUtil.gd +++ b/addons/dialogic/Core/DialogicResourceUtil.gd @@ -236,7 +236,7 @@ static func guess_special_resource(type: String, string: String, default := {}, if not ignores.is_empty(): var regex := RegEx.create_from_string(r" ?\b(" + "|".join(ignores) + r")\b") for name in resources: - if regex.sub(name, "") == string: + if regex.sub(name, "") == regex.sub(string, ""): return resources[name] ## As a last effort check against the unfiltered list diff --git a/addons/dialogic/Modules/Character/settings_portraits.gd b/addons/dialogic/Modules/Character/settings_portraits.gd index bb5ed93df..5e13819ca 100644 --- a/addons/dialogic/Modules/Character/settings_portraits.gd +++ b/addons/dialogic/Modules/Character/settings_portraits.gd @@ -55,25 +55,19 @@ func _refresh(): # JOIN %JoinDefault.resource_icon = get_theme_icon(&"Animation", &"EditorIcons") - %JoinDefault.set_value(DialogicUtil.pretty_name( - ProjectSettings.get_setting(ANIMATION_JOIN_DEFAULT_KEY, - get_script().resource_path.get_base_dir().path_join('DefaultAnimations/fade_in_up.gd')))) + %JoinDefault.set_value(ProjectSettings.get_setting(ANIMATION_JOIN_DEFAULT_KEY, "Fade In Up")) %JoinDefaultLength.set_value(ProjectSettings.get_setting(ANIMATION_JOIN_DEFAULT_LENGTH_KEY, 0.5)) %JoinDefaultWait.button_pressed = ProjectSettings.get_setting(ANIMATION_JOIN_DEFAULT_WAIT_KEY, true) # LEAVE %LeaveDefault.resource_icon = get_theme_icon(&"Animation", &"EditorIcons") - %LeaveDefault.set_value( - ProjectSettings.get_setting(ANIMATION_LEAVE_DEFAULT_KEY, - get_script().resource_path.get_base_dir().path_join('DefaultAnimations/fade_out_down.gd'))) + %LeaveDefault.set_value(ProjectSettings.get_setting(ANIMATION_LEAVE_DEFAULT_KEY, "Fade Out Down")) %LeaveDefaultLength.set_value(ProjectSettings.get_setting(ANIMATION_LEAVE_DEFAULT_LENGTH_KEY, 0.5)) %LeaveDefaultWait.button_pressed = ProjectSettings.get_setting(ANIMATION_LEAVE_DEFAULT_WAIT_KEY, true) # CROSS FADE %CrossFadeDefault.resource_icon = get_theme_icon(&"Animation", &"EditorIcons") - %CrossFadeDefault.set_value( - ProjectSettings.get_setting(ANIMATION_CROSSFADE_DEFAULT_KEY, - get_script().resource_path.get_base_dir().path_join('DefaultAnimations/fade_in.gd'))) + %CrossFadeDefault.set_value(ProjectSettings.get_setting(ANIMATION_CROSSFADE_DEFAULT_KEY, "Fade Cross")) %CrossFadeDefaultLength.set_value(ProjectSettings.get_setting(ANIMATION_CROSSFADE_DEFAULT_LENGTH_KEY, 0.5)) diff --git a/addons/dialogic/Modules/Character/subsystem_portraits.gd b/addons/dialogic/Modules/Character/subsystem_portraits.gd index be96640c2..28f2c5d48 100644 --- a/addons/dialogic/Modules/Character/subsystem_portraits.gd +++ b/addons/dialogic/Modules/Character/subsystem_portraits.gd @@ -394,7 +394,7 @@ func join_character(character:DialogicCharacter, portrait:String, position_id:S character_joined.emit(info) if animation_name.is_empty(): - animation_name = ProjectSettings.get_setting('dialogic/animations/join_default', "Fade Up In") + animation_name = ProjectSettings.get_setting('dialogic/animations/join_default', "Fade In Up") animation_length = _get_join_default_length() animation_wait = ProjectSettings.get_setting('dialogic/animations/join_default_wait', true) @@ -450,7 +450,7 @@ func change_character_portrait(character: DialogicCharacter, portrait: String, f return if fade_animation == "DEFAULT": - fade_animation = ProjectSettings.get_setting('dialogic/animations/cross_fade_default', "Fade In Out") + fade_animation = ProjectSettings.get_setting('dialogic/animations/cross_fade_default', "Fade Cross") fade_length = ProjectSettings.get_setting('dialogic/animations/cross_fade_default_length', 0.5) fade_animation = DialogicPortraitAnimationUtil.guess_animation(fade_animation, DialogicPortraitAnimationUtil.AnimationType.CROSSFADE) @@ -522,7 +522,7 @@ func leave_character(character: DialogicCharacter, animation_name:= "", animatio return if animation_name.is_empty(): - animation_name = ProjectSettings.get_setting('dialogic/animations/leave_default', "Fade Down Out") + animation_name = ProjectSettings.get_setting('dialogic/animations/leave_default', "Fade Out Down") animation_length = _get_leave_default_length() animation_wait = ProjectSettings.get_setting('dialogic/animations/leave_default_wait', true) @@ -622,7 +622,7 @@ func change_speaker(speaker: DialogicCharacter = null, portrait := "") -> void: var just_joined := true for character_node: Node in container.get_children(): if not character_node.get_meta('character') == speaker: - var leave_animation: String = ProjectSettings.get_setting('dialogic/animations/leave_default', "Fade Up Out") + var leave_animation: String = ProjectSettings.get_setting('dialogic/animations/leave_default', "Fade Out") leave_animation = DialogicPortraitAnimationUtil.guess_animation(leave_animation, DialogicPortraitAnimationUtil.AnimationType.OUT) var leave_animation_length := _get_leave_default_length() @@ -646,7 +646,7 @@ func change_speaker(speaker: DialogicCharacter = null, portrait := "") -> void: if portrait.is_empty(): portrait = speaker.default_portrait - var fade_animation: String = ProjectSettings.get_setting('dialogic/animations/cross_fade_default', "Fade In Out") + var fade_animation: String = ProjectSettings.get_setting('dialogic/animations/cross_fade_default', "Fade Cross") var fade_length: float = ProjectSettings.get_setting('dialogic/animations/cross_fade_default_length', 0.5) fade_animation = DialogicPortraitAnimationUtil.guess_animation(fade_animation, DialogicPortraitAnimationUtil.AnimationType.CROSSFADE) @@ -661,7 +661,7 @@ func change_speaker(speaker: DialogicCharacter = null, portrait := "") -> void: continue if just_joined: - var join_animation: String = ProjectSettings.get_setting('dialogic/animations/join_default', "Fade Up In") + var join_animation: String = ProjectSettings.get_setting('dialogic/animations/join_default', "Fade In Up") join_animation = DialogicPortraitAnimationUtil.guess_animation(join_animation, DialogicPortraitAnimationUtil.AnimationType.IN) var join_animation_length := _get_join_default_length()