Giter Site home page Giter Site logo

spnda / blockprot Goto Github PK

View Code? Open in Web Editor NEW
30.0 2.0 11.0 2.08 MB

Bukkit plugin to protect your chests, furnaces and more with a modern GUI approach.

Home Page: https://www.spigotmc.org/resources/blockprot.87829/

License: GNU General Public License v3.0

Java 100.00%
spigot-plugin minecraft-plugin minecraft minecraft-server-plugin paper-plugin papermc-plugin bukkit-plugin bukkit-plugins paper spigot

blockprot's Introduction

BlockProt

CurseForge Downloads Modrinth Downloads Spigot Downloads Spigot Rating Hangar Downloads BlockProt CI gitlocalized JitPack

Servers Players Discord

BlockProt is a lightweight Bukkit and Spigot plugin that gives players the ability to protect chests, furnaces and many more blocks. The plugin features a modern GUI approach instead of commands, so that any player can easily understand how to use all of its features.

image1

Installing

To use this plugin, you can simply download it from CurseForge, Modrinth or SpigotMC and place it in your plugins directory. You do not have to install anything else and any recent version will work with 1.14, 1.15, 1.16, 1.17 and 1.18. It runs on any Spigot and any fork thereof and does not run on CraftBukkit.

To get the latest updates the quickest, you can "watch" or "star" this repository or frequently check the Release tab. Alternatively, it is also possible to watch the resource on Spigot, which will also notify you as soon as new builds get released.


If you want to build the plugin from source yourself, you can simply do so by installing JDK 16 or newer, cloning this repository and running ./gradlew build in the main directory.

Translating

If you know a language that isn't supported by this plugin (yet) or found some translation error we'd love if you could translate for us!

You can do so easily by going to gitlocalize or sending me the translations on Discord.

Contact/Support

If you find bugs or any issues related to this plugin, please report them over on the GitHub issue tracker. If you require more support or want to ask questions, please use the Discord server for chatting.

Developing Addons

This plugin offers a basic API which other developers can use to add new features and provide support and compatibility with other plugins. BlockProt can be accessed via the jitpack.io repository.

Your build.gradle file may look like this:

repositories {
    maven 'https://jitpack.io'
}

dependencies {
    // This version might be slightly outdated. See https://github.com/spnda/BlockProt/releases.
    implementation 'com.github.spnda.BlockProt:blockprot-spigot:0.4.11'
}

From here on, you're good to go. We provide an easy to use BlockProtAPI class and other utility methods to easily add new functionality, with low amount of boilerplate. In the following examples you can see how to use that class.

// A BlockNBTHandler is a NBT Handler designed to lock blocks, add friends and edit other settings.
// This handler exists on a per-block basis.
BlockNBTHandler handler = BlockProtAPI.getInstance().getBlockHandler(block);

// The PlayerSettingsHandler is made to handle settings that are commonly accessible
// through the "/blockprot settings" command.
PlayerSettingsHandler playerHandler = BlockProtAPI.getInstance().getPlayerSettings(player);

We also offer a variety of events that you can listen to. For an up-to-date and more detailed list, see here. You can use these to block players from accessing some blocks based on custom conditions and much more. For even more fine grain control over events, you can write a PluginIntegration. A PluginIntegration is designed to be specific to a single other plugin and is only activated when the referenced plugin is actually loaded through Bukkit. It also provides utilities to quickly load a single config file and register listeners. BlockProt natively includes a plugin integration for Towny, which you can find here. You can freely use this as an example.

bStats

bStats Graph

License

BlockProt is licensed under GPLv3 license, view LICENSE to learn more.

blockprot's People

Contributors

c4br3r4 avatar daretmavi avatar dependabot[bot] avatar endlesslegends avatar fakeee14 avatar gitlocalize-app[bot] avatar hoehoetvhss avatar matiasfacello avatar modcrafts avatar plkaratuspl avatar polkanizki avatar ravel10 avatar razenxc avatar spnda avatar thediscordian avatar trollstercooleg avatar vincentx0905 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

blockprot's Issues

[Feature] Bulk edit a player's blocks

Your question

In our server, sometimes there are players quit. But then if they want to give their things to another player, then they have to unlock all the chest that they had lock before. If they have so many chests then it would be hard to unlock all of them. Is there a command that can unlock all the blocks that a player had lock before ?

[Bug]: Friendslist not automatic in .... doors ,

