1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-07 12:30:27 +00:00

Properly reload built-in tool scripts

(cherry picked from commit 75e8eafa72)
This commit is contained in:
kobewi
2021-11-06 14:32:14 +01:00
committed by Rémi Verschelde
parent efadd46640
commit d0569255f2

View File

@@ -796,6 +796,11 @@ void ScriptEditor::_scene_saved_callback(const String &p_path) {
if (edited_res->get_path().get_slice("::", 0) == p_path) {
se->tag_saved_version();
}
Ref<Script> scr = edited_res;
if (scr.is_valid() && scr->is_tool()) {
scr->reload(true);
}
}
}