Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes conflicts and crashes #1766

Merged
merged 2 commits into from
Oct 1, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions addons/dialogic/Other/DialogicUtil.gd
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ static func get_editor_scale() -> float:
## Although this does in fact always return a EditorPlugin node,
## that class is apparently not present in export and referencing it here creates a crash.
static func get_dialogic_plugin() -> Node:
var tree: SceneTree = Engine.get_main_loop()
if tree.get_root().get_child(0).has_node('DialogicPlugin'):
return tree.get_root().get_child(0).get_node('DialogicPlugin')
for child in Engine.get_main_loop().get_root().get_children():
if child.get_class() == "EditorNode":
Jowan-Spooner marked this conversation as resolved.
Show resolved Hide resolved
return child.get_node('DialogicPlugin')
return null


Expand Down