Version of BlockProt

paper-1.17.1-165 and blockprot 0.4.10

Description of the bug

/blockprot settings friends not working , set not automatic in chest and etc.

Steps to reproduce

  1. use /blockpro settings
  2. add friends
  3. place block
  4. friend is not in block friendslist

Additional context

No response

[Bug]: Wall signs

Version of BlockProt

0.4.1

Description of the bug

When you add signs and wall signs to config, you can lock normal signs in blockprot GUI, but wall signs lock option are unavailable.
2021-07-05_21 04 42
Screenshot_3

Steps to reproduce

add wall sign to block lock section of config
place wall sign and access to blockprot GUI

Additional context

No response

[Bug]: Hoppers cannot retrieve items from unlocked containers.

Version of BlockProt

0.4.13 and 1.0.0 Beta

Description of the bug

Hoppers cannot retrieve items from unlocked containers, i.e. chests, furnaces, smokers.

Hoppers can only retrieve items from containers if the container is locked and has hopper protection disabled. Locking a container, disabling hopper protection, and then unlocking it does not fix the issue.

Steps to reproduce

  1. Place a hopper between two chests vertically (chest feeds into hopper, hopper feeds into chest).
  2. Ensure all blocks are unlocked.
  3. Place items in topmost chest.
  4. Observe that the hopper does not retrieve items from topmost chest.
  5. Lock topmost chest and disable hopper protection.
  6. Observe that the hopper can now retrieve items from the topmost chest and deposit them in the lower chest.

Additional context

No response

[Bug]: Could not pass event InventoryMoveItemEvent to BlockProt v1.0.4

Version of BlockProt

BlockProt v1.0.4 / paper-api-1.18.1

Description of the bug

[12:47:59 ERROR]: Could not pass event InventoryMoveItemEvent to BlockProt v1.0.4
java.lang.RuntimeException: Given block DROPPER is not a lockable block/tile entity
at de.sean.blockprot.bukkit.nbt.BlockNBTHandler.(BlockNBTHandler.java:82) ~[blockprot-spigot-1.0.4-all.jar:?]
at de.sean.blockprot.bukkit.listeners.HopperEventListener.onItemMove(HopperEventListener.java:54) ~[blockprot-spigot-1.0.4-all.jar:?]
at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor557.execute(Unknown Source) ~[?:?]
at org.bukkit.plugin.EventExecutor.lambda$create$1(EventExecutor.java:69) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:git-Paper-136]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:628) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.event.Event.callEvent(Event.java:45) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
at net.minecraft.world.level.block.entity.HopperBlockEntity.callPushMoveEvent(HopperBlockEntity.java:285) ~[?:?]
at net.minecraft.world.level.block.entity.HopperBlockEntity.hopperPush(HopperBlockEntity.java:214) ~[?:?]
at net.minecraft.world.level.block.entity.HopperBlockEntity.ejectItems(HopperBlockEntity.java:356) ~[?:?]
at net.minecraft.world.level.block.entity.HopperBlockEntity.tryMoveItems(HopperBlockEntity.java:159) ~[?:?]
at net.minecraft.world.level.block.entity.HopperBlockEntity.pushItemsTick(HopperBlockEntity.java:140) ~[?:?]
at net.minecraft.world.level.chunk.LevelChunk$BoundTickingBlockEntity.tick(LevelChunk.java:1167) ~[?:?]
at net.minecraft.world.level.chunk.LevelChunk$RebindableTickingBlockEntityWrapper.tick(LevelChunk.java:1119) ~[?:?]
at net.minecraft.world.level.Level.tickBlockEntities(Level.java:956) ~[?:?]
at net.minecraft.server.level.ServerLevel.tick(ServerLevel.java:679) ~[?:?]
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1607) ~[paper-1.18.1.jar:git-Paper-136]
at net.minecraft.server.dedicated.DedicatedServer.tickChildren(DedicatedServer.java:480) ~[paper-1.18.1.jar:git-Paper-136]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1470) ~[paper-1.18.1.jar:git-Paper-136]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1264) ~[paper-1.18.1.jar:git-Paper-136]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:317) ~[paper-1.18.1.jar:git-Paper-136]
at java.lang.Thread.run(Unknown Source) ~[?:?]

Steps to reproduce

just found those error logs.

Additional context

No response

[Feature]: Hopper logic enhancement

