Commit e16794830688d6be5afe0da97c61192d7419f66a
1 parent
1ffc16b9
bug
Showing
2 changed files
with
2 additions
and
8 deletions
Show diff stats
src/adv/AdvBlock.lua
| @@ -83,13 +83,7 @@ function Block:randomEvent() | @@ -83,13 +83,7 @@ function Block:randomEvent() | ||
| 83 | end | 83 | end |
| 84 | --建筑 | 84 | --建筑 |
| 85 | randomFunc[AdvEventType.Build] = function() | 85 | randomFunc[AdvEventType.Build] = function() |
| 86 | - local data = csvdb["event_buildingCsv"][self.event.id] | ||
| 87 | - self.event.effect = data["range"]:randWeight(true) --随出建筑效果 | ||
| 88 | - if self.event.effect[1] == 1 then --获得某道具 | ||
| 89 | - local reward = csvdb["event_dropCsv"][self.event.effect[2]]["range"]:randWeight(true) | ||
| 90 | - self.event.effect[2] = reward[1] | ||
| 91 | - self.event.effect[3] = reward[2] | ||
| 92 | - end | 86 | + |
| 93 | end | 87 | end |
| 94 | 88 | ||
| 95 | randomFunc[AdvEventType.Trap] = function() | 89 | randomFunc[AdvEventType.Trap] = function() |
src/adv/AdvPlayer.lua
| @@ -586,7 +586,7 @@ function Player:addBaseAttr(attr, value, vtype) | @@ -586,7 +586,7 @@ function Player:addBaseAttr(attr, value, vtype) | ||
| 586 | local attrName = attr | 586 | local attrName = attr |
| 587 | if attr == "hp" then | 587 | if attr == "hp" then |
| 588 | attrName = "hpMax" | 588 | attrName = "hpMax" |
| 589 | - elseif attr = "sp" then | 589 | + elseif attr == "sp" then |
| 590 | attrName = "spMax" | 590 | attrName = "spMax" |
| 591 | end | 591 | end |
| 592 | local baseName = "_" .. attrName | 592 | local baseName = "_" .. attrName |