Clean up
This commit is contained in:
parent
d4d1d7ff18
commit
fed561c8f0
@ -9,7 +9,7 @@ public class PlayerChairSitEvent extends PlayerEvent implements Cancellable {
|
|||||||
|
|
||||||
private static final HandlerList handlers = new HandlerList();
|
private static final HandlerList handlers = new HandlerList();
|
||||||
private boolean cancelled = false;
|
private boolean cancelled = false;
|
||||||
|
|
||||||
public PlayerChairSitEvent(Player who) {
|
public PlayerChairSitEvent(Player who) {
|
||||||
super(who);
|
super(who);
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,7 @@ public class PlayerChairUnsitEvent extends PlayerEvent implements Cancellable {
|
|||||||
public boolean canBeCancelled() {
|
public boolean canBeCancelled() {
|
||||||
return canbecancelled;
|
return canbecancelled;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public HandlerList getHandlers() {
|
public HandlerList getHandlers() {
|
||||||
return handlers;
|
return handlers;
|
||||||
|
@ -52,7 +52,7 @@ public class PlayerSitData {
|
|||||||
|
|
||||||
public void startReSitTask(final Player player) {
|
public void startReSitTask(final Player player) {
|
||||||
int task = Bukkit.getScheduler().scheduleSyncRepeatingTask(
|
int task = Bukkit.getScheduler().scheduleSyncRepeatingTask(
|
||||||
plugin,
|
plugin,
|
||||||
new Runnable() {
|
new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
@ -73,7 +73,7 @@ public class PlayerSitData {
|
|||||||
arrow.setPassenger(player);
|
arrow.setPassenger(player);
|
||||||
sit.put(player.getName(), arrow);
|
sit.put(player.getName(), arrow);
|
||||||
Bukkit.getScheduler().scheduleSyncDelayedTask(
|
Bukkit.getScheduler().scheduleSyncDelayedTask(
|
||||||
plugin,
|
plugin,
|
||||||
new Runnable() {
|
new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
@ -109,7 +109,7 @@ public class PlayerSitData {
|
|||||||
final Location tploc = sitstopteleportloc.get(player.getName());
|
final Location tploc = sitstopteleportloc.get(player.getName());
|
||||||
if (restoreposition) {
|
if (restoreposition) {
|
||||||
Bukkit.getScheduler().scheduleSyncDelayedTask(
|
Bukkit.getScheduler().scheduleSyncDelayedTask(
|
||||||
plugin,
|
plugin,
|
||||||
new Runnable() {
|
new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
@ -22,7 +22,7 @@ public class TryUnsitEventListener implements Listener {
|
|||||||
public TryUnsitEventListener(Chairs plugin) {
|
public TryUnsitEventListener(Chairs plugin) {
|
||||||
this.plugin = plugin;
|
this.plugin = plugin;
|
||||||
}
|
}
|
||||||
|
|
||||||
//spigot...
|
//spigot...
|
||||||
@EventHandler(priority=EventPriority.LOWEST)
|
@EventHandler(priority=EventPriority.LOWEST)
|
||||||
public void onPlayerTeleport(PlayerTeleportEvent event) {
|
public void onPlayerTeleport(PlayerTeleportEvent event) {
|
||||||
|
@ -4,8 +4,8 @@ import net.minecraft.server.v1_7_R1.EntityArrow;
|
|||||||
|
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.Server;
|
import org.bukkit.Server;
|
||||||
import org.bukkit.craftbukkit.v1_7_R1.CraftWorld;
|
|
||||||
import org.bukkit.craftbukkit.v1_7_R1.CraftServer;
|
import org.bukkit.craftbukkit.v1_7_R1.CraftServer;
|
||||||
|
import org.bukkit.craftbukkit.v1_7_R1.CraftWorld;
|
||||||
import org.bukkit.entity.Arrow;
|
import org.bukkit.entity.Arrow;
|
||||||
|
|
||||||
import com.cnaude.chairs.vehiclearrow.NMSChairsArrowInterface;
|
import com.cnaude.chairs.vehiclearrow.NMSChairsArrowInterface;
|
||||||
|
Loading…
Reference in New Issue
Block a user