CivClassic / SimpleAdminHacks

Tools and backend for Citadel servers, including advanced inventory monitoring, active new player assistance, and other logging. Built for Paper 1.16.5
BSD 3-Clause "New" or "Revised" License
0 stars 19 forks source link

Fixed issue where onPlayerInteract() would re-enable cancelled event and removed duplicated enderchest check #9

Closed Falvyu closed 4 years ago

Falvyu commented 4 years ago

Calling event.setCancelled(cancel); with cancel == false re-enabling cancelled event. Since this handler was running on a higher priority than Citadel's, this would override setCancelled(true) performed by the latter. As referred in https://github.com/CivClassic/Citadel/pull/20, this would result in non-members being able to access chests, strip wood and tile grass into path.

This also remove the duplicated check for ender chests as it's done by another handler disableEnderChestUse() (https://github.com/CivClassic/SimpleAdminHacks/blob/civ14_2/src/main/java/com/programmerdan/minecraft/simpleadminhacks/hacks/GameFeatures.java#L272)

Maxopoly commented 4 years ago

Thanks