From 3136fda33e6312296242ac635081d97ae366504c Mon Sep 17 00:00:00 2001 From: Alexsandro Percy Date: Sat, 11 Jun 2022 13:05:40 -0300 Subject: [PATCH] dialog improvement --- manual.lua | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/manual.lua b/manual.lua index 4dd4d6b..b5b42fa 100755 --- a/manual.lua +++ b/manual.lua @@ -17,13 +17,14 @@ end minetest.register_on_player_receive_fields(function(player, formname, fields) if formname == "steampunk_blimp:manual_main" then + local formspec_color = "#44444466" if fields.short then local text = { "Shortcuts \n\n", "* Right click: enter in / acess the internal menu \n", "* Punch with dye to paint the primary color\n", "* Punch a dye, but holding Aux (E) key to change the secondary color.\n", - "* To change the blimp logo, call the command \"/blimp_logo\".\n", + "* To change the blimp logo, call the command \""..core.colorize('#ffff00', "/blimp_logo").."\".\n", "* Forward or backward while in drive position: controls the power lever \n", "* Left or right while in drive position: controls the direction \n", "* Jump and sneak: controls the up and down movement \n", @@ -34,6 +35,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) local shortcut_form = table.concat({ "formspec_version[3]", "size[16,10]", + "no_prepend[]", + "bgcolor["..formspec_color..";false]", "label[1.0,2.0;", table.concat(text, ""), "]", }, "") minetest.show_formspec(player:get_player_name(), "steampunk_blimp:manual_shortcut", shortcut_form) @@ -50,6 +53,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) local fuel_form = table.concat({ "formspec_version[3]", "size[16,10]", + "no_prepend[]", + "bgcolor["..formspec_color..";false]", "label[1.0,2.0;", table.concat(text, ""), "]", }, "") minetest.show_formspec(player:get_player_name(), "steampunk_blimp:fuel", fuel_form) @@ -58,16 +63,18 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) local text = { "Sharing \n\n", "This vehicle was made to be shared with a team. So the owner can set more users to \n", - "operate it. Inside the blimp, just use the command \"/blimp_share \" \n", - "To remove someone from the sharing, \"/blimp_remove \" \n", - "To list the owners, \"/blimp_list\" \n", - "Is possible to lock the blimp access, so only the owners can enter: \"/blimp_lock true\" \n", - "To let anyone enter, \"/blimp_lock false\" \n", + "operate it. Inside the blimp, just use the command \""..core.colorize('#ffff00', "/blimp_share ").."\" \n", + "To remove someone from the sharing, \""..core.colorize('#ffff00', "/blimp_remove ").."\" \n", + "To list the owners, \""..core.colorize('#ffff00', "/blimp_list").."\" \n", + "Is possible to lock the blimp access, so only the owners can enter: \""..core.colorize('#ffff00', "/blimp_lock true").."\" \n", + "To let anyone enter, \""..core.colorize('#ffff00', "/blimp_lock false").."\" \n", "All shared owners can access the blimp inventory" } local tips_form = table.concat({ "formspec_version[3]", "size[16,10]", + "no_prepend[]", + "bgcolor["..formspec_color..";false]", "label[1,2;", table.concat(text, ""), "]", }, "") minetest.show_formspec(player:get_player_name(), "steampunk_blimp:share", tips_form)