diff --git a/game/modules/tome/dialogs/DeathDialog.lua b/game/modules/tome/dialogs/DeathDialog.lua index 7962735fb4fe260eae987676f67969bfb4d7cb0d..d1a7fcc9ad61efc58c72ff0618de3eaaed7e07b8 100644 --- a/game/modules/tome/dialogs/DeathDialog.lua +++ b/game/modules/tome/dialogs/DeathDialog.lua @@ -166,17 +166,19 @@ function _M:generateList() local list = {} if config.settings.cheat then list[#list+1] = {name="Resurrect by cheating", action="cheat"} end - if self.actor:attr("easy_mode_lifes") then list[#list+1] = {name=("Resurrect with easy mode (%d left)"):format(self.actor.easy_mode_lifes), action="easy_mode"} end - if self.actor:attr("blood_life") and not self.actor:attr("undead") then list[#list+1] = {name="Resurrect with the Blood of Life", action="blood_life"} end - if self.actor:getTalentLevelRaw(self.actor.T_SKELETON_REASSEMBLE) >= 5 and not self.actor:attr("re-assembled") then list[#list+1] = {name="Re-assemble your bones and resurrect (Skeleton ability)", action="skeleton"} end - - local consumenb = 1 - self.actor:inventoryApplyAll(function(inven, item, o) - if o.one_shot_life_saving and (not o.slot or inven.worn) then - list[#list+1] = {name="Resurrect by consuming "..o:getName{do_colour=true}, action="consume"..consumenb, inven=inven, item=item, object=o} - consumenb = consumenb + 1 - end - end) + if not self.actor.no_resurrect then + if self.actor:attr("easy_mode_lifes") then list[#list+1] = {name=("Resurrect with easy mode (%d left)"):format(self.actor.easy_mode_lifes), action="easy_mode"} end + if self.actor:attr("blood_life") and not self.actor:attr("undead") then list[#list+1] = {name="Resurrect with the Blood of Life", action="blood_life"} end + if self.actor:getTalentLevelRaw(self.actor.T_SKELETON_REASSEMBLE) >= 5 and not self.actor:attr("re-assembled") then list[#list+1] = {name="Re-assemble your bones and resurrect (Skeleton ability)", action="skeleton"} end + + local consumenb = 1 + self.actor:inventoryApplyAll(function(inven, item, o) + if o.one_shot_life_saving and (not o.slot or inven.worn) then + list[#list+1] = {name="Resurrect by consuming "..o:getName{do_colour=true}, action="consume"..consumenb, inven=inven, item=item, object=o} + consumenb = consumenb + 1 + end + end) + end list[#list+1] = {name="Character dump", action="dump"} list[#list+1] = {name="Restart the same character", action="exit", subaction="restart"}