Fail on DC
This commit is contained in:
parent
2579ab220e
commit
b0e52ca41f
1 changed files with 9 additions and 0 deletions
|
@ -11,6 +11,8 @@ import org.bukkit.Location;
|
|||
import org.bukkit.World;
|
||||
import org.bukkit.entity.EntityType;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.player.PlayerQuitEvent;
|
||||
import org.bukkit.potion.PotionEffect;
|
||||
import org.bukkit.potion.PotionEffectType;
|
||||
import org.bukkit.scoreboard.Team;
|
||||
|
@ -82,6 +84,13 @@ public class LightningEvent extends Event {
|
|||
}
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onPlayerQuit(PlayerQuitEvent event) {
|
||||
if (MC13DTL.board.getPlayers(team).contains(event.getPlayer())) {
|
||||
eventFailed();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getMessage() {
|
||||
return "Survive the night while staying outdoors (you need to have direct sky light above you at all times)";
|
||||
|
|
Loading…
Reference in a new issue