Commit 7d0fd1f3601598497971ef93345467248598ffc1

Authored by zhangqijia
2 parents 9b20dbfc 9a6d3ed3

Merge branch 'cn/develop' into cn/publish/zhaolu

# Conflicts:
#	src/csvdata
Showing 2 changed files with 11 additions and 6 deletions   Show diff stats
src/actions/RoleAction.lua
... ... @@ -978,16 +978,21 @@ function _M.unLockStoryBookRpc(agent, data)
978 978  
979 979 local storyId = msg.id
980 980 local storyBookData = csvdb["story_bookCsv"][storyId]
981   - if not storyBookData or storyBookData.lockItem == "" then return end -- 不能解锁
  981 + if not storyBookData or storyBookData.lockItem == "" then return 1 end -- 不能解锁
982 982  
983 983 local storyStatus = role:getProperty("storyB")
984   - if storyStatus[storyId] and storyStatus[storyId].s then return end --不需要解锁
  984 +
  985 + --不需要解锁
  986 + if storyStatus[storyId] and storyStatus[storyId].s then
  987 + SendPacket(actionCodes.Role_unLockStoryBookRpc, '')
  988 + return true
  989 + end
985 990  
986 991 if storyBookData.lockItem ~= "free" then
987 992 local cost = storyBookData.lockItem:toNumMap()
988   - if not cost or not next(cost) then return end
989   - if not role:checkItemEnough(cost) then return end -- 消耗品不足
990   - if not role:costItems(cost, {log = {desc = "unlockStory", int1 = storyId}}) then return end
  993 + if not cost or not next(cost) then return 2 end
  994 + if not role:checkItemEnough(cost) then return 3 end -- 消耗品不足
  995 + if not role:costItems(cost, {log = {desc = "unlockStory", int1 = storyId}}) then return 4 end
991 996 end
992 997  
993 998 -- 解锁
... ...
1   -Subproject commit 6e3e08c1ab1287759b803fc7400efefb979a31d4
  1 +Subproject commit 6883d567759b8f50bf1bace2d7e53e658083fa75
... ...