diff --git a/game/engines/default/engine/utils.lua b/game/engines/default/engine/utils.lua index aca0c13fd0e3f402da02ac0312176478f86ec579..26e13735e24644cd536faa5bf2d09df6020ead1e 100644 --- a/game/engines/default/engine/utils.lua +++ b/game/engines/default/engine/utils.lua @@ -338,6 +338,12 @@ function string.his_her(actor) end end +function string.his_her_self(actor) + if actor.female then return "herself" + else return "himself" + end +end + function string.capitalize(str) if #str > 1 then return string.upper(str:sub(1, 1))..str:sub(2) diff --git a/game/modules/tome/data/chats/sorcerer-end.lua b/game/modules/tome/data/chats/sorcerer-end.lua index 91b342bfb4dd55eadd054ba75d849d939121639c..351ee2df22c75962dcf47d2a031154e618aeee4b 100644 --- a/game/modules/tome/data/chats/sorcerer-end.lua +++ b/game/modules/tome/data/chats/sorcerer-end.lua @@ -48,7 +48,7 @@ The Way will never forget you. Now go and make history! answers = { {"#LIGHT_GREEN#[sacrifice yourself to bring the Way to every sentient creature.]", action=function(npc, player) player.no_resurrect = true - player:die(player) + player:die(player, {special_death_msg="sacrificing "..string.his_her_self(player).." to bring the Way to all"}) player:setQuestStatus("high-peak", engine.Quest.COMPLETED, "yeek") player:hasQuest("high-peak"):win("yeek-sacrifice") end}, @@ -63,7 +63,7 @@ You will do as asked, for the good of all Yeeks! The Way is always right. answers = { {"#LIGHT_GREEN#[sacrifice yourself to bring the Way to every sentient creature.]", action=function(npc, player) player.no_resurrect = true - player:die(player) + player:die(player, {special_death_msg="sacrificing "..string.his_her_self(player).." to bring the Way to all"}) player:setQuestStatus("high-peak", engine.Quest.COMPLETED, "yeek") player:hasQuest("high-peak"):win("yeek-sacrifice") end}, @@ -88,7 +88,7 @@ After searching the remains of the Sorcerers you find a note explaining that the {"Aeryn, I am sorry but one of us needs to be sacrificed for the world to go on. #LIGHT_GREEN#[sacrifice Aeryn for the sake of the world]", jump="aeryn-sacrifice", cond=aeryn_alive}, {"I will close it. #LIGHT_GREEN#[sacrifice yourself for the sake of the world]", action=function(npc, player) player.no_resurrect = true - player:die(player) + player:die(player, {special_death_msg="sacrificing "..string.his_her_self(player).." for the sake of the world"}) player:hasQuest("high-peak"):win("self-sacrifice") end}, }