[X] I have searched the GitHub issues for my bug, even in the closed issues.
All of the following are optional to answer
[ ] Tried reinstalling the Game.
[X] Tried reinstalling MelonLoader.
[ ] Tried restarting PC.
[X] Was able to see the Start Screen.
Describe the issue.
Latest.log
This issue occured when i tried to register class in Il2Cpp that inherits from ingame Il2Cpp type.
Ingame type had virtual method with arguments that have ingame Il2Cpp type.
It looks like all ingame types are in "Il2Cpp" namespace when referencing generated assembly: Il2Cpp.CubeConnector, Assembly-CSharp, while Il2CppInterop ClassInjector tries to find type name and ignores that: CubeConnector, Assembly-CSharp
I fixed it with this patch:
[HarmonyPatch(typeof(ClassInjector), "GetIl2CppTypeFullName")]
internal static class ClassInjectorPatch
{
public static void Postfix(ref string __result)
{
if (__result.Contains("Assembly-CSharp"))
{
__result = "Il2Cpp." + __result;
MelonLogger.Msg(__result);
}
}
}
Did you attach your log file?
Yes, I attached my log file to the text box above.
All of the following criteria must be met
All of the following are optional to answer
Describe the issue.
Latest.log This issue occured when i tried to register class in Il2Cpp that inherits from ingame Il2Cpp type. Ingame type had virtual method with arguments that have ingame Il2Cpp type. It looks like all ingame types are in "Il2Cpp" namespace when referencing generated assembly:
Il2Cpp.CubeConnector, Assembly-CSharp
, while Il2CppInterop ClassInjector tries to find type name and ignores that:CubeConnector, Assembly-CSharp
I fixed it with this patch:
Did you attach your log file?
Yes, I attached my log file to the text box above.