Feature description

i feel as though the hopper shouldn't have its flow restricted, but it has to have permission to interact with a container, the locks have to align.

Example:
Chest1 is on top of hopper, which feeds into Chest2

Scenario A: nothing is locked
everything should work as normal, chest1 empties into the hopper, then feeds into chest2.

Scenario B: hopper is locked, chests aren't
would still run the same as before, since access to chests are "public"

Scenario C: both chests are locked, not hopper
hopper wouldn't take or empty, as it doesn't share access with the chests

Scenario D: everything is locked by PlayerZ
chest1 locked by PlayerZ/or has access and hopper locked by PlayerZ/or has access would allow for hopper to interact with chest1. since chest2 is also locked by PlayerZ/ or has access, items would flow into chest2

with the system as it is, players have to interact with each chest/hopper to allow for flow

[Bug]: Lock hint message being spammed in chat

Version of BlockProt

blockprot-spigot-1.0.6-all

Description of the bug

Whenever you click on a door or chest, the message "You can protect your blocks by crouching and Right-clicking your chest…. Also Check out /blockprot settings to configure it to your liking.“
The message should only come once and not every time. That spams the chat quite a lot. Can you please change this?

Steps to reproduce

  1. Go to a door
  2. Right click it
  3. Message comes every time
66864726401__5A6A43F2-D9BD-4854-BEFD-F1345D59F561.MOV

Additional context

No response

[Bug]: dupe a shulker box

Version of BlockProt

BlockProt 0.4.12 , Server 1.17.1 and GriefPrevention

Description of the bug

dupe a shulker box bug.

Steps to reproduce

Please check yt movie.
https://youtu.be/yECXhwp51t8

A player using GP places a box on his territory.
Lock the box and then unlock it.
Other players can copy a box by destroying it against it

Additional context

No response

[Bug]:translation problem

Version of BlockProt

~1.0.6

Description of the bug

Options language_file: translations_en.yml

The language option has no "" (like "translations_en.yml")

If you fill in the language file directly(like language_file: translations_zh-tw.yml)

If I use this plugin function in game
All messages will be displayed Unknown translation

Steps to reproduce

1.go to config file
2.set language_file: translations_en.yml to language_file: translations_zh-tw.yml
3.join game
4.see this

Additional context

No response

[Feature]: Worldguard region blacklist

Feature description

Hey,
It will be cool if you can add a worldguard support. Some regions player shouldnt lock open containers. Example a global chest. And if you were able to open a global useable chest, you can lock it. Thats bad.
Solution: Add region blacklist.

[Bug]: Map dupe using the blockProt GUI

Version of BlockProt

0.4.1 | paper-1.16.5-779

Description of the bug

I dont really know how to describe it, but I hope this video from my friend helps.
https://youtu.be/7PrOHRT47m0

Steps to reproduce

  1. Go to a blockProt protected container.
  2. Go to manage friends
  3. Take the map and click it out of the inventory menu
  4. Exit and re-enter manage friends
  5. take the map and put it in your inventory

Additional context

not 100% sure of the paper version as the server is run on a host which just says "1.16.5 Paper" so me and the servers owner assume it's the latest version.

[Bug]: Can use hopper minecart to steal items.

Version of BlockProt

1.0.3

Description of the bug

Place the hopper minecart under the locked container to get the contents of the container.

Steps to reproduce

1.Lock the chest.
2.Place rail under the chest
3.Place hopper minecart on the rail.
4.Right click hopper minecart.

Additional context

No response

[Q]: Could you add me to the tranlation team?

Your question

Hi! This plugin is wonderfull, so I made Russian translation. How can I contribute it to the project?
I logged in gitlocalize, but can't fing any options to make translation...

[Suggestion]: Additional friend system improvement.

Feature description

For blocks that have already been set up as friends, it was a little inconvenient to modify friends individually when modifying many blocks.

It may not be possible, but can you add a function that allows you to apply friend settings to blocks near the player when setting up friends?

[Bug]: Can not double chest place

Version of BlockProt

paper-1.17.1-137 and blockprot 0.4.8

Description of the bug

User can only place single boxes, if you try to place a double box, it will be dropped.

Bug Report Video https://youtu.be/9hPzh7RcGTU

Steps to reproduce

  1. Place chest
  2. to double chest
    and finish

Additional context

No response

[Bug]: No permission when unlocked if there is a friend added

