修复了玩家离线时如果坐在椅子上下次上线可能会被卡在方块里的问题
All checks were successful
Java CI-CD with Maven / build (push) Successful in 4m16s
All checks were successful
Java CI-CD with Maven / build (push) Successful in 4m16s
This commit is contained in:
parent
87dd2983f2
commit
75dbefb02a
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>cn.lunadeer</groupId>
|
<groupId>cn.lunadeer</groupId>
|
||||||
<artifactId>EssentialsD</artifactId>
|
<artifactId>EssentialsD</artifactId>
|
||||||
<version>1.17.1</version>
|
<version>1.17.2</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>EssentialsD</name>
|
<name>EssentialsD</name>
|
||||||
|
@ -122,8 +122,10 @@ public class ChairEvent implements Listener {
|
|||||||
}
|
}
|
||||||
Entity vehicle = event.getPlayer().getVehicle();
|
Entity vehicle = event.getPlayer().getVehicle();
|
||||||
// Let players stand up when leaving the server.
|
// Let players stand up when leaving the server.
|
||||||
if (vehicle instanceof ArmorStand)
|
if (vehicle instanceof ArmorStand) {
|
||||||
vehicle.remove();
|
vehicle.remove();
|
||||||
|
event.getPlayer().teleportAsync(event.getPlayer().getLocation().add(0, EssentialsD.config.getChairSitHeight() * -1, 0));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private ArmorStand dropSeat(Block chair) {
|
private ArmorStand dropSeat(Block chair) {
|
||||||
|
Loading…
Reference in New Issue
Block a user