IntellectualSites / PlotSquared

PlotSquared - Reinventing the plotworld
GNU General Public License v3.0
546 stars 748 forks source link

Blocklist flags (use, place, break) are broken #2573

Closed mindw0rm closed 4 years ago

mindw0rm commented 4 years ago

NOTICE:

! PlotSquared for Minecraft Java Edition versions between 1.7 through to 1.12.2 are considered
! legacy, and will receive limited to no support. Please consider upgrading to 1.13+ for
! future support.  Plugins exist for 1.13+ which bring back behaviors found in 1.8.8
! All versions of PlotSquared for Sponge and Nukkit(X) will recieve limited to no support
! due to lack of developer interest and time. Additionally, NukkitX has not had feature
! updates since the Better Together, which prevents some PlotSquared features from ever
! functioning.  Contributions are always welcome however!

Feature requests & Suggestions are to be submitted at the PlotSquared Suggestions tracker

Code contributions are to be done through PRs, tagging the specific issue ticket(s) if applicable.

DISCORD INVITE LINK and please, for the love of the little sanity we have left, use the correct channels!

BUG REPORT TEMPLATE:

Required Information section:

ALL FIELDS IN THIS SECTION ARE REQUIRED, and must contain appropriate information

Server config info (Debug/file paste links):

https://athion.net/ISPaster/paste/view/cbe3b54357654ea7b931a6b1ed9a6a69

Server type:

select one

Minecraft Version:

select one

Server build info:

[17:32:42] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-56f8471-56118c6 (MC: 1.14.4) (Implementing API version 1.14.4-R0.1-SNAPSHOT)
[17:32:42] [Server thread/INFO]: Checking version, please wait...
[17:32:43] [Thread-9/INFO]: You are running the latest version

WorldEdit/FAWE versions:

Description of the problem:

The blocklist flags, i.e. use, break and place, stopped working with the newest version (4.390). This means that you cannot place/break/use blocks which are in those flags.

I tracked the issue down to this commit, where a Supplier<BlockState> is provided to EventUtil::checkPlayerBlockEvent, but the flags values are of type Set<BlockType>. Obviously the call to contains must fail.

How to replicate:

Additional Information:

I already made a bugfix, you'll get a pull request soon.

Other plugins being used on the server:

none (except WorldEdit) - this is only a test server

Relevant console output, log lines, and/or screenshots:

n/a

Additional relevant comments/remarks:

I kept the preamble of the bug template, since it says that I should not remove it, but do you really want it? Imho everything above "Server config info" could be removed and the bug would be easier to read ...

AFFIRMATION OF COMPLETION:

mindw0rm commented 4 years ago

PR needs some time, I just realized that I forgot some flag usages which were not relevant to my testing :/

NotMyFault commented 4 years ago

Fixed in https://github.com/IntellectualSites/PlotSquared/commit/765a021ecdbf86ad3996546ec9d5a67a04d8550d, sorry but Jesse didn't see this one.