BentoBoxWorld / Boxed

A game mode where you are boxed into a tiny space that only expands by completing advancements
Eclipse Public License 2.0
15 stars 4 forks source link

Disable Enderpearl Moving Box #4

Closed Fredthedoggy closed 1 year ago

Fredthedoggy commented 3 years ago

Description

Is your feature request related to a problem?

I've found a few issues with the ender pearl moving player's boxes, such as the fact that players will throw it first thing, then not have any wood or saplings to start from.

Describe the solution you'd like us to implement.

Make a setting for the ender pearl feature in /boxadmin settings

Describe alternatives you've considered.

None

Additional context

N/A

tastybento commented 3 years ago

You could remove it from the blueprint.

tastybento commented 3 years ago

I could also make the current setting cycle so it removes owner too.

Fredthedoggy commented 3 years ago

I have removed it from the blueprint, but I would like to disable it as a feature aswell, as it can have irreversible consequences that people might not expect

Fredthedoggy commented 3 years ago

I could also make the current setting cycle so it removes owner too.

Ah, that would be great.

tastybento commented 3 years ago

Note that unless you plan to give out a lot of advancements, they may never be able to get out of the plains biome.

Fredthedoggy commented 3 years ago

Ok, in that case, it would be nice if the following things could be implemented: A Confirm button when you teleport your box, to say "Did you really mean to do that", A Setting to disable it (if someone uses ender pearls a lot and finds it annoying) and something that moves the island spawn point / visit point automatically if the box is relocated to somewhere that does not overlap with the current locations

BONNe commented 3 years ago

https://github.com/BentoBoxWorld/Boxed/blob/50c195287bd81a79b30ccdfcdcb406df67d4d35e/src/main/java/world/bentobox/boxed/Boxed.java#L118-L130

@tastybento I do not think this is how you do it.

The check is done only onEnable, so how does it should work for changing the value?

I think you need a custom listener for checking ALLOW_MOVE_BOX value changing, and add/remove MOVE_BOX vaule.

Also, I am not sure if Island#isAllowed(FLAG, OWNER) will not return a false positive? How will it act on the flag that is unregistered? Will it return flags default value -> true, or false because flag does not exist?

tastybento commented 1 year ago

Fixed and done