Solved 2 Messages

Discussion in 'Plugin Development' started by NoSpanMan, Apr 24, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    NoSpanMan

    I have:
    Code:
    killer.sendMessage(ChatColor.GREEN + "[" + ChatColor.GOLD + "KubusCraft" + ChatColor.GREEN + "]" + ChatColor.WHITE + "Je hebt gewonnen!");
               plugin.inlobby.remove(killer.getName());
               plugin.readysay.remove(killer.getName());
               plugin.ready = 0;
               plugin.pinlobby = 0;
               
               World w = Bukkit.getServer().getWorld(plugin.getConfig().getString("leavepoint.world"));
               int x = plugin.getConfig().getInt("leavepoint.x");
               int y = plugin.getConfig().getInt("leavepoint.y");
               int z = plugin.getConfig().getInt("leavepoint.z");
               killer.teleport(new Location(w, x, y, z));
    
    But every time i play my minigame and i win he says the first time: je hebt gewonnen 2 times the secondary time he says: je hebt gewonnen 4 times and every x he sends it 2 more times how can i fix this?
     
  2. @NoSpanMan I'm confused, what's the issue exactly? A message sends when it shouldn't?
     
  3. Offline

    mine-care

    We need a litle more code to understand what does the sheduling and sends it over and over.
     
  4. this.cancel();
     
  5. Offline

    NoSpanMan

    I fixed it :D
     
Thread Status:
Not open for further replies.

Share This Page