| Conditions | 3 |
| Paths | 4 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 3 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 34 | protected function getDamage(): int |
||
| 35 | { |
||
| 36 | 1 | $damage = 0; |
|
| 37 | 1 | if (str_ends_with($this->skill->baseDamage, "%")) { |
|
| 38 | 1 | $damage += (int) $this->skill->baseDamage; |
|
| 39 | } |
||
| 40 | 1 | if (str_ends_with($this->skill->damageGrowth, "%")) { |
|
| 41 | 1 | $damage += (int) $this->skill->damageGrowth * ($this->level - 1); |
|
| 42 | } |
||
| 43 | 1 | return $damage; |
|
| 44 | } |
||
| 54 |