diff options
author | Thaddeus Crews <repiteo@outlook.com> | 2024-06-09 15:21:41 -0500 |
---|---|---|
committer | Thaddeus Crews <repiteo@outlook.com> | 2024-11-10 12:41:26 -0600 |
commit | 925b690c989dea13d0dfc06d2a7b1edc8de6b34f (patch) | |
tree | 444f95d5deffb18f2a1a91f6a06c0dd132d83600 /modules/mono/csharp_script.cpp | |
parent | 0f5f3bc9546b46b2029fc8896dc859697f1eab97 (diff) | |
download | redot-engine-925b690c989dea13d0dfc06d2a7b1edc8de6b34f.tar.gz |
Core: Integrate `Ref::instantiate` where possible
Diffstat (limited to 'modules/mono/csharp_script.cpp')
-rw-r--r-- | modules/mono/csharp_script.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp index 6ae9ce56c6..380b401683 100644 --- a/modules/mono/csharp_script.cpp +++ b/modules/mono/csharp_script.cpp @@ -2826,7 +2826,7 @@ Ref<Resource> ResourceFormatLoaderCSharpScript::load(const String &p_path, const GDMonoCache::managed_callbacks.ScriptManagerBridge_GetOrCreateScriptBridgeForPath(&p_path, &scr); ERR_FAIL_COND_V_MSG(scr.is_null(), Ref<Resource>(), "Could not create C# script '" + real_path + "'."); } else { - scr = Ref<CSharpScript>(memnew(CSharpScript)); + scr.instantiate(); } #if defined(DEBUG_ENABLED) || defined(TOOLS_ENABLED) |