mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Fix empty script interface crash on tscn load.
Add fail conditions to protect the visual script function and also fix the initiating cause.
This commit is contained in:
parent
3cf3c4137a
commit
ef78181073
1 changed files with 2 additions and 1 deletions
|
|
@ -765,6 +765,7 @@ void VisualScriptEditor::_update_graph(int p_only_id) {
|
|||
}
|
||||
|
||||
void VisualScriptEditor::_update_members() {
|
||||
ERR_FAIL_COND(!script.is_valid());
|
||||
|
||||
updating_members = true;
|
||||
|
||||
|
|
@ -3061,7 +3062,7 @@ void VisualScriptEditor::_notification(int p_what) {
|
|||
}
|
||||
}
|
||||
|
||||
if (is_visible_in_tree()) {
|
||||
if (is_visible_in_tree() && script.is_valid()) {
|
||||
_update_members();
|
||||
_update_graph();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue