mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-11-25 20:16:03 +01:00
- added .gitignore to ignore eclipse/etc build files
- events are now registered in onEnable()
This commit is contained in:
parent
2b55f3407c
commit
d0ddc7c271
13
.gitignore
vendored
Normal file
13
.gitignore
vendored
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
/bin
|
||||||
|
/build
|
||||||
|
/dist
|
||||||
|
/release
|
||||||
|
/store
|
||||||
|
/test
|
||||||
|
/lib/Bukkit.jar
|
||||||
|
/lib/Craftbukkit.jar
|
||||||
|
/lib/truezip.jar
|
||||||
|
/lib/WorldEdit.jar
|
||||||
|
.classpath
|
||||||
|
.project
|
||||||
|
manifest.mf
|
@ -77,9 +77,9 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|||||||
new WorldGuardBlockListener(this);
|
new WorldGuardBlockListener(this);
|
||||||
private final WorldGuardEntityListener entityListener =
|
private final WorldGuardEntityListener entityListener =
|
||||||
new WorldGuardEntityListener(this);
|
new WorldGuardEntityListener(this);
|
||||||
private final PermissionsResolverServerListener permsListener;
|
|
||||||
|
private PermissionsResolverServerListener permsListener;
|
||||||
private final PermissionsResolverManager perms;
|
private PermissionsResolverManager perms;
|
||||||
|
|
||||||
Blacklist blacklist;
|
Blacklist blacklist;
|
||||||
|
|
||||||
@ -148,19 +148,27 @@ public class WorldGuardPlugin extends JavaPlugin {
|
|||||||
*/
|
*/
|
||||||
public WorldGuardPlugin(PluginLoader pluginLoader, Server instance,
|
public WorldGuardPlugin(PluginLoader pluginLoader, Server instance,
|
||||||
PluginDescriptionFile desc, File folder, File plugin, ClassLoader cLoader) {
|
PluginDescriptionFile desc, File folder, File plugin, ClassLoader cLoader) {
|
||||||
super(pluginLoader, instance, desc, folder, plugin, cLoader);
|
|
||||||
|
|
||||||
logger.info("WorldGuard " + desc.getVersion() + " loaded.");
|
logger.info("WorldGuard " + desc.getVersion() + " loaded.");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called on plugin enable.
|
||||||
|
*/
|
||||||
|
public void onEnable() {
|
||||||
|
PluginDescriptionFile desc = this.getDescription();
|
||||||
|
File folder = this.getDataFolder();
|
||||||
|
|
||||||
folder.mkdirs();
|
folder.mkdirs();
|
||||||
|
|
||||||
createDefaultConfiguration("config.yml");
|
createDefaultConfiguration("config.yml");
|
||||||
createDefaultConfiguration("blacklist.txt");
|
createDefaultConfiguration("blacklist.txt");
|
||||||
|
|
||||||
regionLoader = new CSVDatabase(new File(folder, "regions.txt"));
|
regionLoader = new CSVDatabase(new File(folder, "regions.txt"));
|
||||||
perms = new PermissionsResolverManager(getConfiguration(), getServer(),
|
perms = new PermissionsResolverManager(getConfiguration(), getServer(),
|
||||||
"WorldGuard", logger);
|
"WorldGuard", logger);
|
||||||
permsListener = new PermissionsResolverServerListener(perms);
|
permsListener = new PermissionsResolverServerListener(perms);
|
||||||
|
|
||||||
loadConfiguration();
|
loadConfiguration();
|
||||||
postReload();
|
postReload();
|
||||||
registerEvents();
|
registerEvents();
|
||||||
@ -173,18 +181,15 @@ public WorldGuardPlugin(PluginLoader pluginLoader, Server instance,
|
|||||||
Logger.getLogger("Minecraft").setFilter(null);
|
Logger.getLogger("Minecraft").setFilter(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
logger.info("WorldGuard " + desc.getVersion() + " enabled.");
|
||||||
* Called on plugin enable.
|
|
||||||
*/
|
|
||||||
public void onEnable() {
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called on plugin disable.
|
* Called on plugin disable.
|
||||||
*/
|
*/
|
||||||
public void onDisable() {
|
public void onDisable() {
|
||||||
|
logger.info("WorldGuard " + this.getDescription().getVersion() + " disabled.");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user