BukkitOldCombatMechanics icon indicating copy to clipboard operation
BukkitOldCombatMechanics copied to clipboard

Overpowered Enchantment Conflicts

Open Jeklund6 opened this issue 2 years ago • 6 comments

Edit: Very similar problems to issues #499, #560, and #589 hopefully I provided helpful information.

Server Version: Paper 1.12.2

I'm trying to create an OP Factions server with 1.8 style combat and OP enchants. Ex. (protection.0-100) (sharpness.0-50).

While using this plugin once you have x>=protection.5 you take negative damage from anything above +4 Attack Damage.

Now this is when default is set "old_armor_strength = true"

Screenshots below if they can possibly provide some explanation that I don't understand. Images 1, 1.a, 2, 2.a have "old_armor_strength = true" See config.yml: https://mcpaste.io/599ab873d279fbe8

IMAGE 1: Attacker using sharpness.50 sword. image IMAGE 1.a: Defender wearing protection.5 image

IMAGE 2: Attacker using wooden sword image IMAGE 2.a: Defender wearing protection.5 image

Below is a somewhat separate issue from above

I dont know if this is caused by the plugin or this is Minecraft but I thought I'd include it Troubleshooting the issues I tried setting it to false. Everything worked perfectly when "old_armor_strength = false". Damage worked perfectly, but a different problem occurred; the difference in protection. Any x>=protection.5 isn't more effective Ex. if I enchant something as protection.100 it's no different than protection.5 (same with durability) Images 3, 3.a, 4, 4.a have "old_armor_strength = false" See config.yml: https://mcpaste.io/ae4b7d15c9b2861e

IMAGE 3: Attacker using sharpness.50 sword image IMAGE 3.a: Defender wearing protection.5 (Armor Strength not showing here because I set it to false I'm assuming) image

IMAGE 4: Attacker using sharpness.50 sword image IMAGE 4.a: Defender wearing protection.100 (Armor Strength not showing here because I set it to false I'm assuming) image

As you can see, there was no difference in damage taken between protection.5 and protection.100

Jeklund6 avatar Jun 23 '22 04:06 Jeklund6

Thank you for actually providing some data, I will now have to do a lot of investigating and testing to figure out where the problem lies.

kernitus avatar Jul 02 '22 12:07 kernitus

I've done some extra research after posting this which might help you or save time.

The problem is Minecraft's EPF cap or (reaching 100% protection) on armor/protection enchantments. EPF cap is reached when wearing protection 5 diamond armor.

When (EPF cap is reached) and (old_armor_strength = true) then, you CAN'T take damage because you're at 100% protection.

When (EPF cap is reached) and (old_armor_strength = false) then, you CAN take damage, but the damage you take doesn't decrease as protection level increases.

To fix: I imagine it has to do with overriding Minecraft's default EPF cap/values, but that sounds like it would bring a host of other coding issues like making an entirely new EPF curve or dataset.

But, that's why I just look for plugins and not create them, hope this helps lol.

Jeklund6 avatar Jul 03 '22 01:07 Jeklund6

Thanks for providing such detailed information, I will be looking at this shortly. Would you be available to perform some testing if I managed to fix the issue?

kernitus avatar Jul 22 '22 11:07 kernitus

Yeah I could do that.

Jeklund6 avatar Jul 22 '22 20:07 Jeklund6

Any update on this yet?

Jeklund6 avatar Aug 29 '22 12:08 Jeklund6

I am currently rewriting most of the damage calculation system. It requires a lot of testing to make sure it is actually accurate.

kernitus avatar Sep 16 '22 17:09 kernitus

@Jeklund6 please try the new test builds, where I have rewritten most of the calculations that deal with damage.

kernitus avatar Dec 23 '22 12:12 kernitus

Closing due to rewrite of all damage calculation code. Please open a new issue with debug logs from the latest version if you think the issue is still present.

kernitus avatar Feb 01 '23 13:02 kernitus