-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Description
Bug found in CalamityCraft modpack, but later was reproduced with only Relic mod (v0.8.0.11) and it's dependencies (Forge v47.4.10).
Holy Locket 1st ability can heal user with 'Life Essence' when entity nearby heals. And sometimes it' didn't heal... it damages user.
I was curios so i checked the code and found this line:
relics/src/main/java/it/hurts/sskirillss/relics/entities/LifeEssenceEntity.java
Lines 61 to 67 in a8ae6b9
| if (this.distanceTo(target) <= 1) { | |
| Level level = target.getCommandSenderWorld(); | |
| target.hurt(level.damageSources().generic(), heal); | |
| this.remove(RemovalReason.KILLED); | |
| } |
...HURT? In my life essence? WTH?!
The healing property for essence is ~12 lines bellow:
relics/src/main/java/it/hurts/sskirillss/relics/entities/LifeEssenceEntity.java
Lines 79 to 86 in a8ae6b9
| protected void onHitEntity(EntityHitResult result) { | |
| if (target == null || !(result.getEntity() instanceof LivingEntity entity) || entity.getUUID() != target.getUUID()) | |
| return; | |
| entity.heal(getHeal() + this.getHeal()); | |
| this.discard(); | |
| } |
I'm not a programmer wizard myself... but this shouldn't be too difficult to fix.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels