diff --git a/lua/app/ui/hero/hero_comp.lua b/lua/app/ui/hero/hero_comp.lua index 34b86c67..7a5c1a99 100644 --- a/lua/app/ui/hero/hero_comp.lua +++ b/lua/app/ui/hero/hero_comp.lua @@ -122,18 +122,21 @@ function HeroComp:sortHeroList() local heroEntity = HeroData:getHeroById(info.cfgId) local sort = info.cfgId -- id 预留6位 sort = sort + (10 - info.elementType) * 1000000 -- 位置预留1位 - + sort = sort + 10000000 * heroEntity:getQlt() -- 品质1位 + sort = sort + 100000000 * heroEntity:getLv() -- 预留3位 if heroEntity:isUnlock() then - sort = sort + 30000000 + sort = sort + 300000000000 + if heroEntity:isActived() then + sort = sort + 400000000000 + else + sort = sort + 300000000000 + end elseif DataManager.BagData.ItemData:getItemNumById(heroEntity:getFragmentId()) > 0 then - sort = sort + 20000000 + sort = sort + 200000000000 else - sort = sort + 10000000 + sort = sort + 100000000000 end - sort = sort + 100000000 * heroEntity:getQlt() -- 品质1位 - sort = sort + 1000000000 * heroEntity:getLv() -- 预留3位 - info.sort = sort end table.sort(self.heroList, function(a, b)