I recently downloaded a plugin named "LocalChat" and it does exactly what it says however one main issue I have is that disabled player's that are within an enabled player's radius are able to hear their local chat messages. I was wondering what code would need to be added to make it so that disabled players that are within an enabled player's radius are not able to hear their messages unless they are in the local channel. Here is the plugin src: (LocalChat src)
Code: int radius = 10; List<Player> players = new ArrayList<Player>(); for (Entity entity : player.getNearbyEntities(radius, radius, radius)) { if (entity instanceof Player) players.add((Player) entity); } for (Player otherPlayer : players) { otherPlayer.sendMessage(""/*Your message here*/); }
FisheyLP Super spoonfeed... Besides, I don't think OP is coding a plugin. SuperMonis You aren't coding this plugin, right? You just want a feature for the plugin, correct? If so, you should ask the developer on the project page. If you are trying to add something new to the plugin, you will have to look into any sort of API available for the plugin so you can hook into it.
The developer for this plugin has either given up on this plugin or become inactive because the plugin has not been updated for 2 years. As for the API I have not been able to find anything. I was initially coding a plugin but there were lots of errors and this plugin works fine, I only need to fix one thing in this plugin.