LobbyAPI
What is LobbyAPI
LobbyAPI was created to manage multiple worlds and allow players to teleport to those worlds using user friendly menu, while being able to be fully configurable.Just by using the commands /lobby or /hub, the player has access to all worlds specified in the menu, where when they click on the block the represents a world they are teleported to location given to that world. LobbyAPI has tons of configurable methods to change the color of the block in the menu, the amount of that block, what spot it is located, and the description of the world, who can see or go to a world, along with the methods for how the world will interact with other worlds.
How to create and manage worlds
If you a re new to LobbyAPI, you can find a guide how to set up worlds at this link:
https://dev.bukkit.org/projects/lobbyapi/pages/events/basic-command-tutorial
Features
- Allows players to teleport from world to world.
- Menu is fully customizable
- Shows all players in given world
- Allows players to teleport from Server to Server (for bungee servers only).
- Allows other plugins to access when a player teleports to a new world or clicks on a new world in the menu.
- Works on all versions of Bukkit
- Plugin support LobbyAPI is just the back-bone for the plugins that will add the worlds. All that is needed to add a world to the menu will be under Developer Information.
Icon Customization is here!
Now you can easily customize the materials, description, and other attributes for each world registered!
Commands
/Lobby | Opens up the WorldMenu |
/Hub | Opens up the WorldMenu |
/LobbyApi | Allows you to change some properties of LobbyAPI |
/LobbyApi addWorld [world] [slot] [x][y][z]..... | Adds a world to the LobbyAPI menu |
/LobbyApi removeWorld [world] | Removes a world to the LobbyAPI menu |
/LobbyApi addServer [server-name] [slot] | Adds a server to the LobbyAPI menu |
/LobbyApi removeServer [server-name] | Removes a server to the LobbyAPI menu |
/LobbyApi listServers | Shows a list for all the servers |
/LobbyApi listWorlds |
Shows a list for all the worlds |
/LobbyApi setDefaultWeather [world] [weather] | Sets the default weather for a world. Choices are NORMAL, NO_RAIN, and ALWAYS_RAINING |
/LobbyApi addJoiningCommand [world] [command] | Adds a command that should be sent when a player joins that world. |
/LobbyApi removeJoiningCommand [world] [command id] | Removes a command that should be sent when a player joins that world. |
/LobbyApi listJoiningCommands [world] | Lists all the commands that are sent when a player joins that world. |
/LobbyApi listJoiningCommands [world] | Lists all the commands that are sent when a player joins that world. |
(There are a few more commands, but I've had issues recreating the table :p):
/LobbyAPI generateNetherAndEndFor", "Generates a nether and end world for the world"
/LobbyAPI setMainLobby", "Changes the default spawn world"
/LobbyAPI removeMainLobby", "Removes default spawn world"
/LobbyAPI setMaterial", "Sets the material icon for a world"
/LobbyAPI setDisplayName", "Changes a display name for a world."
/LobbyAPI setDescription", "Sets the description for a world"
/LobbyAPI hideWorld", "Hides a world from the menu."
/LobbyAPI showWorld", "Shows the world from the menu, if previously hidden"
/LobbyAPI setWorldSelector", "Sets the word selector to be the item in the sender's hand"
/LobbyAPI removeWorldSelector", "removes word selector"
/LobbyAPI setGamemode", "Sets the description for a world"
/LobbyAPI changeSpawn", "Changes the spawn location for a world"
/LobbyAPI version", "Gets the version of the plugin"
/LobbyAPI setvoidlooping", "Enables or disables teleporting players to spawn if they are in the void"
/LobbyAPI setdisablehealthandhunger", "Enables or disables health or hunger changes for worlds"
/LobbyAPI setlocationsaving", "Enables or disables location saving when a player leaves the world"
/LobbyAPI setcanuseportals", "Enables or disables portals for certain worlds."
/LobbyAPI addDefaultItem", "Adds the item in your hand to the list of default items."
/LobbyAPI removeDefaultItem", "Adds the item in your hand to the list of default items."
/LobbyAPI listDefaultItems", "Adds the item in your hand to the list of default items."
/LobbyAPI addDecor", "Adds a decor item to the hub menu"
/LobbyAPI removeDecor", "Removes a decor item."
/LobbyAPI toggleWhitelist", "Toggles whether the world is restricted to only certain players"
/LobbyAPI addToWhitelist", "Adds a player to a world's whitelist"
/LobbyAPI removeFromWhitelist", "Adds a player to a world's whitelist"
/LobbyAPI listWhitelist", "Adds a player to a world's whitelist"
/LobbyAPI goto", "Teleports the player to the spawn of a world"
Permissions:
- lobbyapi.*
- ---Gives access to all lobbyapi features
- lobbyapi.user
- --Gives all commands that users should have. If you do not know what permissions to give to your players, just give them this.
- lobbyapi.commands
- --Only gives access to commands
- lobbyapi.hub
- --Gives access to the /hub commands.
- lobbyapi.bypassworldlimits
- --Gives players the ability to join worlds that are private, or have gone over the player limit
Dependencies and Compatibility
LobbyAPI does not depend on any other plugin, and should work with all other plugins. If you receive any errors from my plugin or features or not enabled for you, please make a comment or ticket of this page.
Developer Information
If you want to register a world through a plugin, use the guide HERE . Call this method in onEnable method to register worlds when the plugin loads.
To add a BungeeServer to the menu, all you need is this line: LobbyAPI.registerBungeeServer(String bungeeServersName, Description, WoolColor);
How to Install
- Drop this plugin into you plugins folder
- Find/Create a plugin that will allow you get to your world
- Restart your server
This plugin uses bStats:
bStats is a metrics service that allows me to to see how many servers use my plugins, how many players they have, and which countries use my plugin the most. All information is anonymized, so no information can be directly linked to you, and instead is added to the average of all severs that use the plugin.
This is the only thing inside my config file after refreshing twice like you suggested.
Now, when I try add a world, I get a notification saying "This world does not exist".
I have just released version 3.7.19. The issue you are having is the plugin does not see that the world exist (even though it does). I modified some lines so it should always allow worlds, even if they are not loaded.
Again, reload the server twice for the update to be applied.
Okay. I'll update it when it's loaded onto here.
Edit. Found a new bug that may throw some errors. Wait till I release another update.
Released a new update. For some reason, the XYZ and worldname were all getting defaulted to the X value. Fixed in 3.7.20.
So far, so good. The only issue I'm having is that when I /reload or restart, everything in the config file disappears and it looks like this:
Thank you for working hard on the plugin and fixing
I have 4 worlds that I am wanting to add into LobbyAPI. I don't understand how to get them to show up in the bars.
Is there a tutorial anywhere out there for this specific plugin? I can't seem to find one.
Yes. You can find a basic tutorial either in the "pages" tab for this project, or by going to the following link:
https://dev.bukkit.org/projects/lobbyapi/pages/events/basic-command-tutorial
I personally think this is a great concept, and I am gonna test it and see how it works out. From what I can see this plugin is awesome and everyone wants to know if you can add more features. That USUALLY means you're a great Java Coder! Good Work, Keep it Up!
@ZombieStryker Can you please add this: when you click one of the items, once you teleport to that server, it runs a specific command.
@Sn0wZin
I will try to add this to the main plugin. It should be available soon.
Add it is possible that the example item information getNum Players () / getMaxPlayers ()
for each World
Sorry, to use google translator.
Thanks.
Example setting, if possible to do it in the lobby api
getNumPlayers() / getMaxPlayers()
Sorry, to use google translator.
Tickets have now been added. If there are any more problems, report it there.
@JBuscus101
This is not a problem with my plugin, but with the plugin "PWP" as seen here: us.Myles.PWP.TransparentListeners.PerWorldPluginLoader$1.execute(PerWorldPluginLoader.java:122)
As much as I would want to fix this problem, the problem is that "PWP" is interfering with LobbyAPI.
Could not pass event InventoryClickEvent to LobbyAPI v3.6.4 org.bukkit.event.EventException at us.Myles.PWP.TransparentListeners.PerWorldPluginLoader$1.execute(PerWorldPluginLoader.java:122) [?:?] at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at org.bukkit.plugin.TimedRegisteredListener.callEvent(TimedRegisteredListener.java:36) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at us.Myles.PWP.TransparentListeners.PWPTimedRegisteredListener.callEvent(PWPTimedRegisteredListener.java:30) [PerWorldPlugins_1.3.jar:?] at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:502) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:487) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.PlayerConnection.a(PlayerConnection.java:1603) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.PacketPlayInWindowClick.a(SourceFile:31) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.PacketPlayInWindowClick.a(SourceFile:9) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.PlayerConnectionUtils$1.run(SourceFile:13) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_45] at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_45] at net.minecraft.server.v1_8_R3.SystemUtils.a(SystemUtils.java:19) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:714) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:374) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:653) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:556) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at java.lang.Thread.run(Unknown Source) [?:1.8.0_45] Caused by: java.lang.NullPointerException at org.bukkit.craftbukkit.v1_8_R3.entity.CraftPlayer.teleport(CraftPlayer.java:460) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at org.bukkit.craftbukkit.v1_8_R3.entity.CraftEntity.teleport(CraftEntity.java:223) [spigot-1.8.7.jar:git-Spigot-6d16e64-87b9f46] at com.Zombie_Striker.me.L.MainLobby.teleport(MainLobby.java:544) [?:?] at com.Zombie_Striker.me.L.MainLobby.onSelect(MainLobby.java:520) [?:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [?:1.8.0_45] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [?:1.8.0_45] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [?:1.8.0_45] at java.lang.reflect.Method.invoke(Unknown Source) [?:1.8.0_45] at us.Myles.PWP.TransparentListeners.PerWorldPluginLoader$1.execute(PerWorldPluginLoader.java:120) [?:?] ... 17 more
@alexdidou5
I really do not understand what you mean. LobbyAPI does not have the command /survivalgames. How would right clicking anything send a command, since you have to type in a command in order to send one?
Please elaborate on what you mean.
pls add command per world example right click on world 1 use the command /survivalgames join 1
@Gabi78
The new update is out. Look at the Dev section for how to add a world.
The best place to register the world would be in a method that runs right after LobbyAPI is enabled. As for the tutorial, I will be adding a developers section which will explain what you would need to do.
[EDIT]: Due to a planning failure, the worlds don't update after they are registered. Adding a patch for that. Check in later download version 2.6.3.