Skip to content

Commit

Permalink
Made mods show up in correct order once and for all.
Browse files Browse the repository at this point in the history
  • Loading branch information
Putnam3145 committed Mar 26, 2014
1 parent 8d48f10 commit 6800ccf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hack/scripts/gui/mod-manager.lua
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ function manager:init(args)
if v~="." and v~=".." then
local f,modData=pcall(dofile,dfhack.getHackPath().."/mods/".. v .. "/init.lua")
if f then
mods[modData.loadnum]=modData
mods[modData.name]=modData
modData.guard=modData.guard or {">>"..modData.name.." patch","<<End "..modData.name.." patch"}
modData.guard_init={"--"..modData.guard[1],"--"..modData.guard[2]}
modData.path=dfhack.getHackPath()..'/mods/'..v..'/'
Expand All @@ -126,7 +126,7 @@ function manager:init(args)
for k,v in pairs(self.mods) do
table.insert(modList,{text=k,data=v})
end

table.sort(modList,function(a,b) return a.data.loadnum<b.data.loadnum end)
self:addviews{


Expand Down

0 comments on commit 6800ccf

Please sign in to comment.