It works
Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Ursprung
67fcff7711
Commit
ddc5874fe9
@ -1,19 +1,19 @@
|
||||
package de.steamwar.fightsystem.listener;
|
||||
|
||||
import java.util.EnumSet;
|
||||
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.player.PlayerBedEnterEvent;
|
||||
|
||||
import de.steamwar.fightsystem.states.FightState;
|
||||
|
||||
public class SleepListener extends BasicListener{
|
||||
public SleepListener() {super(EnumSet.allOf(FightState.class));}
|
||||
@EventHandler
|
||||
public void onSleep(PlayerBedEnterEvent e) {
|
||||
e.setCancelled(true);
|
||||
//Block b=e.getBed();
|
||||
//b.getWorld().createExplosion(b.getLocation(),4.0F); //4==tnt => dosnt have any advantage in WS (noFire,sameStrength,moreInvSpace,selfDamage)
|
||||
}
|
||||
package de.steamwar.fightsystem.listener;
|
||||
|
||||
import de.steamwar.fightsystem.states.FightState;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.player.PlayerBedEnterEvent;
|
||||
|
||||
import java.util.EnumSet;
|
||||
|
||||
public class SleepListener extends BasicListener{
|
||||
|
||||
public SleepListener() {
|
||||
super(EnumSet.allOf(FightState.class));
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onSleep(PlayerBedEnterEvent e) {
|
||||
e.setCancelled(true);
|
||||
}
|
||||
}
|
In neuem Issue referenzieren
Einen Benutzer sperren