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

fix death dialog #

backspace to go back in Birther


git-svn-id: http://svn.net-core.org/repos/t-engine4@536 51575b47-30f0-44d4-a5cc-537603b46e54
parent 5a0a9402
No related branches found
No related tags found
No related merge requests found
......@@ -73,6 +73,7 @@ function _M:init(actor, order, at_end)
_UP = function() self.sel = util.boundWrap(self.sel - 1, 1, #self.list); self.changed = true end,
_DOWN = function() self.sel = util.boundWrap(self.sel + 1, 1, #self.list); self.changed = true end,
_RETURN = function() self:next() end,
_BACKSPACE = function() self:prev() end,
}
self:mouseZones{
{ x=2, y=25, w=350, h=self.h, fct=function(button, x, y, xrel, yrel, tx, ty)
......@@ -112,6 +113,17 @@ function _M:selectType(type)
self.current_type = type
end
function _M:prev()
if not self.list then return end
self.changed = true
table.remove(self.descriptors)
self.cur_order = self.cur_order - 1
self:selectType(self.order[self.cur_order])
if #self.list == 1 then
self:prev()
end
end
function _M:next()
self.changed = true
if self.list then
......
......@@ -149,7 +149,7 @@ function _M:generateList()
end
function _M:drawDialog(s)
local help = ([[You have #LIGHT_RED#died##LAST#!
local help = ([[You have #LIGHT_RED#died#LAST#!
Death in T.o.M.E. is usually permanent, but if you have a means of resurrection it will be proposed in the menu below.
You can dump your character data to a file to remember her/him forever, or you can exit and try again to survive in the wilds!
]]):splitLines(self.iw - 10, self.font)
......
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