Warn server owners about use of out-of-date Worldguard

closes #162
This commit is contained in:
RoboMWM 2017-07-21 23:24:52 -07:00
parent 4cb2abefeb
commit d079fcf379

View File

@ -26,7 +26,13 @@ class WorldGuardWrapper
public boolean canBuild(Location lesserCorner, Location greaterCorner, Player creatingPlayer)
{
World world = lesserCorner.getWorld();
if (worldGuard == null)
{
GriefPrevention.AddLogEntry("WorldGuard is out of date. Please update or remove WorldGuard.");
return true;
}
if(new RegionPermissionModel(this.worldGuard, creatingPlayer).mayIgnoreRegionProtection(world)) return true;
RegionManager manager = this.worldGuard.getRegionManager(world);