礼物添加空判断
parent
25dc5ca5a9
commit
8c0dd3a9b0
|
@ -194,7 +194,7 @@ function this.GetHeroPotencyLvById(did)
|
|||
if this.playerGifts and #this.playerGifts>0 then
|
||||
for i=1,#this.playerGifts do
|
||||
local id=this.playerGifts[i]
|
||||
if equipConfig[id] and equipConfig[id].PotentialNew and #equipConfig[id].PotentialNew>0 then
|
||||
if equipConfig[id] and equipConfig[id].PotentialNew and #equipConfig[id].PotentialNew>0 and type(equipConfig[id].PotentialNew[1])~="userdata" then
|
||||
lv=lv+equipConfig[id].PotentialNew[2]
|
||||
end
|
||||
end
|
||||
|
@ -203,7 +203,7 @@ function this.GetHeroPotencyLvById(did)
|
|||
local list=this.allHeroGifts[did]
|
||||
for i=1,#list do
|
||||
local id=list[i]
|
||||
if equipConfig[id] and equipConfig[id].PotentialNew and #equipConfig[id].PotentialNew>0 then
|
||||
if equipConfig[id] and equipConfig[id].PotentialNew and #equipConfig[id].PotentialNew>0 and type(equipConfig[id].PotentialNew[1])~="userdata" then
|
||||
lv=lv+equipConfig[id].PotentialNew[2]
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue