From b11e9bfb18b7bdf62993a003051bebcfb0284554 Mon Sep 17 00:00:00 2001 From: chmodsayshello Date: Thu, 6 Oct 2022 22:32:40 +0200 Subject: [PATCH] fix hud not being centered on all screens --- hud.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hud.lua b/hud.lua index c29932b..ac6cab4 100644 --- a/hud.lua +++ b/hud.lua @@ -3,17 +3,17 @@ function create_huds(arena) local function create(player) scoreboard_blue = minetest.get_player_by_name(player):hud_add({ hud_elem_type = "text", - position = {x = 1, y = 0}, - offset = {x=-600, y = 50}, - scale = {x = 1, y = 1}, + position = {x =0.35, y = 0}, + offset = {x=0, y = 50}, + scale = {x = 100, y = 100}, text = "0", number = 0x0001FF, }) scoreboard_red = minetest.get_player_by_name(player):hud_add({ hud_elem_type = "text", - position = {x = 1, y = 0}, - offset = {x=-400, y = 50}, + position = {x = 0.65, y = 0}, + offset = {x=0, y = 50}, scale = {x = 400, y = 1}, text = "0", number = 0xFF0000