Big refactor: Fix plugin issues when disabling/reenabling plugins (#598)

Co-authored-by: balloonpopper <5151242+balloonpopper@users.noreply.github.com>
Co-authored-by: Duncan Brown <duncan@prometheussoftware.ca>
This commit is contained in:
Julian Murgia
2022-07-10 20:40:08 +02:00
committed by GitHub
parent dfbceadd1c
commit ad79aa69d1
113 changed files with 2977 additions and 2072 deletions

View File

@@ -67,14 +67,14 @@ func transition(
_tween.connect("tween_all_completed", self, "_on_tween_completed")
if transition_name.empty():
transition_name = escoria.project_settings_manager.get_setting(
escoria.project_settings_manager.DEFAULT_TRANSITION
transition_name = ESCProjectSettingsManager.get_setting(
ESCProjectSettingsManager.DEFAULT_TRANSITION
)
if not has_transition(transition_name):
escoria.logger.report_errors(
"transition: Transition %s not found" % transition_name,
[]
escoria.logger.error(
self,
"transition: Transition %s not found" % transition_name
)
# If this is an "instant" transition, we need to set the alpha of the base
@@ -122,8 +122,8 @@ func transition(
#
# *Returns* the full path to the shader or an empty string, if it can't be found
func get_transition(name: String) -> String:
for directory in escoria.project_settings_manager.get_setting(
escoria.project_settings_manager.TRANSITION_PATHS
for directory in ESCProjectSettingsManager.get_setting(
ESCProjectSettingsManager.TRANSITION_PATHS
):
if ResourceLoader.exists(directory.plus_file("%s.material" % name)):
return directory.plus_file("%s.material" % name)
@@ -154,5 +154,5 @@ func _on_tween_completed():
if not _was_canceled:
_tween.stop_all()
_tween.remove_all()
escoria.logger.debug("Transition %s done." % str(transition_id))
escoria.logger.debug(self, "Transition %s done." % str(transition_id))
emit_signal("transition_done", transition_id)