13
0

Merge remote-tracking branch 'origin/seat'

Dieser Commit ist enthalten in:
Lixfel 2020-11-02 16:27:26 +01:00
Commit 5770c05d83

Datei anzeigen

@ -20,6 +20,8 @@
package de.steamwar.spectatesystem.listener;
import org.bukkit.GameMode;
import org.bukkit.block.data.Bisected;
import org.bukkit.block.data.type.Stairs;
import org.bukkit.entity.AbstractArrow;
import org.bukkit.entity.Arrow;
import org.bukkit.entity.EntityType;
@ -41,6 +43,9 @@ public class PlayerSeatListener extends BasicListener {
if(event.getPlayer().getGameMode() != GameMode.ADVENTURE)
return;
if(((Stairs)event.getClickedBlock().getBlockData()).getHalf() != Bisected.Half.BOTTOM)
return;
if(event.getPlayer().isInsideVehicle())
event.getPlayer().getVehicle().remove();