Separate surface and underground library marker options
This commit is contained in:
@@ -277,6 +277,8 @@ public final class Settings {
|
|||||||
public boolean autoShrineMarkers = true;
|
public boolean autoShrineMarkers = true;
|
||||||
/** <b>[Server-only]</b> Whether global markers for library ruins are added to antique atlases. */
|
/** <b>[Server-only]</b> Whether global markers for library ruins are added to antique atlases. */
|
||||||
public boolean autoLibraryMarkers = true;
|
public boolean autoLibraryMarkers = true;
|
||||||
|
/** <b>[Server-only]</b> Whether global markers for underground library ruins are added to antique atlases. */
|
||||||
|
public boolean autoUndergroundLibraryMarkers = false;
|
||||||
|
|
||||||
// Synchronised settings. These settings affect both client-side AND server-side code. Changing these locally
|
// Synchronised settings. These settings affect both client-side AND server-side code. Changing these locally
|
||||||
// only has an effect if the local game is the host, i.e. a dedicated server, a LAN host or a singleplayer world.
|
// only has an effect if the local game is the host, i.e. a dedicated server, a LAN host or a singleplayer world.
|
||||||
@@ -1286,6 +1288,14 @@ public final class Settings {
|
|||||||
autoLibraryMarkers = property.getBoolean();
|
autoLibraryMarkers = property.getBoolean();
|
||||||
propOrder.add(property.getName());
|
propOrder.add(property.getName());
|
||||||
|
|
||||||
|
property = config.get(COMPATIBILITY_CATEGORY, "autoPlaceUndergroundLibraryMarkers", false,
|
||||||
|
"Controls whether wizardry automatically places antique atlas markers at the locations of underground library ruins.");
|
||||||
|
property.setLanguageKey("config." + Wizardry.MODID + ".auto_place_underground_library_markers");
|
||||||
|
property.setRequiresMcRestart(true);
|
||||||
|
Wizardry.proxy.setToNamedBooleanEntry(property);
|
||||||
|
autoUndergroundLibraryMarkers = property.getBoolean();
|
||||||
|
propOrder.add(property.getName());
|
||||||
|
|
||||||
config.setCategoryPropertyOrder(COMPATIBILITY_CATEGORY, propOrder);
|
config.setCategoryPropertyOrder(COMPATIBILITY_CATEGORY, propOrder);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -68,8 +68,8 @@ public class WizardryAntiqueAtlasIntegration {
|
|||||||
|
|
||||||
/** Places a global library ruins marker in all antique atlases at the given coordinates in the given world if
|
/** Places a global library ruins marker in all antique atlases at the given coordinates in the given world if
|
||||||
* {@link electroblob.wizardry.Settings#autoLibraryMarkers} is enabled. Server side only! */
|
* {@link electroblob.wizardry.Settings#autoLibraryMarkers} is enabled. Server side only! */
|
||||||
public static void markLibrary(World world, int x, int z){
|
public static void markLibrary(World world, int x, int z, boolean underground){
|
||||||
if(enabled() && Wizardry.settings.autoLibraryMarkers){ // TODO: More granular settings for above/below ground
|
if(enabled() && (underground ? Wizardry.settings.autoUndergroundLibraryMarkers : Wizardry.settings.autoLibraryMarkers)){
|
||||||
AtlasAPI.getMarkerAPI().putGlobalMarker(world, false, LIBRARY_MARKER.toString(), "integration.antiqueatlas.marker." + LIBRARY_MARKER.toString().replace(':', '.'), x, z);
|
AtlasAPI.getMarkerAPI().putGlobalMarker(world, false, LIBRARY_MARKER.toString(), "integration.antiqueatlas.marker." + LIBRARY_MARKER.toString().replace(':', '.'), x, z);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ public class WorldGenLibraryRuins extends WorldGenSurfaceStructure {
|
|||||||
|
|
||||||
template.addBlocksToWorld(world, origin, processor, settings, 2 | 16);
|
template.addBlocksToWorld(world, origin, processor, settings, 2 | 16);
|
||||||
|
|
||||||
WizardryAntiqueAtlasIntegration.markLibrary(world, origin.getX(), origin.getZ());
|
WizardryAntiqueAtlasIntegration.markLibrary(world, origin.getX(), origin.getZ(), false);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ public class WorldGenUndergroundLibraryRuins extends WorldGenUndergroundStructur
|
|||||||
|
|
||||||
template.addBlocksToWorld(world, origin, processor, settings, 2 | 16);
|
template.addBlocksToWorld(world, origin, processor, settings, 2 | 16);
|
||||||
|
|
||||||
WizardryAntiqueAtlasIntegration.markLibrary(world, origin.getX(), origin.getZ());
|
WizardryAntiqueAtlasIntegration.markLibrary(world, origin.getX(), origin.getZ(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1560,7 +1560,9 @@ config.ebwizardry.auto_place_obelisk_markers.tooltip=Controls whether wizardry a
|
|||||||
config.ebwizardry.auto_place_shrine_markers=Auto-Place Shrine Markers
|
config.ebwizardry.auto_place_shrine_markers=Auto-Place Shrine Markers
|
||||||
config.ebwizardry.auto_place_shrine_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of shrines.
|
config.ebwizardry.auto_place_shrine_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of shrines.
|
||||||
config.ebwizardry.auto_place_library_markers=Auto-Place Library Markers
|
config.ebwizardry.auto_place_library_markers=Auto-Place Library Markers
|
||||||
config.ebwizardry.auto_place_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of library ruins.
|
config.ebwizardry.auto_place_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of surface library ruins.
|
||||||
|
config.ebwizardry.auto_place_underground_library_markers=Auto-Place Underground Library Markers
|
||||||
|
config.ebwizardry.auto_place_underground_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of underground library ruins.
|
||||||
|
|
||||||
integration.jei.category.ebwizardry\:arcane_workbench=Arcane Workbench
|
integration.jei.category.ebwizardry\:arcane_workbench=Arcane Workbench
|
||||||
|
|
||||||
|
|||||||
@@ -1560,7 +1560,9 @@ config.ebwizardry.auto_place_obelisk_markers.tooltip=Controls whether wizardry a
|
|||||||
config.ebwizardry.auto_place_shrine_markers=Auto-Place Shrine Markers
|
config.ebwizardry.auto_place_shrine_markers=Auto-Place Shrine Markers
|
||||||
config.ebwizardry.auto_place_shrine_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of shrines.
|
config.ebwizardry.auto_place_shrine_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of shrines.
|
||||||
config.ebwizardry.auto_place_library_markers=Auto-Place Library Markers
|
config.ebwizardry.auto_place_library_markers=Auto-Place Library Markers
|
||||||
config.ebwizardry.auto_place_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of library ruins.
|
config.ebwizardry.auto_place_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of surface library ruins.
|
||||||
|
config.ebwizardry.auto_place_underground_library_markers=Auto-Place Underground Library Markers
|
||||||
|
config.ebwizardry.auto_place_underground_library_markers.tooltip=Controls whether wizardry automatically places antique atlas markers at the locations of underground library ruins.
|
||||||
|
|
||||||
integration.jei.category.ebwizardry\:arcane_workbench=Arcane Workbench
|
integration.jei.category.ebwizardry\:arcane_workbench=Arcane Workbench
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user