InvalidProgramException: Invalid IL code in ModularCarCodeLock:HasLockPermission (BasePlayer): IL_003f: retSolved

Hi!

Not sure if related, but I'm getting this error since todays update (I updated to 1.13.1).
This is the only plugin that I have that affects vehicles; so I unloaded it for now.

InvalidProgramException: Invalid IL code in ModularCarCodeLock:HasLockPermission (BasePlayer): IL_003f: ret       
  at ModularCarCodeLock.PlayerCanUseThis (BasePlayer player, ModularCarCodeLock+LockType lockType) [0x0000d] in <0639406c7f0540ea9fcd082648f6903f>:0 
  at ModularCar.PlayerCanUseThis (BasePlayer player, ModularCarCodeLock+LockType lockType) [0x00006] in <0639406c7f0540ea9fcd082648f6903f>:0 
  at ModularCar.CanBeLooted (BasePlayer player) [0x00016] in <0639406c7f0540ea9fcd082648f6903f>:0 
  at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.ModularCar.RPC_OpenFuel_Patch0(ModularCar,BaseEntity/RPCMessage)
  at ModularCar.OnRpcMessage (BasePlayer player, System.UInt32 rpc, Network.Message msg) [0x000a1] in <0639406c7f0540ea9fcd082648f6903f>:0 
UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object)
UnityEngine.DebugLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
ModularCar:OnRpcMessage(BasePlayer, UInt32, Message)
BaseEntity:SV_RPCMessage(UInt32, Message)
ServerMgr:OnRPCMessage(Message)
ServerMgr:OnNetworkMessage(Message)
Facepunch.Network.Raknet.Server:ProcessRead(NetRead)
MonoMod.Utils.DynamicMethodDefinition:Network.BaseNetwork.Cycle_Patch0(BaseNetwork)
MonoMod.Utils.DynamicMethodDefinition:ServerMgr.Update_Patch0(ServerMgr)​

In case it is relevant; this is my config:

{
  "Allow NPCs to bypass locks": false,
  "Allow deploying locks onto vehicles owned by other players": false,
  "Allow deploying locks onto unowned vehicles": true,
  "Require cupboard auth to deploy locks onto unowned vehicles": false,
  "Auto claim unowned vehicles when deploying locks": false,
  "Auto replace vehicle ownership when deploying locks": false,
  "Allow pushing vehicles while locked out": true,
  "Cooldown to auto craft locks (seconds)": 10.0,
  "Modular car settings": {
    "Allow editing while locked out": true
  },
  "Lock sharing settings": {
    "Clan": true,
    "Clan or ally": false,
    "Friends": false,
    "Team": true
  },
  "Auto unlock idle vehicles": {
    "Enabled": true,
    "Unlock after idle time (seconds)": 7200.0,
    "Check interval seconds": 300.0,
    "Exempt owned vehicles": true,
    "Exempt vehicles near cupboards": true
  }
}​


Merged post

I now have reports of other players getting kicked for checking fuel tanks; so unlikely that it is this plugin and just an Oxide or Rust server issue.

Merged post

Confirmed Oxide issue, disregard all above :)
Locked automatically