Skip to content
Snippets Groups Projects
Commit 7d99dcc3 authored by Alex Ksandra's avatar Alex Ksandra
Browse files

Fixed chronomancy dialogs. So much copy/paste.

parent 03fc9e35
No related branches found
No related tags found
No related merge requests found
......@@ -42,10 +42,11 @@ function _M:init(actor)
actor.hotkey = actor.hotkey or {}
Dialog.init(self, "Contingency", game.w * 0.6, game.h * 0.8)
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - 10), height=1, auto_height=true, no_color_bleed=true, text=[[
local vsep = Separator.new{dir="horizontal", size=self.ih - 10}
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=1, auto_height=true, no_color_bleed=true, text=[[
You may select a spell for Contingency to automatically use when your life falls below a percentage. Only active spells that do not require a target may be chosen.
]]}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self:generateList()
......@@ -53,14 +54,14 @@ You may select a spell for Contingency to automatically use when your life falls
{name="", width={40,"fixed"}, display_prop="char"},
{name="Talent", width=80, display_prop="name"},
}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list.cur_col = 2
self:loadUI{
{left=0, top=0, ui=self.c_list},
{right=0, top=self.c_tut.h + 20, ui=self.c_desc},
{right=0, top=0, ui=self.c_tut},
{hcenter=0, top=5, ui=Separator.new{dir="horizontal", size=self.ih - 10}},
{hcenter=0, top=5, ui=vsep},
}
self:setFocus(self.c_list)
self:setupUI()
......
......@@ -42,10 +42,11 @@ function _M:init(actor)
actor.hotkey = actor.hotkey or {}
Dialog.init(self, "Empower", game.w * 0.6, game.h * 0.8)
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - 10), height=1, auto_height=true, no_color_bleed=true, text=[[
local vsep = Separator.new{dir="horizontal", size=self.ih - 10}
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=1, auto_height=true, no_color_bleed=true, text=[[
You may select a chronomancy spell to Empower, increasing your effective spellpower when casting that spell.
]]}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self:generateList()
......@@ -53,7 +54,7 @@ You may select a chronomancy spell to Empower, increasing your effective spellpo
{name="", width={40,"fixed"}, display_prop="char"},
{name="Talent", width=80, display_prop="name"},
}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list.cur_col = 2
self:loadUI{
......
......@@ -42,10 +42,11 @@ function _M:init(actor)
actor.hotkey = actor.hotkey or {}
Dialog.init(self, "Extension", game.w * 0.6, game.h * 0.8)
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - 10), height=1, auto_height=true, no_color_bleed=true, text=[[
local vsep = Separator.new{dir="horizontal", size=self.ih - 10}
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=1, auto_height=true, no_color_bleed=true, text=[[
You may select a chronomancy spell to Extend, increasing the duration of that spell.
]]}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self:generateList()
......@@ -53,14 +54,14 @@ You may select a chronomancy spell to Extend, increasing the duration of that sp
{name="", width={40,"fixed"}, display_prop="char"},
{name="Talent", width=80, display_prop="name"},
}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list.cur_col = 2
self:loadUI{
{left=0, top=0, ui=self.c_list},
{right=0, top=self.c_tut.h + 20, ui=self.c_desc},
{right=0, top=0, ui=self.c_tut},
{hcenter=0, top=5, ui=Separator.new{dir="horizontal", size=self.ih - 10}},
{hcenter=0, top=5, ui=vsep},
}
self:setFocus(self.c_list)
self:setupUI()
......
......@@ -42,10 +42,11 @@ function _M:init(actor)
actor.hotkey = actor.hotkey or {}
Dialog.init(self, "Matrix", game.w * 0.6, game.h * 0.8)
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - 10), height=1, auto_height=true, no_color_bleed=true, text=[[
local vsep = Separator.new{dir="horizontal", size=self.ih - 10}
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=1, auto_height=true, no_color_bleed=true, text=[[
You may select a chronomancy spell to Matrix, reducing the cooldown of that spell.
]]}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self:generateList()
......@@ -53,14 +54,14 @@ You may select a chronomancy spell to Matrix, reducing the cooldown of that spel
{name="", width={40,"fixed"}, display_prop="char"},
{name="Talent", width=80, display_prop="name"},
}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list.cur_col = 2
self:loadUI{
{left=0, top=0, ui=self.c_list},
{right=0, top=self.c_tut.h + 20, ui=self.c_desc},
{right=0, top=0, ui=self.c_tut},
{hcenter=0, top=5, ui=Separator.new{dir="horizontal", size=self.ih - 10}},
{hcenter=0, top=5, ui=vsep},
}
self:setFocus(self.c_list)
self:setupUI()
......
......@@ -42,10 +42,11 @@ function _M:init(actor)
actor.hotkey = actor.hotkey or {}
Dialog.init(self, "Quicken", game.w * 0.6, game.h * 0.8)
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - 10), height=1, auto_height=true, no_color_bleed=true, text=[[
local vsep = Separator.new{dir="horizontal", size=self.ih - 10}
self.c_tut = Textzone.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=1, auto_height=true, no_color_bleed=true, text=[[
You may select a chronomancy spell to Quicken, reducing the time it takes you to cast that spell.
]]}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self.c_desc = TextzoneList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - self.c_tut.h - 20, scrollbar=true, no_color_bleed=true}
self:generateList()
......@@ -53,14 +54,14 @@ You may select a chronomancy spell to Quicken, reducing the time it takes you to
{name="", width={40,"fixed"}, display_prop="char"},
{name="Talent", width=80, display_prop="name"},
}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - 10), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list = TreeList.new{width=math.floor(self.iw / 2 - vsep.w / 2), height=self.ih - 10, all_clicks=true, scrollbar=true, columns=cols, tree=self.list, fct=function(item, sel, button) self:use(item, button) end, select=function(item, sel) self:select(item) end}
self.c_list.cur_col = 2
self:loadUI{
{left=0, top=0, ui=self.c_list},
{right=0, top=self.c_tut.h + 20, ui=self.c_desc},
{right=0, top=0, ui=self.c_tut},
{hcenter=0, top=5, ui=Separator.new{dir="horizontal", size=self.ih - 10}},
{hcenter=0, top=5, ui=vsep},
}
self:setFocus(self.c_list)
self:setupUI()
......
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