From 360645962ff6b6ba1a8f7f4e3fac0eb861c2251e Mon Sep 17 00:00:00 2001 From: Garry Newman Date: Wed, 8 May 2019 21:15:20 +0100 Subject: [PATCH] Equality compare InventoryItem (probably need to do this to every struct) --- Facepunch.Steamworks/Structs/InventoryItem.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Facepunch.Steamworks/Structs/InventoryItem.cs b/Facepunch.Steamworks/Structs/InventoryItem.cs index 4472118..1e6b694 100644 --- a/Facepunch.Steamworks/Structs/InventoryItem.cs +++ b/Facepunch.Steamworks/Structs/InventoryItem.cs @@ -131,5 +131,8 @@ namespace Steamworks public InventoryItem Item; public int Quantity; } + + public static bool operator ==( InventoryItem a, InventoryItem b ) => a._id == b._id; + public static bool operator !=( InventoryItem a, InventoryItem b ) => a._id != b._id; } } \ No newline at end of file