Quantcast
Channel: BungeeCord Plugin Development
Viewing all 4046 articles
Browse latest View live

Process tellraw's JSON and turn it into a ChatComponent

$
0
0
Sup!
For example, I have a message string:
Code (Text):
{"text":"Just an example","clickEvent":{"action":"suggest_command","value":"/help"}}
And send it as the ChatComponent, keeping all the things like click events, and such.

Solutions?

How to make a togglechat/staffchat plugin?

$
0
0
Hi. I'm new to developing plugins and I'm wondering how to make a togglechat plugin. Since I've never done a toggle plugin, only message plugin, this is what I've got.
Code (Text):

@Override
    public boolean onCommand(CommandSender sender, Command command, String commandLabel, String[] args) {
        String cmd = command.getName();
        if (cmd.equalsIgnoreCase("staffchat")) {
            if (!(sender instanceof Player)) {
                sender.sendMessage(ChatColor.RED.toString() +...
How to make a togglechat/staffchat plugin?

Sending data from Spigot to Bungeecord

$
0
0
How do I send some text information from playable server using spigot to the main Bungeecord server and handle it? I made BungeeCord -> Spigot using pluginMessages: Spigot can send and recieve it, but BungeeCord can only send. Tell me if I'm not right.

Command cooldown 24hours help

$
0
0
Hi guys, I'm making a plugin for my bungeecord server and I want members to use the warn one every 24 hours!
I know what to do but I don't know how!
(add player names to config.yml and the cooldown)
Please help me
Here is the code

Code (Text):
    private void warn(CommandSender sender, String message, List<ServerInfo> servers, boolean prefix) {
        if (servers == null || servers.isEmpty()) {
            for (ProxiedPlayer player : getProxy().getPlayers()) {
                ServerInfo server =...
Command cooldown 24hours help

Path

$
0
0
Hello,
I would like to get "UUID" from the value of "Username".

Code (Text):
Ban: {}
Mute:
  {UUID}:
    Username: {Username}
    Time: {Temps}
  {UUID}:
    Username: {Username}
    Time: {Temps}

Mojang API

$
0
0
Hi !
I would like to get a bit of code if possible from a function to transform a username into uuid with the mojang api (BungeeCord).
I've been looking for a long time and it's starting to piss me off...

BungeeCord Plugin - Problem with Command and Args

$
0
0
Code (Text):
package me.tomerkenis.friends.Commands;


import java.util.ArrayList;
import java.util.List;
import me.tomerkenis.friends.Main;
import net.md_5.bungee.BungeeCord;
import net.md_5.bungee.api.ChatColor;
import net.md_5.bungee.api.CommandSender;
import net.md_5.bungee.api.chat.BaseComponent;
import net.md_5.bungee.api.chat.ComponentBuilder;
import net.md_5.bungee.api.connection.ProxiedPlayer;
import net.md_5.bungee.api.plugin.Command;

public class Friends extends Command {

    public...
BungeeCord Plugin - Problem with Command and Args

Get the player message

$
0
0
Hello guys,

I try to do a bungeecord ban plugin and i want to add a staff chat in it but not with a command (with a prefix like "@" before the message). I tried to do it with the ChatEvent but it was not succefull, is it possible to do it ?

GetLore().equals()

$
0
0
Code (Text):
 
   @EventHandler
   public void onHold(PlayerItemHeldEvent e) {
     
      ItemStack flyingpickaxe = new ItemStack(Material.DIAMOND_PICKAXE, 1);
      ItemMeta flyingpickaxemeta = flyingpickaxe.getItemMeta();
      List<String> flyingpickaxelore = new ArrayList<String>();
      flyingpickaxelore.add(ChatColor.GRAY + "Flight");
      flyingpickaxemeta.setLore(flyingpickaxelore);
      flyingpickaxe.setItemMeta(flyingpickaxemeta);
     
    Player player = e.getPlayer();
    if...
GetLore().equals()

Cancel connection

$
0
0
How can i cancel the connection so that when a user joins the server it gets a kick message,

also when the bungee is not connected to a online spigot server because now i get the message, "" Cannot connect to default server "but i want. this network is under maintenace".

Which event do i need to use and how?

Uploading plugins on all servers

$
0
0
Privet.
I have a bunch of bungee servers. When I release a new version of my plugin I need to go through all the servers and upload the new plugin manually. If someone has already encountered such a problem and has a solution (Some script for example), I would be very happy if you help me by posting it here.

Also notify me if I'm writing in the wrong section ^^

Universal Plugin NoClassDefFoundError on BungeeCord Side

$
0
0
So I made a Universal plugin that uses a class called MSG.java, in it i have stuff for sending chat messages to both org.bukkit.command.CommandSender and the bungeecord CommandSender also, and it never gave any errors. But suddenly, it gives a Noclassdeffounderror when i try to call the bungeecord methods in it on the bungeecord side, the error is on the bukkit commandsender. I'm not sure why it just happens, I know im not calling the bukkit methods on bungee so it must be compiling the...

Universal Plugin NoClassDefFoundError on BungeeCord Side

Bungeecord Report Cooldown Help

$
0
0
I would like to put cooldown of 1 minute, for player 1 to report again the player 2 my code is below if you can help me how to do this or do it for me, I will be grateful

If you prefer to see the code by hastebin, here it is: https://hastebin.com/akuyopiqek.java

Code (Text):
package Zey.Bungee.Commands;

import net.md_5.bungee.api.plugin.*;
import Zey.Bungee.Main.*;
import net.md_5.bungee.api.connection.*;
import net.md_5.bungee.*;
import net.md_5.bungee.api.*;
import java.util.*;...
Bungeecord Report Cooldown Help

Calling an event in onDisable()

$
0
0
Is this even possible? It doesn't seem to work

Code (Text):
public class BasicPlugin extends JavaPlugin {

    @Override
    public void onEnable() {
       
    }

    @Override
    public void onDisable() {
        Bukkit.getPluginManager().callEvent(new PluginDisablingEvent(this));
    }
}

How do you send a message to all players with a certain permission node?

$
0
0
All I wish to do is send a message to all the online players with a specific permission. This isn't just across one Bukkit server, it'd be across all of the BungeeCord server. If you could help, that'd be great.

How to run async timer task in Bungeecord'a scheduler?

$
0
0
How to run async timer task in Bungeecord'a scheduler like this one in Spigot (.runTaskTimerAsynchronously)?
I am trying to create MySQL query async scheduler to avoid situation with too many running threads.

Thanks for any help :)!

Are Plugin Messaging fast ?

$
0
0
Hi !

I'm coding a big BungeeCord plugin that's managing a lot of thing about players stored in a database.
(About 1 million stored players, 200/250 online players at the same time)

I was thinking about the fatest way to manage players data, as I'm using it on all my servers, why don't I store online player's data recovered from the database in my BungeeCord plugin? It will reduce database access because player's data will be get from the database only at the connection on the proxy, not at...

Are Plugin Messaging fast ?

Bungee Question

$
0
0
Hello, I would to know if there are any way to make a plugin that work on Spigot or Bungee server.

Thanks.

BungeeCord Version not join 1.8

$
0
0
Hi, how can I do login on the server only from 1.9-1.12.2. BungeeCord 1.8-1.12.2, but server support for the Protocol how to restrict the login using 1.8?

Teleport player to coordinates

$
0
0
I have been searching for a solution far and wide but all i've seen is how to teleport a player to a different server. So, how do you teleport someone to coords?
Viewing all 4046 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>