Skip to content

Commit 910844a

Browse files
authored
Fix manager GameObject not having a name (#735)
1 parent f0c0add commit 910844a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Runtimes/Unity/BepInEx.Unity.IL2CPP/Utils/Il2CppUtils.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using System;
1+
using System;
22
using Il2CppInterop.Runtime;
33
using Il2CppInterop.Runtime.Injection;
44
using Il2CppInterop.Runtime.InteropTypes;
@@ -14,7 +14,7 @@ internal static class Il2CppUtils
1414
public static Il2CppObjectBase AddComponent(Type t)
1515
{
1616
if (managerGo == null)
17-
managerGo = new GameObject { hideFlags = HideFlags.HideAndDontSave };
17+
managerGo = new GameObject { hideFlags = HideFlags.HideAndDontSave, name = "BepInEx_Manager" };
1818

1919
if (!ClassInjector.IsTypeRegisteredInIl2Cpp(t))
2020
ClassInjector.RegisterTypeInIl2Cpp(t);

0 commit comments

Comments
 (0)