You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -38,11 +44,11 @@ public void onPlaceInject(BlockPos pos, World world, PlayerEntity player, ItemSt
38
44
name = Text.translatable(blockTranslationKey).getString();
39
45
}
40
46
markerManager.addMarker(bannerBlockEntity, name);
41
-
if (configManager.getBoolConfig("notifyPlayerOnMarkerAdd"))
47
+
if (configManager.getBoolConfig("notifyPlayerOnMarkerAdd") && player != null)
42
48
player.sendMessage(Text.literal("[BlueMap Banners] You added a marker to the ").append(Text.literal("web map").setStyle(Style.EMPTY.withClickEvent(newClickEvent.OpenUrl(URI.create(ConfigManager.getInstance().getConfig("bluemapUrl")))).withUnderline(true))).append(Text.of(".")), false);
43
49
}
44
50
} else {
45
-
if (configManager.getBoolConfig("notifyPlayerOnBannerPlace")) {
51
+
if (configManager.getBoolConfig("notifyPlayerOnBannerPlace") && player != null) {
46
52
player.sendMessage(Text.literal("[BlueMap Banners] Use a map item on the banner to add a marker on the ").append(Text.literal("web map").setStyle(Style.EMPTY.withClickEvent(newClickEvent.OpenUrl(URI.create(ConfigManager.getInstance().getConfig("bluemapUrl")))).withUnderline(true))).append(Text.of(".")), false);
0 commit comments