Merge pull request #12138 from neikeq/i
Avoid adding built-in script path to csproj
This commit is contained in:
commit
8de1dc7e9a
1 changed files with 9 additions and 6 deletions
|
@ -1421,6 +1421,8 @@ bool CSharpScript::can_instance() const {
|
|||
|
||||
#ifdef TOOLS_ENABLED
|
||||
if (Engine::get_singleton()->is_editor_hint()) {
|
||||
|
||||
if (get_path().find("::") == -1) { // Ignore if built-in script. Can happen if the file is deleted...
|
||||
if (_create_project_solution_if_needed()) {
|
||||
CSharpProject::add_item(GodotSharpDirs::get_project_csproj_path(),
|
||||
"Compile",
|
||||
|
@ -1429,6 +1431,7 @@ bool CSharpScript::can_instance() const {
|
|||
ERR_PRINTS("Cannot add " + get_path() + " to the C# project because it could not be created.");
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
return valid || (!tool && !ScriptServer::is_scripting_enabled());
|
||||
|
|
Loading…
Reference in a new issue