Commit 052ae144b08e311965ef85b170203f43e76e05ff
Merge branch 'tr/bugfix' of 120.26.43.151:wasteland/server into tr/bugfix
Showing
5 changed files
with
7 additions
and
5 deletions
Show diff stats
src/actions/HeroAction.lua
@@ -926,6 +926,7 @@ function _M.drawHeroRpc(agent, data) | @@ -926,6 +926,7 @@ function _M.drawHeroRpc(agent, data) | ||
926 | local itemId = math.randWeight(resultPool, 1) | 926 | local itemId = math.randWeight(resultPool, 1) |
927 | if guideHero then | 927 | if guideHero then |
928 | itemId = guideHero | 928 | itemId = guideHero |
929 | + guideHero = nil | ||
929 | end | 930 | end |
930 | 931 | ||
931 | local itemData = csvdb["itemCsv"][itemId] | 932 | local itemData = csvdb["itemCsv"][itemId] |
src/models/Activity.lua
@@ -699,7 +699,7 @@ function Activity:recycleActItem(actId) | @@ -699,7 +699,7 @@ function Activity:recycleActItem(actId) | ||
699 | local itemCount = role:getItemCount(fromId) | 699 | local itemCount = role:getItemCount(fromId) |
700 | if itemCount > 0 then | 700 | if itemCount > 0 then |
701 | costs[fromId] = (costs[fromId] or 0) + itemCount | 701 | costs[fromId] = (costs[fromId] or 0) + itemCount |
702 | - gift[toId] = toNum * itemCount | 702 | + gift[toId] = (gift[toId] or 0) + toNum * itemCount |
703 | end | 703 | end |
704 | end | 704 | end |
705 | if next(costs) then | 705 | if next(costs) then |
src/models/RoleLog.lua
@@ -122,6 +122,7 @@ local ItemReason = { | @@ -122,6 +122,7 @@ local ItemReason = { | ||
122 | 122 | ||
123 | -- pvp | 123 | -- pvp |
124 | pvpCHead = 1301, -- pvp 跨服竞技场头像 | 124 | pvpCHead = 1301, -- pvp 跨服竞技场头像 |
125 | + crossPvpBet = 1302, -- 竞猜 | ||
125 | 126 | ||
126 | --adv | 127 | --adv |
127 | chooseEvent = 1351, -- 冒险选择 | 128 | chooseEvent = 1351, -- 冒险选择 |
src/models/RolePvp.lua
@@ -521,7 +521,7 @@ function Role:changeCrossServerPvpSelfInfo(cType) | @@ -521,7 +521,7 @@ function Role:changeCrossServerPvpSelfInfo(cType) | ||
521 | change[cType] = self:getProperty(cType) | 521 | change[cType] = self:getProperty(cType) |
522 | elseif cType == "format" then | 522 | elseif cType == "format" then |
523 | -- 是否过了时间 | 523 | -- 是否过了时间 |
524 | - local crossTime = skynet.timex() - self:getTimeResetStartTime(TimeReset.PvpCross) | 524 | + local crossTime = skynet.timex() - self:getTimeResetStartTime(TimeReset.PvpCross) + RESET_TIME * 3600 |
525 | local aday = 3600 * 24 | 525 | local aday = 3600 * 24 |
526 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 | 526 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 |
527 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 | 527 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 |
@@ -615,7 +615,7 @@ end | @@ -615,7 +615,7 @@ end | ||
615 | 615 | ||
616 | function Role:setCrossServerPvpBet(idx) | 616 | function Role:setCrossServerPvpBet(idx) |
617 | if not self:isTimeResetOpen(TimeReset.PvpCross) then return false , 1 end | 617 | if not self:isTimeResetOpen(TimeReset.PvpCross) then return false , 1 end |
618 | - local crossTime = skynet.timex() - self:getTimeResetStartTime(TimeReset.PvpCross) | 618 | + local crossTime = skynet.timex() - self:getTimeResetStartTime(TimeReset.PvpCross) + RESET_TIME * 3600 |
619 | local aday = 3600 * 24 | 619 | local aday = 3600 * 24 |
620 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 | 620 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 |
621 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 | 621 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 |
src/services/pvpd.lua
@@ -84,7 +84,7 @@ function CMD.updateRoleInfo(change) | @@ -84,7 +84,7 @@ function CMD.updateRoleInfo(change) | ||
84 | CMD.refreshRoleInfo(change) | 84 | CMD.refreshRoleInfo(change) |
85 | local pvpd = cluster.query("center", "pvpd") | 85 | local pvpd = cluster.query("center", "pvpd") |
86 | if pvpd then | 86 | if pvpd then |
87 | - pcall(cluster.call, "center", pvpd, "updateRoleInfo", change) | 87 | + pcall(cluster.send, "center", pvpd, "updateRoleInfo", change) |
88 | end | 88 | end |
89 | end | 89 | end |
90 | 90 | ||
@@ -92,7 +92,7 @@ local function getDayAndTime() | @@ -92,7 +92,7 @@ local function getDayAndTime() | ||
92 | local startTime = getStartTime() | 92 | local startTime = getStartTime() |
93 | local now = skynet.timex() | 93 | local now = skynet.timex() |
94 | 94 | ||
95 | - local crossTime = now - startTime | 95 | + local crossTime = now - startTime + RESET_TIME * 3600 |
96 | local aday = 3600 * 24 | 96 | local aday = 3600 * 24 |
97 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 | 97 | local day = math.ceil(crossTime / aday) -- 当前是第几个比赛日 |
98 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 | 98 | local ctime = crossTime % aday -- 当前在本天 经过多少时间 |