Skip to content
This repository was archived by the owner on Dec 16, 2024. It is now read-only.

Commit f08bd29

Browse files
authored
Merge pull request #1 from codeHusky/patch-1
Replace blind slot check w/ clicktype check
2 parents 770a71c + b913079 commit f08bd29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/lol/hyper/lecterncrashfix/LecternCrashFix.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public void onPacketReceiving(PacketEvent event) {
3030
Player player = event.getPlayer();
3131
InventoryView inv = player.getOpenInventory();
3232
if (inv.getType() == InventoryType.LECTERN) {
33-
if (packet.getSlot() == 1) {
33+
if (packet.getShift() == WrapperPlayClientWindowClick.InventoryClickType.QUICK_MOVE) {
3434
event.setCancelled(true);
3535
logger.warning(player.getName() + " tried to illegally click a slot in a lectern!");
3636
}

0 commit comments

Comments
 (0)