Crashed on Unity3D(2021.3.14f1 or higher)
RiritoNinigaya opened this issue · 23 comments
Mono Mode is Crashed Unity3D(2021.3.14f1 or higher)... Idk why, but it's strange...
IL2Cpp Mode Is Not Crashed Unity3D!!!
auto CoreModule = UnityResolve::Get("UnityEngine.CoreModule.dll");
auto camerafunction = CoreModule->Get("Camera", "UnityEngine");
float fov = camerafunction->GetValue<float>(camerafunction, "fieldOfView");
Modified code is as follows
auto CoreModule = UnityResolve::Get("UnityEngine.CoreModule.dll");
auto camerafunction = CoreModule->Get("Camera", "UnityEngine");
auto instance = UnityResolve::UnityType::Camera::GetMain();
float fov = camerafunction->GetValue<float>(instance, "fieldOfView");
ok, thanks
auto CoreModule = UnityResolve::Get("UnityEngine.CoreModule.dll");
auto camerafunction = CoreModule->Get("Camera", "UnityEngine");
float fov = camerafunction->GetValue<float>(camerafunction, "fieldOfView");
It is Not Crashing... Init Function is Calling Crash on Unity3D....
It's not a Windows bug. Currently, we are fixing the issue. The error originates from the line
if (pField->static_field) pField->vTable = Invoke<void*>("mono_class_vtable", pDomain, pClass);
again crash... T_T
Exception thrown at 0x00007FF8BAEAC8F3 (mono-2.0-bdwgc.dll) in GeckoGirlProject.exe: 0xC0000005: Access violation reading location 0x0000000000000110.
And I'm Getting This Exception while Getting Camera Function...
Exception thrown at 0x00007FF8BAEAC8F3 (mono-2.0-bdwgc.dll) in GeckoGirlProject.exe: 0xC0000005: Access violation reading location 0x0000000000000110.
And I'm Getting This Exception while Getting Camera Function...
Could you please provide the code?
Exception thrown at 0x00007FF8BAEAC8F3 (mono-2.0-bdwgc.dll) in GeckoGirlProject.exe: 0xC0000005: Access violation reading location 0x0000000000000110.
我在获得相机功能时遇到此异常......
Perhaps you can use exception handling to solve it. (SEH)
try {} catch() {}
or
__try {} __except (EXCEPTION_EXECUTE_HANDLER) {}
again crash... T_T
Error With New Version:
Exception thrown at 0x00007FFF08F560F5 (mono-2.0-bdwgc.dll) in GeckoGirlProject.exe: 0xC0000005: Access violation reading location 0xFFFFFFFFFFFFFFFF.
Code while crashing in mono:
if (address_[funcName] != nullptr) return reinterpret_cast<Return(UNITY_CALLING_CONVENTION*)(Args...)>(address_[funcName])(args...)
Now i'm getting this error while getting camera function in il2cpp:
Exception thrown at 0x00007FFEEA3C739A (4dd5de18.dll) in Holoearth.exe: 0xC0000005: Access violation reading location 0x0000000000000038.
Code:
auto GetValue(void* obj, const std::string& name) -> RType { return *reinterpret_cast<RType*>(reinterpret_cast<uintptr_t>(obj) + Get<Field>(name)->offset); }
现在我在 il2cpp 中获取相机功能时收到此错误:
Exception thrown at 0x00007FFEEA3C739A (4dd5de18.dll) in Holoearth.exe: 0xC0000005: Access violation reading location 0x0000000000000038.
法典:
auto GetValue(void* obj, const std::string& name) -> RType { return *reinterpret_cast<RType*>(reinterpret_cast<uintptr_t>(obj) + Get<Field>(name)->offset); }
GetValue is used to retrieve field values, but as far as I know, UnityEngine.Camera does not have any retrievable fields (fields of static properties do not have memory offsets).
现在我在 il2cpp 中获取相机功能时收到此错误:
Exception thrown at 0x00007FFEEA3C739A (4dd5de18.dll) in Holoearth.exe: 0xC0000005: Access violation reading location 0x0000000000000038.
法典:
auto GetValue(void* obj, const std::string& name) -> RType { return *reinterpret_cast<RType*>(reinterpret_cast<uintptr_t>(obj) + Get<Field>(name)->offset); }GetValue is used to retrieve field values, but as far as I know, UnityEngine.Camera does not have any retrievable fields (fields of static properties do not have memory offsets).
just the opposite, you can retrieve not static field value(as public int offset_name), but it will be difficult
In fact, UnityEngine.Camera only has static fields. The content in the link you provided is the property ( float depth { get; set; } ) in UnityEngine.Camera, not a field in the form of ( float depth; ). Please use a method like float get_depth() to retrieve it.
OMG, I fixed get and set the field of view :D
reopen pls
this is not the end yet, the issue with Mono remains to be resolved
Code while crashing in mono:
if (address_[funcName] != nullptr) return reinterpret_cast<Return(UNITY_CALLING_CONVENTION*)(Args...)>(address_[funcName])(args...)
Can you provide some call stack information?
Code while crashing in mono:
if (address_[funcName] != nullptr) return reinterpret_cast<Return(UNITY_CALLING_CONVENTION*)(Args...)>(address_[funcName])(args...)Can you provide some call stack information?
How?!