Guest Gabriel Alves Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 aulguem pode me ajudar queria saber como fazer para /setwarp e ae a pessoa vai para la qual e o codigo Link para o comentário Compartilhar em outros sites More sharing options...
Guest » MickCraft » xKizame » Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Outro SrGames da vida Link para o comentário Compartilhar em outros sites More sharing options...
Trow_Games Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Você já tem algum código planejado?!! Não fique esperando, tudo pronto na mão... Começa um código ae, que nós vamos lhe dando suporte. Link para o comentário Compartilhar em outros sites More sharing options...
Guest » MickCraft « Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Um SrGames da vida -.- já faço pera.. Link para o comentário Compartilhar em outros sites More sharing options...
Guest Healthay Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Um SrGames da vida -.- já faço pera.. Você que é o SrGames O/o Link para o comentário Compartilhar em outros sites More sharing options...
Guest Gabriel Alves Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Um SrGames da vida -.- já faço pera.. SrGames ? Você já tem algum código planejado?!! Não fique esperando, tudo pronto na mão... Começa um código ae, que nós vamos lhe dando suporte. kkk nao sei new comecar estou tentando com oque me derem por inquanto Um SrGames da vida -.- já faço pera.. eita Link para o comentário Compartilhar em outros sites More sharing options...
Guest » MickCraft « Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 SrGames ? kkk nao sei new comecar estou tentando com oque me derem por inquanto eita Não so SrGames carai -.- Link para o comentário Compartilhar em outros sites More sharing options...
Trow_Games Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 SrGames ? kkk nao sei new comecar estou tentando com oque me derem por inquanto eita Só você tirar a base deste vídeo: Vídeo. Link para o comentário Compartilhar em outros sites More sharing options...
Guest » MickCraft « Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Só você tirar a base deste vídeo: Vídeo. Que voz feia Link para o comentário Compartilhar em outros sites More sharing options...
Trow_Games Postado Junho 15, 2015 Denunciar Compartilhar Postado Junho 15, 2015 Que voz feia Olha isso. Link para o comentário Compartilhar em outros sites More sharing options...
Naghtrion Postado Junho 21, 2015 Denunciar Compartilhar Postado Junho 21, 2015 (editado) Peguei do meu plugin na parte do Lobby, só substitui para o que quiser. package com.DevNaghtrion.Comando.Set; import java.io.File; import java.io.IOException; import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; import org.bukkit.configuration.file.FileConfiguration; import org.bukkit.configuration.file.YamlConfiguration; import org.bukkit.entity.Player; import com.DevNaghtrion.Main; public class SetLobby implements CommandExecutor { public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) { Player p = (Player)sender; File warps = new File(Main.plugin.getDataFolder(), "Warps.yml"); FileConfiguration wr = YamlConfiguration.loadConfiguration(warps); if (cmd.getName().equalsIgnoreCase("setlobby")) { if (sender instanceof Player) { if ((sender.hasPermission("np.setwarp")) || (sender.isOp()) || (sender.hasPermission("np.admin"))) { wr.set("Lobby.World", p.getWorld().getName()); wr.set("Lobby.X", Double.valueOf(p.getLocation().getX())); wr.set("Lobby.Y", Double.valueOf(p.getLocation().getY())); wr.set("Lobby.Z", Double.valueOf(p.getLocation().getZ())); wr.set("Lobby.Yaw", Float.valueOf(p.getLocation().getYaw())); wr.set("Lobby.Pitch", Float.valueOf(p.getLocation().getPitch())); try { wr.save(warps); } catch (IOException e) { e.printStackTrace(); } p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Set").replace("&", "§")); } else { p.sendMessage(Main.plugin.getConfig().getString("PlayerSemPermissao").replace("&", "§").replace("{player}", sender.getName())); } } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } if (cmd.getName().equalsIgnoreCase("lobby")) { if (sender instanceof Player) { if (wr.getString("Lobby") == null) { p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.NaoEncontrado").replace("&", "§")); return true; } World w = Bukkit.getWorld(wr.getString("Lobby.World")); double x = wr.getDouble("Lobby.X"); double y = wr.getDouble("Lobby.Y"); double z = wr.getDouble("Lobby.Z"); float yaw = (float)wr.getDouble("Lobby.Yaw"); float pitch = (float)wr.getDouble("Lobby.Pitch"); Location l = new Location(w, x, y, z); l.setYaw(yaw); l.setPitch(pitch); p.teleport(l); p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Teleportado").replace("&", "§")); } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } if (cmd.getName().equalsIgnoreCase("dellobby")) { if (sender instanceof Player) { if ((sender.hasPermission("np.delwarp")) || (sender.isOp()) || (sender.hasPermission("np.del")) || (sender.hasPermission("np.admin"))) { if (wr.getString("Lobby") == null) { p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.NaoEncontrado").replace("&", "§")); return true; } wr.set("Lobby", null); try { wr.save(warps); } catch (IOException e) { e.printStackTrace(); } p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Del").replace("&", "§")); } else { p.sendMessage(Main.plugin.getConfig().getString("PlayerSemPermissao").replace("&", "§").replace("{player}", sender.getName())); } } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } return false; } } config: Warps: Lobby: Set: '&2Você setou o local do Lobby' Del: '&4Você deletou o local do Lobby' Teleportado: '&6Você foi teleportado para o Lobby' NaoEncontrado: '&cNão foi possivel encontrar o Lobby. Contate um Staffer.' ###### Mensagens: #Mensagem que aparece no console quando nao e possivel executar um comando. #Nao utilize acentuacao para o console. ErroConsole: '&4O Console nao pode executar este comando!' ####### PlayerSemPermissao: '&b{player} &4Você nao tem Permissão para usar este comando!' Like ou Resolvido? @Edit Quote aulguem pode me ajudar queria saber como fazer para /setwarp e ae a pessoa vai para la qual e o codigo Editado Junho 21, 2015 por Mr Naghtrion Link para o comentário Compartilhar em outros sites More sharing options...
Guest Gabriel Alves Postado Junho 21, 2015 Denunciar Compartilhar Postado Junho 21, 2015 Peguei do meu plugin na parte do Lobby, só substitui para o que quiser. package com.DevNaghtrion.Comando.Set; import java.io.File; import java.io.IOException; import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; import org.bukkit.configuration.file.FileConfiguration; import org.bukkit.configuration.file.YamlConfiguration; import org.bukkit.entity.Player; import com.DevNaghtrion.Main; public class SetLobby implements CommandExecutor { public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) { Player p = (Player)sender; File warps = new File(Main.plugin.getDataFolder(), "Warps.yml"); FileConfiguration wr = YamlConfiguration.loadConfiguration(warps); if (cmd.getName().equalsIgnoreCase("setlobby")) { if (sender instanceof Player) { if ((sender.hasPermission("np.setwarp")) || (sender.isOp()) || (sender.hasPermission("np.admin"))) { wr.set("Lobby.World", p.getWorld().getName()); wr.set("Lobby.X", Double.valueOf(p.getLocation().getX())); wr.set("Lobby.Y", Double.valueOf(p.getLocation().getY())); wr.set("Lobby.Z", Double.valueOf(p.getLocation().getZ())); wr.set("Lobby.Yaw", Float.valueOf(p.getLocation().getYaw())); wr.set("Lobby.Pitch", Float.valueOf(p.getLocation().getPitch())); try { wr.save(warps); } catch (IOException e) { e.printStackTrace(); } p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Set").replace("&", "§")); } else { p.sendMessage(Main.plugin.getConfig().getString("PlayerSemPermissao").replace("&", "§").replace("{player}", sender.getName())); } } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } if (cmd.getName().equalsIgnoreCase("lobby")) { if (sender instanceof Player) { if (wr.getString("Lobby") == null) { p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.NaoEncontrado").replace("&", "§")); return true; } World w = Bukkit.getWorld(wr.getString("Lobby.World")); double x = wr.getDouble("Lobby.X"); double y = wr.getDouble("Lobby.Y"); double z = wr.getDouble("Lobby.Z"); float yaw = (float)wr.getDouble("Lobby.Yaw"); float pitch = (float)wr.getDouble("Lobby.Pitch"); Location l = new Location(w, x, y, z); l.setYaw(yaw); l.setPitch(pitch); p.teleport(l); p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Teleportado").replace("&", "§")); } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } if (cmd.getName().equalsIgnoreCase("dellobby")) { if (sender instanceof Player) { if ((sender.hasPermission("np.delwarp")) || (sender.isOp()) || (sender.hasPermission("np.del")) || (sender.hasPermission("np.admin"))) { if (wr.getString("Lobby") == null) { p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.NaoEncontrado").replace("&", "§")); return true; } wr.set("Lobby", null); try { wr.save(warps); } catch (IOException e) { e.printStackTrace(); } p.sendMessage(Main.plugin.getConfig().getString("Warps.Lobby.Del").replace("&", "§")); } else { p.sendMessage(Main.plugin.getConfig().getString("PlayerSemPermissao").replace("&", "§").replace("{player}", sender.getName())); } } else { sender.sendMessage(Main.plugin.getConfig().getString("Mensagens.ErroConsole").replace("&", "§")); } } return false; } } config: Warps: Lobby: Set: '&2Você setou o local do Lobby' Del: '&4Você deletou o local do Lobby' Teleportado: '&6Você foi teleportado para o Lobby' NaoEncontrado: '&cNão foi possivel encontrar o Lobby. Contate um Staffer.' ###### Mensagens: #Mensagem que aparece no console quando nao e possivel executar um comando. #Nao utilize acentuacao para o console. ErroConsole: '&4O Console nao pode executar este comando!' ####### PlayerSemPermissao: '&b{player} &4Você nao tem Permissão para usar este comando!' Like ou Resolvido? @Edit Quote eu ja tinha conseguido mais oque vale e a intencao =) Link para o comentário Compartilhar em outros sites More sharing options...
leonardosc Postado Junho 21, 2015 Denunciar Compartilhar Postado Junho 21, 2015 Sua dúvida foi marcada como [Resolvido] e movido à área de dúvidas resolvidas. Atenciosamente, Gamer's Board Link para o comentário Compartilhar em outros sites More sharing options...
Pergunta
Guest Gabriel Alves
aulguem pode me ajudar
queria saber como fazer para
/setwarp
e ae a pessoa vai para la qual e o codigo
Link para o comentário
Compartilhar em outros sites
12 respostass a esta questão
Posts Recomendados