From 6e7e3be58cfd0361cee5d28f7a9dec6ea39386c0 Mon Sep 17 00:00:00 2001 From: SX <50966843+S-S-X@users.noreply.github.com> Date: Tue, 16 Mar 2021 08:46:57 +0200 Subject: [PATCH] Optional QoS support (#13) --- .luacheckrc | 2 +- init.lua | 2 +- mod.conf | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.luacheckrc b/.luacheckrc index 722854b..88c07cb 100644 --- a/.luacheckrc +++ b/.luacheckrc @@ -21,6 +21,6 @@ read_globals = { "minecart", locator = { fields = { "beacons" } }, -- optional mods - "xban", "monitoring", + "xban", "monitoring", "QoS", "mcl_core", "mcl_sounds" } diff --git a/init.lua b/init.lua index c8ee7cc..160472e 100644 --- a/init.lua +++ b/init.lua @@ -46,7 +46,7 @@ end -- optional mapserver-bridge stuff below -local http = minetest.request_http_api() +local http = QoS and QoS(minetest.request_http_api(), 2) or minetest.request_http_api() if http then -- check if the mapserver.json is in the world-folder diff --git a/mod.conf b/mod.conf index 586bbba..d7006f6 100644 --- a/mod.conf +++ b/mod.conf @@ -1,3 +1,3 @@ name = mapserver description = Mod for the mapserver. -optional_depends = default, dye, advtrains, minecart, monitoring, bones, mcl_core, mcl_sounds, mcl_dye +optional_depends = default, dye, advtrains, minecart, monitoring, bones, mcl_core, mcl_sounds, mcl_dye, qos -- GitLab