Commit 109740971d8ea1c52e735655706947e6f3aea993

Authored by gaofengduan
1 parent a1d09d22

fix diner

Showing 2 changed files with 8 additions and 5 deletions   Show diff stats
src/actions/DinerAction.lua
@@ -170,11 +170,14 @@ function _M.expediteSellRpc( agent, data ) @@ -170,11 +170,14 @@ function _M.expediteSellRpc( agent, data )
170 if count >= max then 170 if count >= max then
171 return 1 171 return 1
172 end 172 end
173 - local cost = {[ItemId.Diamond] = globalCsv.diner_sell_quick_cost[count+1]}  
174 - if not role:checkItemEnough(cost) then  
175 - return 2 173 + local diamond = globalCsv.diner_sell_quick_cost[count]
  174 + if diamond > 0 then
  175 + local cost = {[ItemId.Diamond] = diamond}
  176 + if not role:checkItemEnough(cost) then
  177 + return 2
  178 + end
  179 + role:costItems(cost)
176 end 180 end
177 - role:costItems(cost)  
178 181
179 local dirty = false 182 local dirty = false
180 local reward,popular = "",0 183 local reward,popular = "",0
1 -Subproject commit 13eb69bd67154cb457bd9885e27546754b169b92 1 +Subproject commit 3605bdd04bc3ef79ff0d25e18a3b7afe9edabdc0