diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-06-10 09:21:52 +0200 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-06-10 09:21:52 +0200 |
commit | 2adf62e22e1a12a16318431dfe37516a1c945776 (patch) | |
tree | 350660264f3dd67c5d34a1fd5b48c64e0fd46e91 /MCServer/Plugins/ProtectionAreas/Storage.lua | |
parent | ProtectionAreas: Fixed area reloading (diff) | |
download | cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar.gz cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar.bz2 cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar.lz cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar.xz cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.tar.zst cuberite-2adf62e22e1a12a16318431dfe37516a1c945776.zip |
Diffstat (limited to '')
-rw-r--r-- | MCServer/Plugins/ProtectionAreas/Storage.lua | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/MCServer/Plugins/ProtectionAreas/Storage.lua b/MCServer/Plugins/ProtectionAreas/Storage.lua index 10cc469e5..e21b128d5 100644 --- a/MCServer/Plugins/ProtectionAreas/Storage.lua +++ b/MCServer/Plugins/ProtectionAreas/Storage.lua @@ -192,7 +192,17 @@ function cStorage:LoadPlayerAreas(a_PlayerName, a_PlayerX, a_PlayerZ, a_WorldNam local BoundsMinZ = a_PlayerZ - g_AreaBounds;
local BoundsMaxZ = a_PlayerZ + g_AreaBounds;
- local res = cPlayerAreas:new();
+ local res = cPlayerAreas:new(
+ BoundsMinX + g_AreaSafeEdge, BoundsMinZ + g_AreaSafeEdge,
+ BoundsMaxX - g_AreaSafeEdge, BoundsMaxZ - g_AreaSafeEdge
+ );
+
+ --[[
+ LOG("Loading protection areas for player " .. a_PlayerName .. " centered around {" .. a_PlayerX .. ", " .. a_PlayerZ ..
+ "}, bounds are {" .. BoundsMinX .. ", " .. BoundsMinZ .. "} - {" ..
+ BoundsMaxX .. ", " .. BoundsMaxZ .. "}"
+ );
+ --]]
-- Load the areas from the DB, based on the player's location
local sql =
|