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

update

git-svn-id: http://svn.net-core.org/repos/t-engine4@1028 51575b47-30f0-44d4-a5cc-537603b46e54
parent 60c474ef
No related branches found
No related tags found
No related merge requests found
......@@ -221,7 +221,7 @@ function _M:getNews()
print("[ONLINE PROFILE] get news")
local data = self:rpc{action="GetNews"}
if not data then print("[ONLINE PROFILE] no news") return end
print("[ONLINE PROFILE] news ", data[1] and data[1].title)
print("[ONLINE PROFILE] news ", data.title)
return data
end
......
......@@ -45,7 +45,7 @@ function _M:set(str, ...)
if w > self.w then self.w = w end
self.h = self.h + self.font_h
end
self.w = self.w + 8
self.w = math.min(self.w, self.max) + 8
self.h = self.h + 8
self.changed = true
end
......
......@@ -217,19 +217,25 @@ function _M:selectStepMain()
core.game.exit_engine()
end,
},
}, 400, self.h * 0.2, self.w * 0.4, self.h * 0.3)
}, 400 + 8 + 10, self.h * 0.2, self.w * 0.4, self.h * 0.3)
if not self.news then
self.news = profile:getNews()
if not self.news or not self.news[1] then
self.nesw = {
if not self.news then
self.news = {
title = 'Welcome to T-Engine and the Tales of Middle-earth',
text = [[From this interface you can create new characters for the game modules you want to play.
T-Engine comes by default with the "Tales of Middle-earth" module, you can also install more by selecting "Install a game module" or by going to http://te4.org/
]]
#GOLD#"Tales of Middle-earth"#WHITE# is the default game module, you can also install more by selecting "Install a game module" or by going to http://te4.org/
When inside a module remember you can press Escape to bring up a menu to change keybindings, resolution and other module specific options.
Remember that in most roguelikes death is usualy permanent so be careful!
Now go and have some fun!]]
}
end
self.tooltip:set("%s\n---\n%s", self.news[1].title, self.news[1].text)
self.tooltip:set("#AQUAMARINE#%s#WHITE#\n---\n%s", self.news.title, self.news.text)
end
self.step.do_tooltip = true
......
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