mavenization
gitignore added maven target/ and intellij project stuff simplified a return statement in PluginPlayerListener added TODO in LocationSerializer (creating a world should not be done there)
This commit is contained in:
@ -72,14 +72,6 @@ public class PluginPlayerListener extends BaseLocationListener implements Listen
|
||||
|
||||
|
||||
protected boolean hasPermission(Player player) {
|
||||
if (player.hasPermission(Plugin.permissionUse)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (player.hasPermission(Plugin.permissionAll)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
return player.hasPermission(Plugin.permissionUse) || player.hasPermission(Plugin.permissionAll);
|
||||
}
|
||||
}
|
||||
|
@ -24,7 +24,10 @@ public class LocationSerializer
|
||||
protected static World getWorld(String name)
|
||||
{
|
||||
World world = Plugin.instance.getServer().getWorld(name);
|
||||
|
||||
|
||||
// TODO: Creating a world silently in the background is not a good thing I think. No one expects a Gate
|
||||
// Plugin to do that. It would be better to handle gates which point to non-existing worlds safely (not
|
||||
// teleporting at all)
|
||||
if (world == null) {
|
||||
world = Plugin.instance.getServer().createWorld(new WorldCreator(name).environment(Environment.NORMAL));
|
||||
}
|
||||
|
@ -3,7 +3,7 @@ version: 1.1.1
|
||||
description: A plugin to create gates for fast traveling.
|
||||
author: tomco
|
||||
authors: [oloflarsson, locutus, DrAgonmoray, s1m0ne, tomco]
|
||||
website: http://www.craftinc.de/blog/?p=255
|
||||
website: http://www.craftinc.de/ancient-gates/
|
||||
|
||||
main: org.mcteam.ancientgates.Plugin
|
||||
database: false
|
||||
@ -25,6 +25,4 @@ permissions:
|
||||
ancientgates.use:
|
||||
description: Allows you to use open gates.
|
||||
acientgates.manage:
|
||||
description: Gives access to commands manipulating gates.
|
||||
|
||||
|
||||
description: Gives access to commands manipulating gates.
|
Reference in New Issue
Block a user