convert PLAYER_ACTION from byte to unsigned byte, replace -1 (1.7 client not looking at block)#629
convert PLAYER_ACTION from byte to unsigned byte, replace -1 (1.7 client not looking at block)#629Term4 wants to merge 2 commits intoViaVersion:masterfrom
Conversation
florianreuth
left a comment
There was a problem hiding this comment.
Can you show the bug / a way on how I can reproduce it? The type didn't change in Minecraft, so it has to be something else.
Sorry didn't see this sooner. The only time I've seen it is on minestom using velocity + viarewind on a proxy & bungee auth. When a 1.7 client joins & blocks their sword while digging, they get kicked (helps if they're walking forward as well). |
|
Could you make a video + show the kick message/logs? |
Sure, https://youtu.be/sdzyI0DHEww If you need more logs I can provide em, didn't feel like removing my IP. |
|
Juse use https://mclo.gs/, it will remove them |
PS C:\Users********\Desktop\Development\Velocity> java -jar velocity.jar [02:58:44 INFO]: Booting up Velocity 3.5.0-SNAPSHOT (git-7e01491e-b574)...
|
|
Using SniffCraft and Pakkit, here's what I captured in '7, '8 and '21 1.21.11 (SniffCraft) (does not get you kicked)Sword blocking/unblocking (sword had block_attacks component)Initiating a sword block sends an ID:64 Use Item hand: 0
sequence: 7
x_rot: ...
x_rot: ...and an ID:4 Block Changed Ack sequence: 7unblocking does an ID:40 Player Action action: 5
direction: 0
pos: x/y/z all 0
sequence: 0and a Set Entity Data ID: 97 entity_id: 4
packed_items: [ 8, 0, 0, 255]1.8.9 (pakkit) (does not get you kicked)Sword blocking/unblockingStarting to block a sword (holding right click) sends a 0x08 block_place location: { x: -1, y: -1, z: -1 },
direction: -1,
heldItem:
{ blockId: 276, itemCount: 1, itemDamage: 0 },
cursorX: 0, cursorY: 0, cursorZ: 0when releasing it sends 0x07 block_dig status: 5,
location: { x: 0, y: 0, z: 0 },
face: 0Bow pull/releasepulling: location: { x: -1, y: -1, z: -1 },
direction: -1,
heldItem: { blockId: 261, itemCount: 1, itemDamage: 0 },
cursorX: 0, cursorY: 0, cursorZ: 0release: status: 5,
location: { x: 0, y: 0, z: 0 },
face: 01.7.10 (pakkit) (gets you kicked)Sword blocking/unblockingStarting to block a sword (holding right click) sends a 0x08 block_place location: { x: -1, y: 255, z: -1 },
direction: -1,
heldItem: { blockId: 276, itemCount: 1, itemDamage: 0 },
cursorX: 0, cursorY: 0, cursorZ: 0then, when ublocking, a 0x07 block_dig status: 5,
location: { x: 0, y: 0, z: 0 },
face: -1Bow pull/releasepulling back a bow sends a 0x08 block_place: location: { x: -1, y: 255, z: -1 },
direction: -1,
heldItem: { blockId: 261, itemCount: 1, itemDamage: 0 },
cursorX: 0, cursorY: 0, cursorZ:0and also a 0x1c entity_metadata: entityId:6,
metadata: [0:{ type: 0, key: 0, value: 16 }]then releasing the bow causes the same 0x07 block_dig status:5,
location: { x: 0, y: 0, z: 0 },
face: -1Note: Kicks when bow releasing/sword unblocking can be avoided by switching slots (0x09 held_item_slot) instead of releasing right-click With hope these observations may help |

Prevents bug where 1.7 clients get kicked from non spigot based servers when cancel digging packet is sent.