From 05ea4b90cc6c339cd5c0588ca4ce2785a7db089f Mon Sep 17 00:00:00 2001 From: Sokomine Date: Thu, 14 Apr 2022 19:34:47 +0200 Subject: [PATCH] adjusted color for trade list buttons --- trade_list.lua | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/trade_list.lua b/trade_list.lua index d7a5d17..3ac919a 100644 --- a/trade_list.lua +++ b/trade_list.lua @@ -125,9 +125,9 @@ yl_speak_up.get_fs_trade_list = function(player, show_dialog_option_trades) anz_trades = anz_trades + 1 local kstr = tostring(minetest.formspec_escape(k)) local sold_out = not(npc_inv:contains_item("npc_main", buy_stack)) - local color = "#777777" + local color = "#a37e45" --"#777777" if(sold_out) then - color = "#333333" + color = "#663333" -- still needs to contain kstr so that each button has a diffrent text kstr = "sold out "..kstr end @@ -146,7 +146,8 @@ yl_speak_up.get_fs_trade_list = function(player, show_dialog_option_trades) table.insert(formspec, "label[0,1.9;Sold out]\ncontainer_end[]") else -- show the price label only when the offer is in stock - table.insert(formspec, "label[0,4.4;Price:]\ncontainer_end[]") + table.insert(formspec, "label[0,1.9;->]".. + "label[0,4.4;Price:]\ncontainer_end[]") end col = col + 1 if(col >= yl_speak_up.trade_max_cols) then @@ -205,5 +206,5 @@ yl_speak_up.get_fs_trade_list = function(player, show_dialog_option_trades) -- kein edit_mode beim trade-formspec da nicht sinnvoll return yl_speak_up.show_fs_decorated(pname, nil, h, alternate_text, "", - table.concat(formspec, ""), nil) + table.concat(formspec, "\n"), nil) end