If attempting to get MarkerAPI from DynMap results in an NPE (like version 0.35 if DynMap's Spout integration fails), it will no longer prevent WorldBorder from continuing to load.

This commit is contained in:
Brettflan 2012-03-29 07:52:11 -05:00
parent 247e9052c2
commit c4127c35ad
1 changed files with 10 additions and 2 deletions

View File

@ -57,8 +57,16 @@ public class DynMapFeatures
return;
}
markApi = api.getMarkerAPI();
if (markApi == null) return;
try
{
markApi = api.getMarkerAPI();
if (markApi == null) return;
}
catch (NullPointerException ex)
{
Config.LogConfig("DynMap is present, but a NullPointerException was encountered while attempting to integrate. Border display disabled.");
return;
}
// go ahead and show borders for all worlds
showAllBorders();