Skip to content

Commit

Permalink
Fix GDScript placeholder fallback
Browse files Browse the repository at this point in the history
  • Loading branch information
neikeq committed Nov 10, 2018
1 parent 0f3fc93 commit 7c4c646
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
3 changes: 2 additions & 1 deletion core/script_language.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,8 @@ Variant PlaceHolderScriptInstance::property_get_fallback(const StringName &p_nam
PlaceHolderScriptInstance::PlaceHolderScriptInstance(ScriptLanguage *p_language, Ref<Script> p_script, Object *p_owner) :
owner(p_owner),
language(p_language),
script(p_script) {
script(p_script),
build_failed(false) {
}

PlaceHolderScriptInstance::~PlaceHolderScriptInstance() {
Expand Down
7 changes: 7 additions & 0 deletions modules/gdscript/gdscript.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,15 @@ bool GDScript::_update_exports() {
for (Set<PlaceHolderScriptInstance *>::Element *E = placeholders.front(); E; E = E->next()) {
E->get()->set_build_failed(true);
}
return false;
}
} else {
if (!valid) {
for (Set<PlaceHolderScriptInstance *>::Element *E = placeholders.front(); E; E = E->next()) {
E->get()->set_build_failed(true);
}
return false;
}
}

if (base_cache.is_valid()) {
Expand Down

0 comments on commit 7c4c646

Please sign in to comment.