Updated to 1.18.1
This commit is contained in:
parent
583cb591ca
commit
1b5592cc06
4 changed files with 25 additions and 23 deletions
|
@ -42,7 +42,7 @@ public final class MCTPAudio extends JavaPlugin {
|
|||
saveConfig();
|
||||
|
||||
Bukkit.getLogger().info("[MCTPAudio] Connecting with socket...");
|
||||
client = new Client("ws://81.16.136.67:25564");
|
||||
client = new Client("ws://5.9.170.139:25564");
|
||||
client.connect();
|
||||
|
||||
Bukkit.getLogger().info("[MCTPAudio] Loading commands and events...");
|
||||
|
|
|
@ -30,9 +30,11 @@ public class SongList<E> extends ArrayList<E> {
|
|||
/**
|
||||
* Get a random item from this List
|
||||
*
|
||||
* @return The random element
|
||||
* @return The random element, or null if empty
|
||||
*/
|
||||
public E getRandom() {
|
||||
int size = size();
|
||||
if (size <= 0) return null;
|
||||
return get(r.nextInt(size()));
|
||||
}
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ import java.io.IOException;
|
|||
*/
|
||||
|
||||
public class Playlist {
|
||||
private SongList<String> playList = new SongList<>();
|
||||
private final SongList<String> playList = new SongList<>();
|
||||
private final SongList<String> playedList = new SongList<>();
|
||||
|
||||
private boolean running = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue