Theronguard / Emergency-Dice

A lethal company mod. Adds new equipment and scrap.
3 stars 3 forks source link

Dice broken in v56 #23

Open Seviper opened 4 months ago

Seviper commented 4 months ago

Howdy! Just wanted to let you that the latest update of Lethal Company has unfortunately broken this mod. Not sure what's going on under the hood, but when you roll the dice, they no longer spin and you can no longer pick them back up.

[00:02:02.3287029] [Error  : Unity Log] MissingMethodException: Method not found: void .Landmine.SpawnExplosion(UnityEngine.Vector3,bool,single,single,int,single,UnityEngine.GameObject)
Stack trace:
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)
UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator)
MysteryDice.Dice.DieBehaviour:DropAndBlock(UInt64)
MysteryDice.Dice.DieBehaviour:SyncDropClientRPC(UInt64)
MysteryDice.Dice.DieBehaviour:__rpc_handler_2874552817(NetworkBehaviour, FastBufferReader, __RpcParams)
Unity.Netcode.RpcMessageHelpers:Handle(NetworkContext&, RpcMetadata&, FastBufferReader&, __RpcParams&)
Unity.Netcode.ClientRpcMessage:Handle(NetworkContext&)
Unity.Netcode.NetworkBehaviour:__endSendClientRpc(FastBufferWriter&, UInt32, ClientRpcParams, RpcDelivery)
MysteryDice.Dice.DieBehaviour:SyncDropClientRPC(UInt64)
MysteryDice.Dice.DieBehaviour:SyncDropServerRPC(UInt64)
MysteryDice.Dice.DieBehaviour:__rpc_handler_775119853(NetworkBehaviour, FastBufferReader, __RpcParams)
Unity.Netcode.RpcMessageHelpers:Handle(NetworkContext&, RpcMetadata&, FastBufferReader&, __RpcParams&)
Unity.Netcode.ServerRpcMessage:Handle(NetworkContext&)
Unity.Netcode.NetworkBehaviour:__endSendServerRpc(FastBufferWriter&, UInt32, ServerRpcParams, RpcDelivery)
MysteryDice.Dice.DieBehaviour:SyncDropServerRPC(UInt64)
MysteryDice.Dice.DieBehaviour:ItemActivate(Boolean, Boolean)
GrabbableObject:UseItemOnClient(Boolean)
GameNetcodeStuff.PlayerControllerB:DMD<GameNetcodeStuff.PlayerControllerB::ActivateItem_performed>(PlayerControllerB, CallbackContext)
UnityEngine.InputSystem.LowLevel.<>c__DisplayClass7_0:<set_onUpdate>b__0(NativeInputUpdateType, NativeInputEventBuffer*)
UnityEngineInternal.Input.NativeInputSystem:NotifyUpdate(NativeInputUpdateType, IntPtr)

[00:02:02.3287029] [Error  : Unity Log] MissingMethodException: Method not found: void .Landmine.SpawnExplosion(UnityEngine.Vector3,bool,single,single,int,single,UnityEngine.GameObject)
Stack trace:
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)
UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator)
MysteryDice.Dice.DieBehaviour:DropAndBlock(UInt64)
MysteryDice.Dice.DieBehaviour:SyncDropClientRPC(UInt64)
MysteryDice.Dice.DieBehaviour:__rpc_handler_2874552817(NetworkBehaviour, FastBufferReader, __RpcParams)
Unity.Netcode.RpcMessageHelpers:Handle(NetworkContext&, RpcMetadata&, FastBufferReader&, __RpcParams&)
Unity.Netcode.ClientRpcMessage:Handle(NetworkContext&)
Unity.Netcode.NetworkBehaviour:__endSendClientRpc(FastBufferWriter&, UInt32, ClientRpcParams, RpcDelivery)
MysteryDice.Dice.DieBehaviour:SyncDropClientRPC(UInt64)
MysteryDice.Dice.DieBehaviour:SyncDropServerRPC(UInt64)
MysteryDice.Dice.DieBehaviour:__rpc_handler_775119853(NetworkBehaviour, FastBufferReader, __RpcParams)
Unity.Netcode.RpcMessageHelpers:Handle(NetworkContext&, RpcMetadata&, FastBufferReader&, __RpcParams&)
Unity.Netcode.ServerRpcMessage:Handle(NetworkContext&)
Unity.Netcode.NetworkBehaviour:__endSendServerRpc(FastBufferWriter&, UInt32, ServerRpcParams, RpcDelivery)
MysteryDice.Dice.DieBehaviour:SyncDropServerRPC(UInt64)
MysteryDice.Dice.DieBehaviour:ItemActivate(Boolean, Boolean)
GrabbableObject:UseItemOnClient(Boolean)
GameNetcodeStuff.PlayerControllerB:DMD<GameNetcodeStuff.PlayerControllerB::ActivateItem_performed>(PlayerControllerB, CallbackContext)
UnityEngine.InputSystem.LowLevel.<>c__DisplayClass7_0:<set_onUpdate>b__0(NativeInputUpdateType, NativeInputEventBuffer*)
UnityEngineInternal.Input.NativeInputSystem:NotifyUpdate(NativeInputUpdateType, IntPtr)

For now, someone has uploaded a fixed version of this mod so perhaps they can help with what's changed.

Theronguard commented 4 months ago

Hey, thanks for the heads up. I updated the mod and it should work now. Sadly I wrote the code before I knew enough about reflection so now with each update I have to rebuild it manually so it works with the new version.

Jack67119 commented 4 months ago

Im still having issues with the mod on the latest version of the game. The dice are spawning but just arent working at all.

Jack67119 commented 4 months ago

Specifically, my friends and I are still having the exact same issue as the op. The dice roll, don't do anything, and then cant be picked back up. No text popup or anything. This is off of the beta branch in the new release of v56.