From c4efc96303091b4fa72c17ff155797f6090af7d5 Mon Sep 17 00:00:00 2001 From: Lucas Nicodemus Date: Wed, 13 Jul 2011 22:58:59 -0600 Subject: [PATCH] (Taking a break. If anyone wants to continue shit feel free. Just note that RegionStore.cs is completely useless because it turns out a Region class already existed. Oh and there's no constructor for it that contains allowed user IDs either, which is also dumb. --- TShockAPI/DB/RegionManager.cs | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/TShockAPI/DB/RegionManager.cs b/TShockAPI/DB/RegionManager.cs index 9fc37278..cf7bd94b 100644 --- a/TShockAPI/DB/RegionManager.cs +++ b/TShockAPI/DB/RegionManager.cs @@ -127,7 +127,7 @@ namespace TShockAPI.DB } } - public bool InProtectedArea(int X, int Y, User user) + public bool InProtectedArea(int X, int Y, User user) //This whole thing is dumb { try { @@ -273,5 +273,16 @@ namespace TShockAPI.DB DisableBuild = 1; RegionWorldID = string.Empty; } + + public bool InProtectedArea(Rectangle point, User user) + { + if (RegionArea.Intersects(point)) + { + //Todo: Code here + //Apparently we don't have access to allowed/denied user IDs here, or they aren't constructed or something + + } + return false; + } } }