Version of BlockProt

0.4.8, Paper 1.17.1

Description of the bug

Config: Default
Plugin Version: 0.4.8
Minecraft version: 1.17.1
Server: Paper 1.17.1
Spigot: v1_17_R1

EXPECTED BEHAVIOR: After unlocking an item, regardless of the settings, the item should be accessible by all.

ISSUE: After adding a friend to any lockable item, once unlocked, nobody except that friend or friends has permissions to interact with the block. This includes breaking, opening, closing, or any interaction. The people added as friends, however, are able to interact with the block, but not break it or lock it. The owner of the block can lock it to regain permissions and the ability to break and interact with the block.

When no friends are added, the lock/unlock mechanism works totally fine.

Steps to reproduce

  1. Place and lock any lockable item.
  2. Add a friend to the item
  3. Unlock the item
  4. Try to interact with it
  5. Have friend interact with it
  6. Re-lock said item and remove friend
  7. Unlock item
  8. Try to interact with it (it should work fine)

Additional context

Both friends I tested this with had the same experience when they were added to my /blockprot settings friends and when they were not on the list. The bug still occurred exactly as described above.

[Bug]: Hopper Protection Doesn't work

Version of BlockProt

1.0.4

Description of the bug

Hopper protection just doesn't work. Here is the video with demonstration: https://youtu.be/pD7zDvoITUk

Steps to reproduce

Watch video: https://youtu.be/pD7zDvoITUk

Additional context

Please, fix it ASAP.
Version of game 1.18.1
Version of server: Purpur 1.18.1 (one of latest builds)

My configuration

# BlockProt Config

# Load a language file from the plugins/BlockProt/ directory.
# You can create your own language files and edit existing ones.
# Translations can be missing from this file and will instead be loaded
# from "translations_en.yml".
language_file: translations_en.yml

# The fallback string when a translation cannot be found in translations_en
# and the specified language_file above. This often happens when the plugin
# is updated and there are new translations or translations were renamed. Best
# to then delete the lang/ folder and restart the server.
fallback_string: "Unknown translation"

# If this is true, we will copy and replace the translation files on
# each startup. This is so that when you should update this plugin, any
# new or updated translations are automatically copied and applied. If
# you want to modify and included translation file, you will have to make
# this false.
replace_translations: true

# If set to "true", anytime an admin joins the server, they will
# receive an in-game message if this plugin is outdated.
# If set to "false", no message will be sent but /blockprot update
# will still work.
notify_op_of_updates: true

# If set to "true", redstone will be automatically disallowed on every
# placed block, if the player has lock on place enabled.
redstone_disallowed_by_default: false

# A list of world names the plugin should not be usable in.
# The case of each name is ignored.
# Useful for a mining-only world where a block should not be
# owned by anyone. For example:
#   - world_mining
#   - world_end
excluded_worlds: [ ]

# Setting this to 'false' will make every new player have
# their lock and place setting set to of. This will be by
# default set to 'true'.
# Note: This does NOT affect players who have previously
# changed this setting.
lock_on_place_by_default: true

# Tile entities that should be locked. Tile entities are blocks
# that can contain items. You can find a detailed list of all
# possible values at https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/Material.html.
lockable_tile_entities:
  - CHEST
  - TRAPPED_CHEST
  - FURNACE
  - SMOKER
  - BLAST_FURNACE
  - HOPPER
  - BARREL
  - BREWING_STAND
  - DISPENSER
  - DROPPER
  - LECTERN

# All varieties of shulker boxes that should be lockable.
lockable_shulker_boxes:
  - BLACK_SHULKER_BOX
  - BLUE_SHULKER_BOX
  - BROWN_SHULKER_BOX
  - CYAN_SHULKER_BOX
  - GRAY_SHULKER_BOX
  - GREEN_SHULKER_BOX
  - LIGHT_BLUE_SHULKER_BOX
  - LIGHT_GRAY_SHULKER_BOX
  - LIME_SHULKER_BOX
  - MAGENTA_SHULKER_BOX
  - ORANGE_SHULKER_BOX
  - PINK_SHULKER_BOX
  - PURPLE_SHULKER_BOX
  - RED_SHULKER_BOX
  - SHULKER_BOX
  - WHITE_SHULKER_BOX
  - YELLOW_SHULKER_BOX

