Guest User

Untitled

a guest
Aug 27th, 2021
27
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package listener;
  2.  
  3. import org.bukkit.Bukkit;
  4. import org.bukkit.entity.Player;
  5. import org.bukkit.event.EventHandler;
  6. import org.bukkit.event.Listener;
  7. import org.bukkit.event.player.PlayerJoinEvent;
  8. import org.bukkit.scheduler.BukkitRunnable;
  9.  
  10. import Methoden.Methoden;
  11. import de.minelag.main.Main;
  12.  
  13. public class PlayerJoinListener implements Listener {
  14.  
  15. @EventHandler
  16. public void onPlayerJoin(PlayerJoinEvent e) {
  17.  
  18. new BukkitRunnable() {
  19.  
  20. @Override
  21. public void run() {
  22. for(Player all : Bukkit.getOnlinePlayers()) {
  23. Methoden.setScoreboard(all);
  24. }
  25. }
  26.  
  27. }.runTaskLater(Main.getPlugin(), 1);
  28. }
  29.  
  30. }
  31.  
RAW Paste Data