diff --git a/fs_add_quest_steps.lua b/fs_add_quest_steps.lua index c2271d0..7770083 100644 --- a/fs_add_quest_steps.lua +++ b/fs_add_quest_steps.lua @@ -661,10 +661,7 @@ yl_speak_up.get_fs_add_quest_steps = function(player, param) local name_txt = "- ? -" local dialog_txt = "- ? -" local option_txt = "- ? -" - if(dialog and dialog.n_dialogs and d_id and o_id - and dialog.n_dialogs[d_id] - and dialog.n_dialogs[d_id].d_options - and dialog.n_dialogs[d_id].d_options[o_id]) then + if(yl_speak_up.check_if_dialog_has_option(dialog, d_id, o_id)) then dialog_txt = dialog.n_dialogs[d_id].d_text or "- ? -" option_txt = dialog.n_dialogs[d_id].d_options[o_id].o_text_when_prerequisites_met or "- ? -" name_txt = (dialog.n_npc or "- ? -")