summaryrefslogtreecommitdiff
path: root/src/SMAPI/Framework/CursorPosition.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/SMAPI/Framework/CursorPosition.cs')
-rw-r--r--src/SMAPI/Framework/CursorPosition.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/SMAPI/Framework/CursorPosition.cs b/src/SMAPI/Framework/CursorPosition.cs
index 6f716746..aaf089d3 100644
--- a/src/SMAPI/Framework/CursorPosition.cs
+++ b/src/SMAPI/Framework/CursorPosition.cs
@@ -36,5 +36,12 @@ namespace StardewModdingAPI.Framework
this.Tile = tile;
this.GrabTile = grabTile;
}
+
+ /// <summary>Get whether the current object is equal to another object of the same type.</summary>
+ /// <param name="other">An object to compare with this object.</param>
+ public bool Equals(ICursorPosition other)
+ {
+ return other != null && this.ScreenPixels == other.ScreenPixels;
+ }
}
}