mirror of
https://github.com/YouHaveTrouble/YardWatch.git
synced 2026-05-12 06:26:59 +00:00
e516cf2ec6
Introduced a new plugin, YardWatch, implemented with WorldGuard for protection. The plugin checks if WorldGuard is enabled and regulates breaking blocks, placing blocks, and interactions based on WorldGuard's build and interact flags. Also included are updated .gitignore and pom.xml files to manage the project setup.
21 lines
566 B
Java
21 lines
566 B
Java
package me.youhavetrouble.yardwatch;
|
|
|
|
import me.youhavetrouble.yardwatch.hooks.WorldGuardProtection;
|
|
import org.bukkit.plugin.ServicePriority;
|
|
import org.bukkit.plugin.java.JavaPlugin;
|
|
|
|
public final class YardWatch extends JavaPlugin {
|
|
|
|
@Override
|
|
public void onEnable() {
|
|
|
|
if (getServer().getPluginManager().isPluginEnabled("WorldGuard")) {
|
|
getServer().getServicesManager().register(
|
|
Protection.class, new WorldGuardProtection(this), this, ServicePriority.Normal
|
|
);
|
|
}
|
|
|
|
|
|
}
|
|
}
|