Skip to content
Snippets Groups Projects
Commit eb2ddb1c authored by dg's avatar dg
Browse files

New achievement for saving all the lumberjacks

git-svn-id: http://svn.net-core.org/repos/t-engine4@6433 51575b47-30f0-44d4-a5cc-537603b46e54
parent f27c0435
No related branches found
No related tags found
No related merge requests found
......@@ -168,6 +168,11 @@ newAchievement{
show = "name",
desc = [[Killed Ben Cruthdar the Cursed.]],
}
newAchievement{
name = "Fast Curse Dispel", id = "CURSE_ALL",
show = "name",
desc = [[Killed Ben Cruthdar the Cursed while saving all the lumberjacks.]],
}
newAchievement{
name = "Eye of the storm", id = "EYE_OF_THE_STORM",
show = "name",
......
......@@ -60,13 +60,16 @@ on_status_change = function(self, who, status, sub)
game:addEntity(game.level, o, "object")
o:identify(true)
who:addObject(who.INVEN_INVEN, o)
require("engine.ui.Dialog"):simplePopup("Thanks", ("You saved most of us, please take this has a reward. (They give you %s)"):format(o:getName{do_color=true}))
require("engine.ui.Dialog"):simplePopup("Thanks", ("You saved %s of us, please take this has a reward. (They give you %s)"):format(self.lumberjacks_died == 0 and "all" or "most", o:getName{do_color=true}))
end
end
who:setQuestStatus(self.id, engine.Quest.DONE)
game:setAllowedBuild("afflicted")
game:setAllowedBuild("afflicted_cursed", true)
world:gainAchievement("CURSE_ERASER", game.player)
if self.lumberjacks_died == 0 then
world:gainAchievement("CURSE_ALL", game.player)
end
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment