From f7e607f01734d4c1be0daf38d788ae4e7c6e097f Mon Sep 17 00:00:00 2001 From: mckaygerhard Date: Tue, 28 May 2024 13:51:47 -0400 Subject: [PATCH] provide backaguard falback on older servers, biome data functions missing * will work with 0.4 servers like just test and famous subnasa * make it work with older versions of minetest --- commands.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/commands.lua b/commands.lua index 0b9e5df..604fb7d 100644 --- a/commands.lua +++ b/commands.lua @@ -174,6 +174,11 @@ if essentials.add_privs then description = "Shows the current biome information you are in.", func = function(name, param) local pos = minetest.get_player_by_name(name):get_pos() + if not minetest.has_feature("object_use_texture_alpha") then + core.chat_send_player(name, core.colorize("red", "Biome info cannot retrieve, server engine does not support the command!")) + minetest.sound_play("error", name) + minetest.log("error","[essentials] server mineitest engine too old, biome data not supported!, upgrade server") + end local biomeinfo = minetest.get_biome_data(pos) local biome = minetest.get_biome_name(biomeinfo.biome) if param == "" then