mojira.dev

LoliColleen

Assigned

No issues.

Reported

MC-279758 Blocking component causes strange knockback Confirmed MC-278104 Attacking or dropping quickly after switching items did not match expectations Duplicate MC-278103 Jumping can reset player's velocity Duplicate MC-278088 Switching items quickly causes the server to misjudge Duplicate MC-276926 Fast switching the Mace can deal more damage than expected Duplicate MC-269947 Clicking spam with Mace causes very high damage Fixed MC-267775 Shield doesn't knock back attacker Duplicate

Comments

I tested with this command:

/give @s minecraft:diamond_sword[minecraft:blocks_attacks={block_delay_seconds:0.0,disable_cooldown_scale:0.0,damage_reductions:[{base:0.0,factor:0.5}],block_sound:"minecraft:entity.zombie.attack_iron_door"}]

It works fine. Are you mistaken?

I tested and checked out the src, finally found out the solution.

The attributes of living entites only refresh when entities' mob effects change or by tick.

So we can refresh players' attributes when they change their selected item.

This ticket can be closed because MC-28289 can describe how the problem can be caused again

Although the ticket was marked as a "community consensus", I still need to explain more about the impact of the bug on the game

Why should this bug be fixed?:

  1.  [In Survival] With the addition of wind charge, players can now jump higher by using the wind charge. And they can jump much more higher by jumping when they use wind charge. But this bug is unintuitive and will confuse players. They will find that sometimes wind charge doesn't boost them at all.

  2.  [In Combat] This bug has become a pvp mechanic called "Jump Reset" which allows players take less knock back than they should. Similar to the wind charge , this bug also makes knock back unintuitive. It also allows cheaters to take no knock back, and they can't be detected by anti cheat.

  3. [Others] This bug disables some custom features that depend on speed changes. For example, if you want to make a jump pad which allows players to jump boost when they jump on it, this bug will reset the velocity change from the jump pad.

In addition, the melee attack charging does not reset in time

Can we close the old ticket and reopen this one? Because the old one didn't mention that the impact of the bug on the behaviours more than combat. The community consensus of that ticket is also just about combat.

I tested again and found MC-28289 can describe this issue.

I originally thought that the bug on the server that caused the item error was also due to this. But vanilla didn't seem to have the problem with that server

@BugTracker I think that ticket doesn't fully describe the bug. If there isn't any ticket fully describes, I will modify this ticket and add some details.

Can confirm in 1.21.2 pre 2

By the way, as what I mentioned in that ticket, this bug may be related to an old bug which hasn't been fixed for several years. I think the old bug has been reported, but I can't find it in Mojira, please help find it.

The new way to trigger this bug seems different from the previous methods. Please check this ticket: MC-276926

I've annotated the code block for understanding, so check it out