public static bool receiveRightClick_Prefix(int x, int y, bool playSound, // Original arguments
ref Item ___sourceItem, ref TemporaryAnimatedSprite ___poof,
ItemGrabMenu.behaviorOnItemSelect ___behaviorFunction, bool ___essential, // Private fields
ItemGrabMenu __instance) // Special
{
try
{
Monitor.Log($"Invoked ItemGrabMenu.receiveRightClick_Prefix", LogLevel.Debug);
// Reimplemented game code
return true;
}
catch (Exception ex)
{
Monitor.Log($"Failed in {nameof(receiveRightClick_Prefix)}:\n{ex}", LogLevel.Error);
return true; // Run original code
}
}