# Blocks that should be lockable.
# This only works with Spigot 1.16.4 or higher.
lockable_blocks:
  - ANVIL
  - CHIPPED_ANVIL
  - DAMAGED_ANVIL
  - ACACIA_FENCE_GATE
  - BIRCH_FENCE_GATE
  - CRIMSON_FENCE_GATE
  - DARK_OAK_FENCE_GATE
  - JUNGLE_FENCE_GATE
  - OAK_FENCE_GATE
  - SPRUCE_FENCE_GATE
  - WARPED_FENCE_GATE

# Doors are two blocks and are therefore handled differently.
# This only works with Spigot 1.16.4 or higher.
lockable_doors:
  - ACACIA_DOOR
  - BIRCH_DOOR
  - CRIMSON_DOOR
  - DARK_OAK_DOOR
  - JUNGLE_DOOR
  - OAK_DOOR
  - SPRUCE_DOOR
  - WARPED_DOOR

[Question]: Can anyone lock every single chest?

Your question

Hi! I was wondering if anyone can lock every single chest? If so it should be reading who placed the blocks and only allowing that person to lock it. Otherwise anyone can come to my base and lock my chests?

[Bug]: BlockProt v0.4.12

Version of BlockProt

BlockProt 0.4.12

Description of the bug

Players could broke that shulker box to 0.4.12 ...

They just told me ...

Steps to reproduce

Player A puts shulker box, Player B could broke that shulker box.

I think it's new bug from 0.4.12 ...

Additional context

blockprot-spigot-0.4.12-shulker-dupe-fix-all.zip

[Bug]OR[Feature]?:OP Can't open block

Version of BlockProt

0.4.13

Description of the bug

OP Can't open block

Steps to reproduce

1.lock block
2.op Can't open this block

Additional context

No response

[Suggestion]: Reload Check Message

Feature description

When using the /blockprot reload command, you need to check the console to see if it has been reloaded.

It's my personal opinion, but I think it's good to tell you through in-game messages.

Anvils can fall and loose their protection

Protections for anvils are stored by location (like all other blocks). However, anvils have physics and can fall, thus invalidating their previous location. This also becomes an issue with statistics, as the location stored there is also invalidated. I see two options here:

  • Change the protection to the new location (Difficult to code)
  • Prohibit locked anvils from falling (More restrictive, might cost performance)

[Bug]: lost the ability to lock

Version of BlockProt

1.0.0

Description of the bug

essentially happened after i installed a permission plugin (ppp), the lock gui just wont appear anymore (doing the crouch and right click freehand process). i have verified i have both blockprot.lock and blockprot.admin perms, i am also an op

Steps to reproduce

add permissions ++
try to lock block like door/chest
it wont show the gui

Additional context

i run a simple server, we have 9 people on it and only 3 plugins, but the most important one is this one (the only one i need to manage permissions for), so i also wanted to ask if you are aware of what is the best permission plugin that is compatible with yours so i can have it installed and try it out
thanks for reading

BlockProt launch warnings

Warning during plugin loading.
Plugins: item-nbt-api-plugin-2.7.1, BlockProt-0.1.7-all.

java.lang.NumberFormatException: For input string: "BlockProt 0"
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) ~[?:1.8.0_275]
        at java.lang.Integer.parseInt(Integer.java:580) ~[?:1.8.0_275]
        at java.lang.Integer.parseInt(Integer.java:615) ~[?:1.8.0_275]
        at de.sean.blockprot.bukkit.tasks.UpdateChecker$Version.compareTo(UpdateChecker.kt:66) ~[?:?]
        at de.sean.blockprot.bukkit.tasks.UpdateChecker.run(UpdateChecker.kt:27) ~[?:?]
        at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftTask.run(CraftTask.java:81) ~[spigot-1.16.5.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:54) [spigot-1.16.5.jar:2991-Spigot-018b9a0-f3f3094]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_275]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_275]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_275]

[Bug]: Can break blocks to disable protection

Version of BlockProt

0.4.11, Purpur version git-Purpur-1331 (MC: 1.17.1) (Implementing API version 1.17.1-R0.1-SNAPSHOT) (Git: 635d108 on ver/1.17.1)

Description of the bug

By breaking a block, one can remove the protections on it allowing it to be accessed or broken a second time.

Steps to reproduce

  1. Have someone place and protect a block
  2. Break the block
  3. Break it a second time
  4. Block is broken and no longer protected.

Additional context

No response

[Feature]: Automatic Language Selection

Feature description

If BlockProt is installed for the first time or there is no Config file, it would be nice to load it automatically based on the language of the computer.

[Feature]:Add translation of config

Feature description

ZH_TW translation of config

# BlockProt 配置

# 從 plugins/BlockProt/lang 目錄加載語言文件。
# 您可以創建自己的語言文件或編輯現有的語言文件。
# 文件中可能缺少翻譯,而依然還是會加載翻譯
# 將會從 "translations_en.yml" 獲取未翻譯的語言.
language_file: translations_en.yml

# 在 "translations_en" 中找不到翻譯時的備用顯示語言(或是上方指定加載的語言文件) 
# 這經常發生在插件更新後並且有新的翻譯或翻譯文件已重新命名。 
# 最好刪除 lang 文件夾並重新啟動服務器。
fallback_string: "Unknown translation"

# 如果設置為 "true" ,我們將在每次啟動時自動複製並替換翻譯文件
# 這樣當你更新這個插件時,任何新的或更新的翻譯將會自動複製並應用。
# 如果你想修改自訂翻譯文件,你必須使將此選項設置為 "false"。
replace_translations: true

# 如果設置為 "true",只要管理員加入服務器且此插件已過時,則會在遊戲中收到更新訊息。
# 如果設置為 "false" ,則不會發送更新訊息,你可以使用 /blockprot update 仍然有效。
notify_op_of_updates: false

# 如果設置為 "true" 
# 玩家啟用了自動上鎖方塊,則每個放置的方塊都會自動禁用紅石。
# 反之亦然
redstone_disallowed_by_default: false

# 禁止此插件在特定世界使用。
# 將會忽略每個世界名稱的大小寫(意味著大小寫皆可)。
# 對於任何人都不該上鎖方塊的純挖礦世界很有用
# 例如:
#   - world_mining
#   - world_end
excluded_worlds: [ ]

# 將此設置為 "false"
# 將使每個新玩家的自動鎖定和相關設定設置為關閉。
# 此默認設置為 "true"。
# 注意:這不會影響之前已更改此設置的玩家。
lock_on_place_by_default: true

# 玩家可以鎖定的最大方塊數。
# 如果刪除此選項或設置為任何負值
# 將設置沒有限制。
player_max_locked_block_count: -1

# 應該上鎖的"實體"方塊。
# 您可以在下方連結找到所有實體方塊的詳細列表
# https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/Material.html.
lockable_tile_entities:
  - CHEST
  - TRAPPED_CHEST
  - FURNACE
  - SMOKER
  - BLAST_FURNACE
  - HOPPER
  - BARREL
  - BREWING_STAND
  - DISPENSER
  - DROPPER
  - LECTERN

# 設定各種可以上鎖的界浮盒。
lockable_shulker_boxes:
  - BLACK_SHULKER_BOX
  - BLUE_SHULKER_BOX
  - BROWN_SHULKER_BOX
  - CYAN_SHULKER_BOX
  - GRAY_SHULKER_BOX
  - GREEN_SHULKER_BOX
  - LIGHT_BLUE_SHULKER_BOX
  - LIGHT_GRAY_SHULKER_BOX
  - LIME_SHULKER_BOX
  - MAGENTA_SHULKER_BOX
  - ORANGE_SHULKER_BOX
  - PINK_SHULKER_BOX
  - PURPLE_SHULKER_BOX
  - RED_SHULKER_BOX
  - SHULKER_BOX
  - WHITE_SHULKER_BOX
  - YELLOW_SHULKER_BOX

# 可上鎖的方塊。
# 這僅適用於 Spigot 1.16.4 或更高版本。
lockable_blocks:
  - ANVIL
  - CHIPPED_ANVIL
  - DAMAGED_ANVIL
  - ACACIA_FENCE_GATE
  - BIRCH_FENCE_GATE
  - CRIMSON_FENCE_GATE
  - DARK_OAK_FENCE_GATE
  - JUNGLE_FENCE_GATE
  - OAK_FENCE_GATE
  - SPRUCE_FENCE_GATE
  - WARPED_FENCE_GATE

# 門是兩個方塊,因此插件對此的處理方式不同。
# 這僅適用於 Spigot 1.16.4 或更高版本。
lockable_doors:
  - ACACIA_DOOR
  - BIRCH_DOOR
  - CRIMSON_DOOR
  - DARK_OAK_DOOR
  - JUNGLE_DOOR
  - OAK_DOOR
  - SPRUCE_DOOR
  - WARPED_DOOR

# 中文配置翻譯者: vincentwang0905
# 中文配置翻譯者github連結: https://github.com/vincentwang0905

[Bug]: door debug info in console

Version of BlockProt

0.4.13 \ 1.17.1 paper

Description of the bug

on door placement
console says the item name, then "Applying to other door!"

Steps to reproduce

place a door
look at console

Additional context

No response

[Bug]: API release version issue

Version of BlockProt

1.0.2

Description of the bug

API not yet released on Spigot/CurseForge!

[15:07:20 WARN]: [NBTAPI] [NBTAPI] The NBT-API at 'package de.sean.blockprot.bukkit.shaded.nbtapi' seems to be a future Version, not yet released on Spigot/CurseForge!
[15:07:20 WARN]: [NBTAPI] [NBTAPI] Current Version: '2.9.0-SNAPSHOT' Newest Version: 2.8.0'

Steps to reproduce

1.install BlockProt V1.0.2-all
2.start server
3.see control panel message

Additional context

image

[Feature Request]: Public Chests, Doors and etc.

Feature description

Long story short, sometime some players lock public chests on server and making them private, so no one except me (server owner and him) can open them. So my feature suggestion is to add ability to make public chests, so no one can lock it. Anyone can access it. Same story with doors and other blocks. For example someone locked doors on servers spawn, lobby or on someone's home (which was unlocked by owner).

I don't want to add plugin such a WorldGuard, because it's a huge gamechanger. I love BlockProt for being unique, simple and realistic.

[Feature Request]: Chat message hint about locking

Feature description

New players don't know that there are ability to lock their chests, etc. So it would be great each time player interacts with lockable thing it shows a notification that he can lock it and how to do this. I think it's essential

Anvils, fence gates and doors.

Anvils, fence gates and doors ignore the default setting to be locked when placed.
They also ignore the redstone_disallowed_by_default setting.

[Bug]: search_history translation BUG

Version of BlockProt

0.4.13

Description of the bug

Search_history cannot be added to the translated text
The server cannot read the TW translated text
If I join Search_history it will cause an error

Steps to reproduce

1.Go to TW to translate text
2.Added search_history translation
3.Then turn on the server

Then he cannot read the TW translated text
Will automatically switch to English text

Additional context

No response

[Bug]: shulkers are broken

Version of BlockProt

1.0 beta 3 \ 1.17.1 paper

Description of the bug

player places a shulker box, no permission to access, cant pick up, op cant break

Steps to reproduce

shulker
place
cry.

Additional context

No response

[Feature]: reload

Feature description

Can you refresh the configuration, language files, etc. with the "/blockprot reload" command related to the plugin?

You can get Player Heads and other items

If you shift+RMB on a locked block, Let's say a furnace. You can get another free furnace (multiple times) :
(Edit: It happens when you want to Lock OR Unlock any Block)

image
image

The same happens with Player Heads. If you search for players to add to your "friends list", you can get their heads as well. It seems to only happen on the "search screen"

[Bug]: Given block <BLOCK> is not a lockable block/tile entity

Version of BlockProt

BlockProt v1.0.2 - git-Paper-68 (MC: 1.18.1)

Description of the bug

Had a world created, and decided to disable the locks on the furnace and now everytime a player uses the furnace, it prints out a huge error on the console.

Steps to reproduce

  1. Create World
  2. Remove furnaces from lockable blocks
  3. Open furnace

Additional context

Log for the error:

Could not pass event InventoryOpenEvent to BlockProt v1.0.2
java.lang.RuntimeException: Given block FURNACE is not a lockable block/tile entity
        at de.sean.blockprot.bukkit.nbt.BlockNBTHandler.<init>(BlockNBTHandler.java:81) ~[blockprot-spigot-1.0.2-all.jar:?]
        at de.sean.blockprot.bukkit.listeners.InventoryEventListener.onInventoryOpen(InventoryEventListener.java:144) ~[blockprot-spigot-1.0.2-all.jar:?]
        at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor63.execute(Unknown Source) ~[?:?]
        at org.bukkit.plugin.EventExecutor.lambda$create$1(EventExecutor.java:69) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:git-Paper-81]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:628) ~[paper-api-1.18.1-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.v1_18_R1.event.CraftEventFactory.callInventoryOpenEvent(CraftEventFactory.java:1324) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.server.level.ServerPlayer.openMenu(ServerPlayer.java:1493) ~[?:?]
        at net.minecraft.world.level.block.FurnaceBlock.openContainer(FurnaceBlock.java:41) ~[?:?]
        at net.minecraft.world.level.block.AbstractFurnaceBlock.use(AbstractFurnaceBlock.java:44) ~[?:?]
        at net.minecraft.world.level.block.state.BlockBehaviour$BlockStateBase.use(BlockBehaviour.java:978) ~[?:?]
        at net.minecraft.server.level.ServerPlayerGameMode.useItemOn(ServerPlayerGameMode.java:584) ~[?:?]
        at net.minecraft.server.network.ServerGamePacketListenerImpl.handleUseItemOn(ServerGamePacketListenerImpl.java:1821) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundUseItemOnPacket.handle(ServerboundUseItemOnPacket.java:33) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundUseItemOnPacket.a(ServerboundUseItemOnPacket.java:9) ~[?:?]
        at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$1(PacketUtils.java:56) ~[?:?]
        at net.minecraft.server.TickTask.run(TickTask.java:18) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:149) ~[?:?]
        at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:23) ~[?:?]
        at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1413) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.server.MinecraftServer.c(MinecraftServer.java:189) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:122) ~[?:?]
        at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1391) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1384) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:132) ~[?:?]
        at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1462) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1264) ~[paper-1.18.1.jar:git-Paper-81]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:317) ~[paper-1.18.1.jar:git-Paper-81]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]

[Bug]: Copy Configuration doesn't work

Version of BlockProt

1.18.1 PaperSpigot

Description of the bug

Shift rightclick to enter UI. Set a friend and then copy configuration for a chest. Paste that configuration to other chests, only my friend can't open chests. If I set the friend list manually it works. Copying configuration has my friend in friend list, just doesn't work

Steps to reproduce

Shift rightclick to enter UI. Set a friend and then copy configuration for a chest. Paste that configuration to other chests, only my friend can't open chests. If I set the friend list manually it works. Copying configuration has my friend in friend list, just doesn't work

Additional context

No response

[Bug]: Door Permission Fail

Version of BlockProt

paper-1.17.1-130 and blockprot 0.4.9

Description of the bug

Hello Spnda,
i found the door bug.

i place a door and see top block of door, permission no set owner me.
if i see down block form door is set owner me and now see top block of door, permission set owner me

but all user on my Server can open door, if top block.
BUG-Report

Steps to reproduce

  1. place a door
  2. see top block of door, no owner set
  3. see down block of door, owner set
  4. see top block of door, owner set now

2.2. all player can open the door, if top block of door

Additional context

No response

[Bug]: Maximum number of blocks.

Version of BlockProt

BlockProt 1.0.3 / Paper-85 (1.18.1)

Description of the bug

Setting player max locked block count: -1 in the Config file does not install protected blocks.

Steps to reproduce

  1. player max locked block count: -1 Setting
  2. /blockprot reload or sever reboot
  3. chest place

Additional context

No response

[Bug]: Anvil GUI Level Bug

Version of BlockProt

BlockProt: 1.0.3 / Paper-85 (1.18.1)

Description of the bug

If the player's level is 0 in the Anvil GUI that occurs when searching for friends, it is not possible to search for friends.

Steps to reproduce

  1. Shift + Right Click
  2. Search Friends (Player Level 0)

Additional context

No response

[Bug]: Form 0.4.6 to 0.4.7 all Chest lock for owner chest

Version of BlockProt

paper-1.17.1-130 and blockprot 0.4.7

Description of the bug

Sry my English is not so good , but i have a video for this bug.

If I update the plugin from 0.4.6 to 0.4.7, no user has any more rights to his box or to new boxes. No error message is displayed in the console. In-game only the message "No authorization" comes, regardless of whether or not with an OP.

https://www.youtube.com/watch?v=wHB-1C0aKgM Bug Report Video

Steps to reproduce

  1. Starting Server with BlockProt 0.4.6
  2. Stop
  3. Starting Server with BlockProt 0.4.7
  4. and you have this bug.
    If you go back to 0.4.6, the users have the right to their boxes again.

Additional context

No response

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.