Ir para conteúdo

MrPowerGamerBR

Membros VIP
  • Total de itens

    585
  • Registro em

  • Última visita

Respostas na Comunidade

  1. MrPowerGamerBR's postagem in Location - Retornando os dois para 1 was marked as the answer   
    E o que você quer fazer?
     
    Porque, do jeito que eu estou vendo, você está:
     
    Pegando a localização atual do player Alterando a posição do spawn do mundo para a posição atual do player Pegando o nome do mundo por... não sei, faço a mínima ideia porque você fez isso Salva a localização na configuração E isso só nisso aqui
    Location arena2 = p.getLocation(); p.getWorld().setSpawnLocation(arena2.getBlockX(), arena2.getBlockY(), arena2.getBlockZ()); p.getWorld().getName(); getConfig().set("Arena.Mundo", p.getLocation().getWorld().getName()); getConfig().set("Arena.X", Double.valueOf(p.getLocation().getX())); getConfig().set("Arena.Y", Double.valueOf(p.getLocation().getY())); getConfig().set("Arena.Z", Double.valueOf(p.getLocation().getZ())); getConfig().set("Arena.Pitch", Float.valueOf(p.getLocation().getPitch())); getConfig().set("Arena.Yaw", Float.valueOf(p.getLocation().getYaw())); saveConfig(); Algo que poderia ser reduzido para
    getConfig().set("Arena.Mundo", p.getLocation().getWorld().getName()); getConfig().set("Arena.X", Double.valueOf(p.getLocation().getX())); getConfig().set("Arena.Y", Double.valueOf(p.getLocation().getY())); getConfig().set("Arena.Z", Double.valueOf(p.getLocation().getZ())); getConfig().set("Arena.Pitch", Float.valueOf(p.getLocation().getPitch())); getConfig().set("Arena.Yaw", Float.valueOf(p.getLocation().getYaw())); saveConfig(); Já aqui
    Location saida2 = p.getWorld().getSpawnLocation(); saida2.setX(saida2.getBlockX()); saida2.setY(saida2.getBlockY()); saida2.setZ(saida2.getBlockZ()); p.teleport(saida2); Você vai ter que pegar cada valor da config (int x = getConfig().getInt("...")) e criar uma localização usando elas (new Location(Bukkit.getWorld(worldName), x...))
  2. MrPowerGamerBR's postagem in Plugin urgente was marked as the answer   
    http://lori.mrpowergamerbr.com/?dir=plugins
  3. MrPowerGamerBR's postagem in [Resolvido] Futebol in-game. was marked as the answer   
    Se você sabe alguma página na internet que mostra os jogos acontecendo no momento, você pode usar o Jsoup (eu uso ele para pegar as notícias do Globo News e mostrar em um livro do Minecraft) e pegar as informações dos jogos a cada X segundos.
  4. MrPowerGamerBR's postagem in [Resolvido] Como posso fazer esse botão? was marked as the answer   
    Eu tenho um parecido:
    .button_normal { border: 0px none; background: #009CFF none repeat scroll 0% 0%; border-radius: 4px; box-shadow: 0px 5px 0px #006899; color: #FFF; cursor: pointer; font-family: inherit; font-style: inherit; font-weight: inherit; line-height: inherit; font-size-adjust: inherit; font-stretch: inherit; font-feature-settings: inherit; font-language-override: inherit; font-kerning: inherit; font-synthesis: inherit; font-variant: inherit; margin: 3px; outline: 0px none; padding: 4px 12px; font-size: 120%; transition: all 0.1s linear 0s; } .button_normal:active { box-shadow: 0 2px 0 #006599; transform: translateY(3px); } A única diferença é que ele não dá aquela abaixadinha quando você passa o mouse por cima, mas eu acho que isto é possível fazer usando animações com CSS.
  5. MrPowerGamerBR's postagem in [Resolvido] Me Ajudem ! was marked as the answer   
    Bem, o único jeito para a gente conseguir ajudar é você hospedando o website em algum lugar e você passar a URL.
  6. MrPowerGamerBR's postagem in [Resolvido] PHP Hash diferente do logit ;-; what? was marked as the answer   
    $password = $_POST["password"]; if ((hash('sha256', ($password . $row["salt"]))) == $row["password"]) { // Senha correta } else { // Senha incorreta } Eu tinha falado várias vezes para você que precisa aplicar o salt antes de fazer o hash.
  7. MrPowerGamerBR's postagem in [Entregue] [Pedido] Só nascer mobs pelos mobspawners was marked as the answer   
    Irei fazer o plugin.
     
    Feito: http://lori.mrpowergamerbr.com/sharex/OnlySpawners.jar
  8. MrPowerGamerBR's postagem in [Resolvido] Duvida com PlayerQuitEvent was marked as the answer   
    O PlayerKickEvent não é disparado caso o player não foi kickado.
     
    O que eu faria é criar um HashSet e adicionar o player que foi kickado na HashSet (use o evento PlayerKickEvent), aí, no PlayerQuitEvent, verifique se o player está na HashSet, se sim, envie a mensagem que ele foi kickado, se não, mande a mensagem que ele saiu (E depois remova o player da HashSet).
  9. MrPowerGamerBR's postagem in [Resolvido] [Dúvida] - Checando se o player é original was marked as the answer   
    Bela página de Erro 404 ai fera...
     
    Não sei o que vocês estão fazendo, alguns métodos aí verificam se o cara usa Minecraft original, mas ele quer para um plugin de login, verificar externamente não vai ajudar.
     
    Se vocês forem usar esses métodos que vocês passaram, qualquer um vai poder logar com um nick original, mesmo tendo Minecraft Pirata.
     
    Quer fazer um sistema de login igual ao AutoIn? Então siga quem sabe.
     
    Você vai precisar alterar o server.properties para deixar o online-mode em true, após isto, use o AsyncPlayerPreLoginEvent para trocar o LoginResult para ALLOWED.
    e.setLoginResult(Result.ALLOWED); Pronto, caso resolvido, você ainda terá que alterar o UUIDs dos players para não bugar usando Reflection.
     
    Para você fazer logins apenas para usuários piratas, você terá que comparar o Result do evento (e.getLoginResult()) para verificar se ele foi kickado por não estar autenticado, se ele está tentando logar sem estar autenticado, coloque ele em uma lista e altere o resultado para Result.ALLOWED.
     
    Eu não testei, mas eu tenho certeza que é assim que o AutoIn funciona, se estiver errado só me falar que eu irei verificar.
  10. MrPowerGamerBR's postagem in [Resolvido] [Duvida] Salvar inventario em um arquivo was marked as the answer   
    https://gist.github.com/4235b0c74ac90b55a4a1dbc14b473803
  11. MrPowerGamerBR's postagem in [Resolvido] [Alguem que entenda de Scheduler] so ler was marked as the answer   
    A JAR da sua 1.5.2 está bugada, troque para outra.
     
    (Tente usar o seu plugin em qualquer outra versão mais nova, ele não irá bugar)
  12. MrPowerGamerBR's postagem in [Resolvido] Duvida was marked as the answer   
    Falando qualquer coisa já que eu ajudei pela Shoutbox.
     
    Estava faltando um return true após enviar a mensagem do argumento inválido.
  13. MrPowerGamerBR's postagem in [Entregue] imagem 64x64 was marked as the answer   
    Ficou mais ou menos.

  14. MrPowerGamerBR's postagem in [Resolvido] Porque não esta funcionando ? was marked as the answer   
    Você escreve §4[Reparar] na placa e verifica [Reparação] no código para reparar...
     
     
    ...ok né.
  15. MrPowerGamerBR's postagem in [Resolvido] Ajuda delay was marked as the answer   
    Tá sim, ele remove após 20 * número que você colocou na config.
  16. MrPowerGamerBR's postagem in [Resolvido] Ajuda Simples was marked as the answer   
    Se você sabe como curar outro player, então você deveria saber como manda a mensagem para o outro player...
     
    Só usar .sendMessage() com o outro player com a mensagem arg0.getDisplayName() + " te curou com orgulho e carinho"
  17. MrPowerGamerBR's postagem in [Resolvido] Setar um BlockType de x, y, z até x, y, z was marked as the answer   
    Os caras ficam falando para usar as coisas mas não mandam nenhum exemplo...
    public static void setBlockInDistance(Location loc1, Location loc2, Material material, byte data) {         int minX = Math.min(loc1.getBlockX(), loc2.getBlockX());         int minY = Math.min(loc1.getBlockY(), loc2.getBlockY());         int minZ = Math.min(loc1.getBlockZ(), loc2.getBlockZ());         int maxX = Math.max(loc1.getBlockX(), loc2.getBlockX());         int maxY = Math.max(loc1.getBlockY(), loc2.getBlockY());         int maxZ = Math.max(loc1.getBlockZ(), loc2.getBlockZ());         for(int x = minX; x <= maxX; x++){             for(int y = minY; y <= maxY; y++){                 for(int z = minZ; z <= maxZ; z++){                     Block block = loc1.getWorld().getBlockAt(x, y, z);                     block.setType(material);                     block.setData(data);                 }             }         }     }
  18. MrPowerGamerBR's postagem in [Resolvido] ScoreBoard'S was marked as the answer   
    Scoreboard score = p.getScoreboard();                             for (Objective obj2 : score.getObjectives()) {                                 obj2.unregister();                             }                             Objective obj = score.registerNewObjective("meuspontos", "dummy");                             obj.setDisplayName("§4Sparkly§bPower");                             obj.setDisplaySlot(DisplaySlot.SIDEBAR);                             obj.getScore("§bOnline:").setScore(50);                             Objective obj2 = score.registerNewObjective("outrospontos", "health");                             obj2.setDisplaySlot(DisplaySlot.BELOW_NAME);                             obj2.setDisplayName("/ 10"); poof, mágica.
     
    O problema que as vezes a vida da scoreboard em baixo do nome não atualiza (mostra "0")
  19. MrPowerGamerBR's postagem in [Resolvido] Duvida simples! was marked as the answer   
    public void tc(PlayerDeathEvent e){
            if (e.getEntity() instanceof Player && e.getEntity().getKiller() instanceof Player){
                for (Player all : Bukkit.getOnlinePlayers()){
                    Player morreu = (Player)e.getEntity();
                    Player matou = (Player)e.getEntity().getKiller();
                    Bukkit.broadcastMessage(matou.getName() + " matou " + morreu.getName());
                }
            }
        }

  20. MrPowerGamerBR's postagem in [Entregue] [Plugins Pedido] Skquery e SkPower sem erro para 1.5.2 was marked as the answer   
    Você não está usando a versão mais recente do Skript, baixe a v2.1.2 e use no seu Servidor 1.5.2 para fazer os addons funcionarem.
  21. MrPowerGamerBR's postagem in [Resolvido] Event chestshop api was marked as the answer   
    PreTransactionEvent
    public void aoComprar(PreTransactionEvent e) { Bukkit.broadcastMessage("Alguém tentou comprar em uma Loja do ChestShop!"); } Você pode pegar a placa do evento usando e.getSign();
     
    (Lembrando que é necessário colocar o ChestShop como dependência)
  22. MrPowerGamerBR's postagem in [Resolvido] Erro no kick player was marked as the answer   
    Esse seu código me deu ebola.
    public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {         if (command.getName().equalsIgnoreCase("itens"))         {             for(String b : getConfig().getStringList("Itens")) {                 sender.sendMessage((b).replaceAll("&","§").replace(">", "»"));                 return true;             }         }         if (command.getName().equalsIgnoreCase("eventos"))         {             if (sender instanceof Player) {                 Player p = (Player) sender;                 p.kickPlayer("Motivo");                 return true;             } sender.sendMessage("Somente Players podem escrever este comando!"); return true;         }         return false;     }
  23. MrPowerGamerBR's postagem in [Resolvido] Definição de skin! was marked as the answer   
    Então não tem jeito, só usando o Lib's Disguises, mas aí você também vai trocar o nome dele.
  24. MrPowerGamerBR's postagem in [Entregue] > Pedido < > Banner para servidor Minecraft < > .GIF < was marked as the answer   
    https://dl.dropboxusercontent.com/u/93092749/Banners%20Animados%20para%20AfterEffects.zip
     
    "forge-created-by-mightykitten.psd", só abrir o Photoshop CS6 e editar.
     
     
    Estou ocupado agora, preciso estudar e preciso acabar meu blog logo... Se você tem o Photoshop, só baixar o arquivo que eu passei ali em cima.
×
×
  • Criar Novo...