alex9849 / advanced-region-market

A Bukkit/Spigot plugin for renting/selling WorldGuard regions
https://www.spigotmc.org/resources/advancedregionmarket.58732/
69 stars 44 forks source link

Add ability for owners to clear regions #120

Closed tylerking closed 2 years ago

tylerking commented 2 years ago

Would be nice to allow owners/members to clear a region of all blocks via command & GUI. I checked to see if this feature already exists and didn't see anything. Any chance you would add this? Thanks in advance.

Command: /arm clear [REGION] Permission: arm.member.clear

Roos-Skywalker commented 2 years ago

Sounds like /arm reset [REGION] This command (which doesn't run from console for some reason) sets the chosen region back to its previous state and reapplies the original schematic file if there is one.

tylerking commented 2 years ago

No that command does exactly what it's meant todo which is reset the region to default. I'm asking for a command that clears the region of all blocks. It's not the same.

Thanks for the suggestion either way.

alex9849 commented 2 years ago

You can use /arm restore for that. There is also a member permission and a cooldown integrated so this feature won't get abused.

tylerking commented 2 years ago

Nope...that also resets the region to default which is not what I'm asking for. I would like to be able to clear the region completely...no blocks on it from placement or from a schematic. Its not the same as reset or restore which I tried both prior to posting this.

alex9849 commented 2 years ago

OK? So you just want to remove everything including the bedrock?

tylerking commented 2 years ago

Just clear everything that's in the region no matter what the block is. Something as simple as selecting the region and setting all blocks to air would work.

For context, I have player shop regions that come with optional pre-built shops on the regions. The regions aren't hotels so they can use the pre-built or tear it down and build their own custom shop. Would be a nice QoL update to allow them to just clear the plot if they don't want to use the pre-built vs always having to tear it down. Hope this helps.

Roos-Skywalker commented 2 years ago

In that case just use Luckperms with Extra Contexts so you can give worldedit permission on per region basis. When leaving the region the permission is removed.

tylerking commented 2 years ago

I know that’s possible but Im not going to do that. It’s not easy for the players to remember random commands like that and it’s unprofessional. What I’m asking is not out of scope for this plugin and would be a nice addition. There is also an available slot in the GUI. Please add a simple region clear option.

On August 20, 2022 at 6:14:46 AM, Roos-Skywalker @.***) wrote:

In that case just use Luckperms with Extra Contexts so you can give worldedit permission on per region basis. When leaving the region the permission is removed.

— Reply to this email directly, view it on GitHub https://github.com/alex9849/advanced-region-market/issues/120#issuecomment-1221312933, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAN5M7IXRJ45ICBZPJ7KITTV2DK4NANCNFSM567MBGSA . You are receiving this because you authored the thread.Message ID: @.***>

Roos-Skywalker commented 2 years ago

You can add an alias to any command without additional plugins simply by registering an alias in the commands.yml file of the server. You can copy paste this and be done. However, the player would still need to select the region with /rg select

aliases:
  icanhasbukkit:
  - version $1-
  clearshop:
  - /set air $1