Commit 4ea1b5ac7f1fae9ccb34cf7e58066f8287988c64

Authored by zhouhaihai
1 parent a0013f0b

穿戴零件

Showing 2 changed files with 4 additions and 4 deletions   Show diff stats
src/actions/HeroAction.lua
... ... @@ -564,7 +564,7 @@ function _M.referRunesRpc(agent, data)
564 564 else
565 565 local newRune = role.runeBag[runes[typ]]
566 566 newRune:updateProperty({field = "refer",value = hero:getProperty("id")})
567   - curRune = curRune:delk(typ)
  567 + curRune = curRune:setv(typ, runes[typ])
568 568 end
569 569  
570 570 if cur ~= 0 then
... ... @@ -575,8 +575,8 @@ function _M.referRunesRpc(agent, data)
575 575 end
576 576 end
577 577 end
578   - hero:updateProperty({field = "rune", value = curRune})
579 578 end
  579 + hero:updateProperty({field = "rune", value = curRune})
580 580 SendPacket(actionCodes.Hero_referRunesRpc, "")
581 581 return true
582 582 end
... ...
src/models/Hero.lua
... ... @@ -15,8 +15,8 @@ Hero.schema = {
15 15 loveExp = {"number", 0}, --好感度经验
16 16 loveL = {"number", 0}, --好感度等级
17 17 skin = {"number", 0}, --皮肤 0 、 1、 2、 3
18   - equip = {"string","1=0 2=0 3=0 4=0"}, --装备 type=level
19   - rune = {"string","1=0 2=0 3=0 4=0 5=0 6=0"}, --零件 type=id
  18 + equip = {"string",""}, --装备 type=level
  19 + rune = {"string",""}, --零件 type=id
20 20 }
21 21  
22 22 function Hero:ctor( properties )
... ...