https://github.com/wesjd/worldlib
Some old world management system. I wouldn't recommend using this.
https://github.com/wesjd/worldlib
Last synced: 11 months ago
JSON representation
Some old world management system. I wouldn't recommend using this.
- Host: GitHub
- URL: https://github.com/wesjd/worldlib
- Owner: WesJD
- License: mit
- Created: 2016-02-20T05:40:23.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-05-08T17:24:56.000Z (about 10 years ago)
- Last Synced: 2025-02-18T01:37:25.088Z (over 1 year ago)
- Language: Java
- Homepage:
- Size: 26.4 KB
- Stars: 0
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# WorldLib
A world management system for [Bukkit](http://bukkit.org/).
## How to Use
### Registration
```java
public class MyPlugin extends JavaPlugin {
@Override
public void onEnable() {
WorldLib.getInstance().enable(this);
}
@Override
public void onDisable() {
WorldLib.getInstance().disable();
}
//example methods
{
WorldLib.getInstance().getManager().createWorld(WorldType.FLAT, "MyFlatWorld");
WorldLib.getInstance().getManager().loadWorld("MyFlatWorld");
WorldLib.getInstance().getManager().unloadWorld("MyFlatWorld");
WorldLib.getInstance().getManager().deleteWorld("MtFlatWorld");
}
}
```
Simple enough, eh? Call `WorldLib#enable(JavaPlugin)` with your main class as the parameter to enable the system. When you're done with it (really when the server shuts down), call `WorldLib#disable()`. This will save worlds, etc.
### Usage
```java
//example methods
{
WorldLib.getInstance().getManager().createWorld(WorldType.FLAT, "MyFlatWorld");
WorldLib.getInstance().getManager().loadWorld("MyFlatWorld");
WorldLib.getInstance().getManager().unloadWorld("MyFlatWorld");
WorldLib.getInstance().getManager().deleteWorld("MtFlatWorld");
}
```
All of these methods are self explanatory. Each one takes a string of the world name as the parameter. These do not need to be called like this either, it is simply showing the methods of WorldManager. You can attempt a creation, deletion, etc of a world as many times as you would like, but it will do nothing if a world with that name already exists.
### Importing
Either put the source into your project or shade it in with Maven.
```xml
me.wes
worldlib
1.0-SNAPSHOT
...
buildstatic-repo
BuildStatic Repository
http://serv.buildstatic.net/maven-repo
...
```
alternatively, you can download a jar [here](http://ci.buildstatic.net/job/WorldLib/).
Hope you use this well.
## Licensing
This project is registered under the [MIT License](LICENSE.txt).