Commit ce42bb0339857363f0b61faf5b21b9f55a610e7f
Merge branch 'develop' of 120.26.43.151:wasteland/server into develop
Showing
7 changed files
with
29 additions
and
16 deletions
Show diff stats
src/actions/ActivityAction.lua
| ... | ... | @@ -138,6 +138,7 @@ function _M.signRpc(agent, data) |
| 138 | 138 | |
| 139 | 139 | local reward, change = role:award(monthData[curDay].item, {log = {desc = "sign", int1 = yearMonth, int2 = curDay}}) |
| 140 | 140 | role:changeUpdates({{type = "sign", field = curDay, value = yearMonth}}) |
| 141 | + role:checkTaskEnter("SignIn") | |
| 141 | 142 | |
| 142 | 143 | SendPacket(actionCodes.Activity_signRpc, MsgPack.pack(role:packReward(reward, change))) |
| 143 | 144 | return true | ... | ... |
src/actions/HangAction.lua
| ... | ... | @@ -483,9 +483,11 @@ function _M.buyBonusCountRpc(agent, data) |
| 483 | 483 | if not TimeReset["DailyBattle" .. btype] then return end |
| 484 | 484 | local open, actId = role.activity:isOpen("BonusDouble") |
| 485 | 485 | local actData = csvdb["activity_ctrlCsv"][actId] |
| 486 | - if not actData then return end | |
| 487 | 486 | |
| 488 | - local coef = open and tonumber(actData.condition2) or 1 | |
| 487 | + local coef = 1 | |
| 488 | + if open and actData then | |
| 489 | + coef= tonumber(actData.condition2) | |
| 490 | + end | |
| 489 | 491 | |
| 490 | 492 | local bonusC = role.dailyData:getProperty("bonusC") |
| 491 | 493 | bonusC[btype] = bonusC[btype] or {c = 0, b = 0} |
| ... | ... | @@ -528,9 +530,11 @@ function _M.startBonusBattleRpc(agent, data) |
| 528 | 530 | bonusC[bonusData.type] = bonusC[bonusData.type] or {c = 0, b = 0} |
| 529 | 531 | |
| 530 | 532 | local actData = csvdb["activity_ctrlCsv"][actId] |
| 531 | - if not actData then return 6 end | |
| 532 | 533 | |
| 533 | - local coef = open and tonumber(actData.condition2) or 1 | |
| 534 | + local coef = 1 | |
| 535 | + if open and actData then | |
| 536 | + coef = tonumber(actData.condition2) | |
| 537 | + end | |
| 534 | 538 | |
| 535 | 539 | if globalCsv.bonus_daily_count * coef - bonusC[bonusData.type]["c"] <= 0 then return 7 end |
| 536 | 540 | |
| ... | ... | @@ -552,9 +556,11 @@ function _M.endBonusBattleRpc(agent, data) |
| 552 | 556 | if not role.__bonusBattleCache then return 1 end |
| 553 | 557 | local open, actId = role.activity:isOpen("BonusDouble") |
| 554 | 558 | local actData = csvdb["activity_ctrlCsv"][actId] |
| 555 | - if not actData then return end | |
| 556 | 559 | |
| 557 | - local coef = open and tonumber(actData.condition2) or 1 | |
| 560 | + local coef = 1 | |
| 561 | + if open and actData then | |
| 562 | + coef = tonumber(actData.condition2) | |
| 563 | + end | |
| 558 | 564 | |
| 559 | 565 | if role.__bonusBattleCache.id ~= id or role.__bonusBattleCache.key ~= key then |
| 560 | 566 | SendPacket(actionCodes.Hang_endBonusBattleRpc, MsgPack.pack({errorCode = 1})) | ... | ... |
src/actions/RoleAction.lua
| ... | ... | @@ -679,7 +679,7 @@ function _M.storyBookRewardRpc(agent, data) |
| 679 | 679 | if status == -1 then return end |
| 680 | 680 | |
| 681 | 681 | if not status or status ~= 1 then |
| 682 | - if storyBookData.unlockType == 1 and role:getProperty("hangInfo").carbonId == tonumber(storyBookData.unlockData) then -- 挂机剧情正在挂机也可以领奖 | |
| 682 | + if storyBookData.unlockType == 1 and (role:getProperty("hangInfo").carbonId == tonumber(storyBookData.unlockData) or storyId == 1 or storyId == 2) then -- 挂机剧情正在挂机也可以领奖 | |
| 683 | 683 | else |
| 684 | 684 | return |
| 685 | 685 | end | ... | ... |
src/models/Activity.lua
| ... | ... | @@ -218,10 +218,15 @@ function Activity:checkWeeklyAct(actType, notify, count, pool) |
| 218 | 218 | local info = actInfoMap[actType] |
| 219 | 219 | if not info then return end |
| 220 | 220 | |
| 221 | + local open, actId = self:isOpen(actType) | |
| 222 | + if not open then | |
| 223 | + return | |
| 224 | + end | |
| 225 | + | |
| 221 | 226 | local curData = self:getActData(actType) |
| 222 | 227 | local roundData = self:getProperty("round") |
| 223 | 228 | local curRound = roundData[actType] or 0 |
| 224 | - local ctrlData = csvdb["activity_ctrlCsv"][actType] | |
| 229 | + local ctrlData = csvdb["activity_ctrlCsv"][actId] | |
| 225 | 230 | if not ctrlData then return end |
| 226 | 231 | if curRound >= ctrlData.condition then |
| 227 | 232 | return |
| ... | ... | @@ -350,7 +355,7 @@ activityFunc[Activity.ActivityType.PayBack] = { |
| 350 | 355 | local newVal = oldVal + twd |
| 351 | 356 | local gift, checkPoint = self.owner:getPaybackReward(oldVal, newVal) |
| 352 | 357 | if gift ~= "" then |
| 353 | - local strCp = table.concat(checkPoint ,"/") | |
| 358 | + local strCp = table.concat(checkPoint ,"、") | |
| 354 | 359 | self.owner:sendMail(MailId.PayBackAward, nil, gift, {newVal, strCp}) |
| 355 | 360 | end |
| 356 | 361 | self:updateActData(actType, newVal, not notify) | ... | ... |
src/models/RoleLog.lua
src/models/RoleTask.lua
| ... | ... | @@ -82,8 +82,13 @@ local TaskType = { |
| 82 | 82 | GetFriendP = 803, -- 获得友情点 - count |
| 83 | 83 | |
| 84 | 84 | -- 角色相关 |
| 85 | - RoleLevelUp = 901, -- 角色升级 - curlevel | |
| 86 | - RuneQualityCollect = 902, -- 铭文品质收集进度 | |
| 85 | + RoleLevelUp = 851, -- 角色升级 - curlevel | |
| 86 | + RuneQualityCollect = 852, -- 铭文品质收集进度 | |
| 87 | + | |
| 88 | + -- 其他相关 | |
| 89 | + SignIn = 901, -- 签到 | |
| 90 | + Pay = 902, -- 充值 | |
| 91 | + ShopAll = 903, -- 在任意商店购买 | |
| 87 | 92 | |
| 88 | 93 | --功能未实现 todo |
| 89 | 94 | AdvShop = 1002, -- 冒险商城 |
| ... | ... | @@ -93,9 +98,6 @@ local TaskType = { |
| 93 | 98 | BindPhone = 1008, -- 绑定手机 |
| 94 | 99 | WeChat = 1009, -- 关注微信 |
| 95 | 100 | WeBlog = 1010, -- 关注微博 |
| 96 | - SignIn = 1011, -- 签到 | |
| 97 | - ShopAll = 1013, -- 在任意商店购买 | |
| 98 | - Pay = 1014, -- 充值 | |
| 99 | 101 | } |
| 100 | 102 | |
| 101 | 103 | local function f(field, func) | ... | ... |
-
mentioned in commit 52f8c5f05d0a531232a7dd7887becd2a77986aa1
-
mentioned in commit 52f8c5f05d0a531232a7dd7887becd2a77986aa1
-
mentioned in commit ba6d85edc65900830c7e168102d70671881b5808
-
mentioned in commit ba6d85edc65900830c7e168102d70671881b5808