|
|
@@ -414,6 +414,7 @@ local function JjcNewLadder_SendLast3Rank(human)
|
|
|
tData.worshipCnt = v.worshipCnt
|
|
|
tData.worshipState = JjcNewLadderLogic_GetWorShip(human, v.uuid)
|
|
|
end
|
|
|
+ tMsgData.tList[0] = nIndex
|
|
|
end
|
|
|
|
|
|
Msg.send(tMsgData, human.fd)
|
|
|
@@ -699,13 +700,13 @@ end
|
|
|
|
|
|
-- 点赞成功
|
|
|
function JjcNewLadderLogic_AddWorShipOK(tData)
|
|
|
- if not tLast3RankPlayerInfo then
|
|
|
+ if not tLast3RankPlayerInfo or not tLast3RankPlayerInfo.tLastRankInfo then
|
|
|
print("[JjcNewLadderLogic_AddWorShipOK] 为什么点赞完不存在数据了")
|
|
|
return
|
|
|
end
|
|
|
|
|
|
local uuidDes, nNowWorShip = tData.uuidDes, tData.nNowWorShip
|
|
|
- for _, v in pairs(tLast3RankPlayerInfo) do
|
|
|
+ for _, v in pairs(tLast3RankPlayerInfo.tLastRankInfo) do
|
|
|
if v.uuid == uuidDes then
|
|
|
v.worshipCnt = nNowWorShip
|
|
|
break
|
|
|
@@ -737,12 +738,12 @@ end
|
|
|
|
|
|
-- 更新缓存的点赞数据
|
|
|
function JjcNewLadderLogic_UpdateWorShip(tData)
|
|
|
- if not tLast3RankPlayerInfo then
|
|
|
+ if not tLast3RankPlayerInfo or not tLast3RankPlayerInfo.tLastRankInfo then
|
|
|
print("[JjcNewLadderLogic_UpdateWorShip] 更新缓存的点赞数据 为什么不存在数据了")
|
|
|
return
|
|
|
end
|
|
|
|
|
|
- for _, v in pairs(tLast3RankPlayerInfo) do
|
|
|
+ for _, v in pairs(tLast3RankPlayerInfo.tLastRankInfo) do
|
|
|
if v.uuid == tData.uuidDes then
|
|
|
v.worshipCnt = tData.nNowWorShip
|
|
|
break
|
|
|
@@ -756,6 +757,9 @@ function JjcNewLadderLogic_GetRankInfo(tData)
|
|
|
local nFirst = 1
|
|
|
for i = 1, JjcNewLadderDefine.JJC_NEWLADDER_RANK_SEND_LEN, 1 do
|
|
|
local tRank = JjcNewLadderDB.JjcNewLadderDB_GetDBDataByRank(i)
|
|
|
+ if not tRank then
|
|
|
+
|
|
|
+ end
|
|
|
table.insert(tSendRankData, {tRankData = tRank, nRank = i})
|
|
|
|
|
|
local nLen = #tSendRankData
|
|
|
@@ -1162,7 +1166,7 @@ end
|
|
|
|
|
|
-- 膜拜
|
|
|
function JjcNewLadderLogic_Worship(human, uuid)
|
|
|
- if not tLast3RankPlayerInfo then
|
|
|
+ if not tLast3RankPlayerInfo or not tLast3RankPlayerInfo.tLastRankInfo then
|
|
|
print("[JjcNewLadderLogic_Worship] 不存在上一轮数据排名前3的数据")
|
|
|
return
|
|
|
end
|
|
|
@@ -1173,7 +1177,7 @@ function JjcNewLadderLogic_Worship(human, uuid)
|
|
|
end
|
|
|
|
|
|
local nServerID
|
|
|
- for _, v in pairs(tLast3RankPlayerInfo) do
|
|
|
+ for _, v in pairs(tLast3RankPlayerInfo.tLastRankInfo) do
|
|
|
if v.uuid == uuid then
|
|
|
nServerID = v.nServerID
|
|
|
break
|