diff --git a/fs_edit_options_dialog.lua b/fs_edit_options_dialog.lua index b9aa5f2..d59d075 100644 --- a/fs_edit_options_dialog.lua +++ b/fs_edit_options_dialog.lua @@ -293,8 +293,8 @@ yl_speak_up.get_fs_edit_option_dialog = function(player, n_id, d_id, o_id) -- the text the NPC says "label[0.2,0.6;NPC says ".. minetest.formspec_escape("[dialog \""..tostring(d_id).."\"]:").."]".. - "hypertext[1.2,1.2;19.6,2.5;d_text;".. - minetest.formspec_escape(n_dialog.d_text) .. "\n".."]".. + "hypertext[1.2,1.2;19.6,2.5;d_text;".. + minetest.formspec_escape(n_dialog.d_text) .. "\n]".. "tooltip[1.2,1.2;19.6,3.0;This is what the NPC says to the player.]".. -- list the preconditions "label[0.2,4.2;If all of the following pre(C)onditions are fulfilled:]".. @@ -307,23 +307,23 @@ yl_speak_up.get_fs_edit_option_dialog = function(player, n_id, d_id, o_id) "Please click on a pre(C)ondition in order\n".. "to edit or delete it!]".. -- answer of the player (the actual option) - "label[0.2,6.8;..the player may answer with this text".. + "label[0.2,6.9;..the player may answer with this text".. minetest.formspec_escape(" [dialog option \""..tostring(o_id).."\"]:").."]".. - "label[1.2,7.6;A:]".. - "field[1.7,7.1;19.1,0.9;text_option_"..minetest.formspec_escape(o_id)..";;".. + "label[1.2,7.7;A:]".. + "field[1.7,7.2;19.1,0.9;text_option_"..minetest.formspec_escape(o_id)..";;".. minetest.formspec_escape(d_option.o_text_when_prerequisites_met).."]".. "tooltip[option_text_met;This is the answer the player may choose if the ".. "preconditions are all fulfilled.]".. -- dropdown for selecting weather to show the alternate answer or not "label[0.2,8.6;..but if at least one pre(C)ondition is not fulfilled, then...]".. - "dropdown[12.0,8.2;8.6,0.9;hide_or_grey_or_alternate_answer;".. + "dropdown[12.0,8.2;8.6,0.7;hide_or_grey_or_alternate_answer;".. "..hide this answer.,".. - "..grey out this answer.,".. + "..grey out the following answer:,".. "..display the following alternate answer:;".. alternate_answer_option..";]".. -- alternate answer - "label[1.2,9.6;A:]".. - "field[1.7,9.1;19.1,0.9;option_text_not_met;;".. + "label[1.2,9.4;A:]".. + "field[1.7,8.9;19.1,0.9;option_text_not_met;;".. minetest.formspec_escape(d_option.o_text_when_prerequisites_not_met).."]".. "tooltip[option_text_not_met;This is the answer the player may choose if the ".. "preconditions are NOT all fulfilled.]".. @@ -333,30 +333,30 @@ yl_speak_up.get_fs_edit_option_dialog = function(player, n_id, d_id, o_id) "table[1.2,10.9;19.6,0.7;table_of_actions;".. list_of_actions..";0]".. -- list of effects - "label[0.2,12.0;If the player completed the above action successfully, ".. + "label[0.2,12.1;If the player completed the above action successfully, ".. "apply the following (Ef)fects:]".. "tablecolumns[text;color,span=1;text;text]".. - "table[1.2,12.3;19.6,2.0;table_of_effects;".. + "table[1.2,12.4;19.6,2.0;table_of_effects;".. list_of_effects..";0]".. - "tooltip[1.2,12.3;19.6,2.0;".. + "tooltip[1.2,12.4;19.6,2.0;".. "*All* (Ef)fects are executed after the action (if there is\n".. "one defined in this option) has been completed successfully\n".. "by the player. If there is no action defined, then the\n".. "(Ef)fects will always be executed when this option here is\n".. "selected.\n".. "Please click on an (Ef)fect in order to edit or delete it!]".. - -- ..and what the NPC will reply to that answer - "label[0.2,15.1;The NPC will react to this answer with the following dialog:]".. - "hypertext[1.2,15.7;19.6,2.5;d_text_next;".. - minetest.formspec_escape(next_text) .. "\n".."]".. - "tooltip[1.2,16.8;21.0,2.5;This is what the NPC will say next when the player has ".. - "selected this answer here.]".. -- allow to change the target dialog via a dropdown menu - "dropdown[14.8,14.7;5,0.9;d_id_"..minetest.formspec_escape(o_id)..";".. + "dropdown[13.3,14.7;7.5,0.7;d_id_"..minetest.formspec_escape(o_id)..";".. dialog_list..";"..dialog_selected..",]".. - "tooltip[14.8,14.7;5,0.9;Select the target dialog with which the NPC shall react ".. + "tooltip[13.3,14.7;7.5,0.7;Select the target dialog with which the NPC shall react ".. "to this answer. Currently, dialog "..minetest.formspec_escape(target_dialog).. " is beeing displayed.;#FFFFFF;#000000]".. + -- ..and what the NPC will reply to that answer + "label[0.2,15.1;The NPC will react to this answer with the following dialog:]".. + "hypertext[1.2,15.5;19.6,2.5;d_text_next;".. + minetest.formspec_escape(next_text) .. "\n]".. + "tooltip[1.2,16.8;21.0,2.5;This is what the NPC will say next when the player has ".. + "selected this answer here.]".. -- button: delete "button[0.2,18.7;2.0,0.9;del_option;Delete]".. "tooltip[del_option;Delete this option/answer.]".. diff --git a/functions.lua b/functions.lua index 7460997..7d20f86 100644 --- a/functions.lua +++ b/functions.lua @@ -2106,7 +2106,7 @@ yl_speak_up.edit_mode_apply_changes = function(pname, fields) " is not met, hide option/answer.") -- make sure we show this options update next result["show_next_option"] = o_id - elseif(fields.hide_or_grey_or_alternate_answer == "..grey out this answer." + elseif(fields.hide_or_grey_or_alternate_answer == "..grey out the following answer:" and d_option.o_grey_when_prerequisites_not_met ~= "true") then d_option.o_hide_when_prerequisites_not_met = "false" d_option.o_grey_when_prerequisites_not_met = "true"