Bug Closed · Resolved

Setting `Damage` to 0 stills deals damage

#2734 opened by Unknown 4 years ago

Unknownreported this bug

Summary

I have a mob set to deal 0 damage but instead of it dealing 0 damage it just deals its base damage.

Steps to reproduce

Simply define a mob like this:

test_zombie:
  Type: ZOMBIE
  Display: '&2Test zombie'
  Health: 10
  Damage: 0
  Skills:
  - message{m="damage = <caster.damage> target health = <target.thp>"} @trigger ~onAttack

Spawn the mob, and let the mob attack you.

Then you can see the mob still deals damage.

Current behavior

If setting the Damage option to 0, the mob still deals damage.

Intended correct behavior

The mob should not be able to deal damage if setting Damage to 0

Server log file

https://pastebin.com/fzNCstgQ

Debug log snippet

There is no erros on the console. The reproduce steps should be enough to investigate this issue.

Proposed fixes

I have no idea sorry.

Unknowncommented

That is why i always cancel the even it never was 0 from what i remember .

Sign in to join the discussion.