Exemple #1
0
 /*
  * 死亡したらスポーンポイントにスポーン
  */
 @EventHandler
 public void onPlayerRespawn(final PlayerRespawnEvent e) {
   if (plugin.getAPI().onDeath()) {
     Bukkit.getScheduler()
         .runTaskLater(
             plugin,
             new Runnable() {
               public void run() {
                 plugin.getAPI().spawn(e.getPlayer());
               }
             },
             5);
   }
 }
Exemple #2
0
 public DeathSpawn(NumaAdmin plugin) {
   this.plugin = plugin;
   plugin.getServer().getPluginManager().registerEvents(this, plugin);
 }