From 0dab238fd3360b5e9754ef370b2ac4f0a68ddd93 Mon Sep 17 00:00:00 2001 From: Ivan Date: Mon, 30 Apr 2018 00:36:30 +0200 Subject: [PATCH] Fix invalid area checks --- TShockAPI/RegionHandler.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/TShockAPI/RegionHandler.cs b/TShockAPI/RegionHandler.cs index 68cd4512..9acf6679 100644 --- a/TShockAPI/RegionHandler.cs +++ b/TShockAPI/RegionHandler.cs @@ -133,12 +133,12 @@ namespace TShockAPI continue; } - if (e.Y < region.Area.Top || e.X > region.Area.Bottom) + if (e.Y < region.Area.Top || e.Y > region.Area.Bottom) { continue; } - // Do not include the current region if it has not been protected and the includeProtected flag has not been set + // Do not include the current region if it has not been protected and the includeUnprotected flag has not been set if (!region.DisableBuild && !includeUnprotected) { continue;