diff --git a/pom.xml b/pom.xml
index d569e5e..d4ee12b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -52,7 +52,7 @@
org.bukkit
bukkit
- 1.12.2-R0.1-SNAPSHOT
+ 1.13.2-R0.1-SNAPSHOT
provided
diff --git a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/RandomTeleport.java b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/RandomTeleport.java
index 8ee14c4..ac1f09a 100644
--- a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/RandomTeleport.java
+++ b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/RandomTeleport.java
@@ -362,7 +362,7 @@ public class RandomTeleport extends JavaPlugin implements RandomTeleportAPI {
if (e instanceof Player) {
Location belowLoc = targetLoc.clone().subtract(0, 1, 0);
Block belowBlock = belowLoc.getBlock();
- ((Player) e).sendBlockChange(belowLoc, belowBlock.getType(), belowBlock.getData());
+ ((Player) e).sendBlockChange(belowLoc, belowBlock.getBlockData());
}
targetLoc.setX(targetLoc.getBlockX() + 0.5);
targetLoc.setY(targetLoc.getY() + 0.1);
diff --git a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/listeners/SignListener.java b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/listeners/SignListener.java
index 129865b..4e0e9c1 100644
--- a/randomteleport-plugin/src/main/java/de/themoep/randomteleport/listeners/SignListener.java
+++ b/randomteleport-plugin/src/main/java/de/themoep/randomteleport/listeners/SignListener.java
@@ -47,9 +47,11 @@ public class SignListener implements Listener {
plugin.sendMessage(event.getPlayer(), "sign.no-permission.create", "perm", "randomteleport.sign.create");
} else {
String preset = event.getLine(2);
- plugin.sendMessage(event.getPlayer(), "sign.created", "preset", preset);
- if (plugin.getConfig().getString("presets." + preset.toLowerCase()) == null) {
- plugin.sendMessage(event.getPlayer(), "error.preset-doesnt-exist", "preset", preset);
+ if (preset != null) {
+ plugin.sendMessage(event.getPlayer(), "sign.created", "preset", preset);
+ if (plugin.getConfig().getString("presets." + preset.toLowerCase()) == null) {
+ plugin.sendMessage(event.getPlayer(), "error.preset-doesnt-exist", "preset", preset);
+ }
}
}
}
@@ -72,7 +74,8 @@ public class SignListener implements Listener {
@EventHandler(ignoreCancelled = true)
public void onSignClick(PlayerInteractEvent event) {
- if (event.getHand() == EquipmentSlot.HAND && event.getAction() == Action.RIGHT_CLICK_BLOCK && event.getClickedBlock().getType().name().contains("SIGN")) {
+ if (event.getHand() == EquipmentSlot.HAND && event.getAction() == Action.RIGHT_CLICK_BLOCK
+ && event.getClickedBlock() != null && event.getClickedBlock().getType().name().contains("SIGN")) {
Sign sign = (Sign) event.getClickedBlock().getState();
if (plugin.matchesSignVariable(sign.getLine(1))) {
String preset = sign.getLine(2).toLowerCase();
diff --git a/randomteleport-plugin/src/main/resources/config.yml b/randomteleport-plugin/src/main/resources/config.yml
index ed4a627..a36535f 100644
--- a/randomteleport-plugin/src/main/resources/config.yml
+++ b/randomteleport-plugin/src/main/resources/config.yml
@@ -6,54 +6,88 @@ debug: true
# Blocks to teleport on in normal mode
save-blocks:
- sand
+- sandstone
- gravel
- dirt
+- grass_block
+- coarse_dirt
+- podzol
- stone
+- granite
+- diorite
+- andesite
- cobblestone
-- ender_stone
+- end_stone
- netherrack
# Blocks unsave when in "--force blocks" mode
unsave-blocks:
- air
- water
-- stationary_water
- lava
-- stationary_lava
-- sapling
-- bed_block
+- oak_sapling
+- spruce_sapling
+- birch_sapling
+- jungle_sapling
+- acacia_sapling
+- dark_oak_sapling
+- white_bed
+- orange_bed
+- magenta_bed
+- light_blue_bed
+- yellow_bed
+- lime_bed
+- pink_bed
+- gray_bed
+- light_gray_bed
+- cyan_bed
+- purple_bed
+- blue_bed
+- brown_bed
+- green_bed
+- red_bed
+- black_bed
- powered_rail
- detector_rail
-- web
-- piston_extension
+- cobweb
+- piston_head
- tnt
- torch
- fire
-- sign_post
-- wooden_door
+- sign
- ladder
-- rails
+- rail
- wall_sign
- lever
-- stone_plate
-- iron_door_block
-- redstone_torch_off
-- redstone_torch_on
+- stone_pressure_plate
+- iron_door
+- redstone_wall_torch
+- redstone_torch
- stone_button
- cactus
-- magma
-- portal
+- magma_block
+- nether_portal
- vine
-- ender_portal
+- end_portal
+- end_portal_frame
- tripwire_hook
- tripwire
-- wood_button
- flower_pot
-- leaves
-- leaves_2
+- oak_leaves
+- spruce_leaves
+- birch_leaves
+- jungle_leaves
+- acacia_leaves
+- dark_oak_leaves
- barrier
- iron_trapdoor
-- wall_banner
+- oak_trapdoor
+- spruce_trapdoor
+- birch_trapdoor
+- jungle_trapdoor
+- acacia_trapdoor
+- dark_oak_trapdoor
+- oak_door
- spruce_door
- birch_door
- jungle_door