|
|
@@ -23,7 +23,7 @@ local AbsActLogic = require("absAct.AbsActLogic")
|
|
|
function loadBoard()
|
|
|
-- 角色
|
|
|
local cnt = 0
|
|
|
- LuaMongo.find(DB.db_char, nil, BillboardDB.fields)
|
|
|
+ LuaMongo.find(DB.db_char, nil, BillboardDB.newFiles)
|
|
|
while true do
|
|
|
local data = {}
|
|
|
if not LuaMongo.next(data) then
|
|
|
@@ -62,7 +62,8 @@ end
|
|
|
function getValues(boardType, db)
|
|
|
if boardType == BillboardDefine.TYPE_BATTLE then
|
|
|
local fininID = db.guajiID
|
|
|
- return (fininID > 0) and fininID
|
|
|
+ local passTimes = db.maxBattleTime or 0
|
|
|
+ return (fininID > 0) and fininID, passTimes
|
|
|
elseif boardType == BillboardDefine.TYPE_TOWER then
|
|
|
if db.tower and (db.tower.lv or 0) > 0 then
|
|
|
return db.tower.lv, db.tower.usetime
|
|
|
@@ -93,7 +94,7 @@ function cmpValues(boardType, data1, data2)
|
|
|
return data1.value1 > data2.value1
|
|
|
end
|
|
|
if data1.value2 ~= data2.value2 then
|
|
|
- if boardType == BillboardDefine.TYPE_TOWER then
|
|
|
+ if boardType == BillboardDefine.TYPE_TOWER or boardType == BillboardDefine.TYPE_BATTLE then
|
|
|
return data1.value2 < data2.value2
|
|
|
else
|
|
|
return data1.value2 > data2.value2
|