Skip to content

System.AccessViolationException using BE builds on Unity 2023.1.7 #668

@wh0am15533

Description

@wh0am15533

What happened?

Installed BepInEx BE #673 (tried earlier also) as normally. BepInEx runs as usual and dumps the interops fine.

Game: Pawperty Damage v1.2 (You can get free on itch.io)

The issue comes when trying to do ANYTHING with the interops in my plugin. You can't even apply Harmony patches. You get an error such as shown in following.

I tried the Melon also and get the same type error. I've also tried the Dobby.dll patch (Fixes Dave the Diver) and still same error. Any idea?

BepInEx Distribution

Bleeding Edge from BepisBuilds

Log outputs

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
Repeat 2 times:
--------------------------------
   at Il2CppInterop.Runtime.IL2CPP.il2cpp_gchandle_get_target(UInt32)
--------------------------------
   at Il2CppInterop.Runtime.InteropTypes.Il2CppObjectBase.get_Pointer()
   at Il2CppInterop.Runtime.IL2CPP.Il2CppObjectBaseToPtrNotNull(Il2CppInterop.Runtime.InteropTypes.Il2CppObjectBase)
   at UnityEngine.InputSystem.Keyboard.get_f12Key()
   at Trainer.TrainerComponent.Update()

Environment

- OS: win10/win11
- BepInEx: BE Build #670-673
- Game: Pawperty Damage v1.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    errorError message or log that may need investigationneeds-replicationIssue needs to be replicated by BepInEx dev

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions