9
0
mirror of https://github.com/Xiao-MoMi/Custom-Fishing.git synced 2025-12-29 20:09:14 +00:00
This commit is contained in:
Xiao-MoMi
2022-10-18 01:50:56 +08:00
parent eb350a49a8
commit 023667a7d7
98 changed files with 1423 additions and 741 deletions

View File

@@ -10,4 +10,19 @@ public interface BlockInterface {
void placeBlock(String id, Location location);
@Nullable
String getID(Block block);
default void replaceBlock(Location location, String id) {
removeBlock(location.getBlock());
placeBlock(id, location);
}
static boolean isVanillaItem(String item) {
char[] chars = item.toCharArray();
for (char character : chars) {
if ((character < 65 || character > 90) && character != 95) {
return false;
}
}
return true;
}
}