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

Talent trees are sorted by known/unknown in the levelup screen

git-svn-id: http://svn.net-core.org/repos/t-engine4@5908 51575b47-30f0-44d4-a5cc-537603b46e54
parent 6243ab28
No related branches found
No related tags found
No related merge requests found
......@@ -525,11 +525,15 @@ function _M:generateList()
end
end
table.sort(ctree, function(a, b)
return a.order_id < b.order_id
if self.actor:knowTalentType(a.type) and not self.actor:knowTalentType(b.type) then return 1
elseif not self.actor:knowTalentType(a.type) and self.actor:knowTalentType(b.type) then return nil
else return a.order_id < b.order_id end
end)
self.ctree = ctree
table.sort(gtree, function(a, b)
return a.order_id < b.order_id
if self.actor:knowTalentType(a.type) and not self.actor:knowTalentType(b.type) then return 1
elseif not self.actor:knowTalentType(a.type) and self.actor:knowTalentType(b.type) then return nil
else return a.order_id < b.order_id end
end)
self.gtree = gtree
......
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