Handle large protected depths

Portals will now fail to ignite instead of defaulting to a fallback depth of (starty - 256) when no unprotected target can be found.
The search depth is also increased from (starty - 256) to (starty - 646)

This is to properly handle large protected areas that are sometimes set up at spawn - see issue #26
This commit is contained in:
Treer
2020-07-29 23:45:16 +10:00
parent e326a94266
commit 02d062b9c9
3 changed files with 30 additions and 9 deletions

View File

@@ -100,7 +100,7 @@ function nether.debug(message, ...)
end
end
local composed_message = string.format(message, unpack(args))
local composed_message = "nether: " .. string.format(message, unpack(args))
if math.floor(DEBUG_FLAGS / 1) % 2 == 1 then print(composed_message) end
if math.floor(DEBUG_FLAGS / 2) % 2 == 1 then minetest.chat_send_all(composed_message) end