Tags
Creators
Details
V1.0.2
Compatibility
Changes
Configuration Changes Added Configuration Options: Introduced a new configuration structure in config.yml for water system settings: water-levels: max-water: Maximum water level (default: 100) starting-water: Starting water level for players (default: 100) warning-threshold: Water level threshold for warnings (default: 20) dirty-water-restore: Water restored from drinking dirty water (default: 5) clean-water-restore: Water restored from drinking clean water (default: 20) water-loss: hot-loss: Water loss rate in hot biomes (default: 0.66) cold-loss: Water loss rate in cold biomes (default: 0.16) default-loss: Default water loss rate (default: 0.33) hot-biomes: List of hot biomes (e.g., "DESERT", "SAVANNA", "BADLANDS") cold-biomes: List of cold biomes (e.g., "SNOWY_PLAINS", "ICE_SPIKES", "FROZEN_OCEAN") effects: dirty-water: poison-duration: Duration of poison effect from dirty water (default: 100) poison-strength: Strength of poison effect from dirty water (default: 0) Code Changes Biome Loss Rate Loading:
Added loadBiomeLossRates() method to load biome-specific water loss rates from the configuration. Player Data Management:
Added loadPlayerData(UUID uuid) method to load player data from player.yml. Implemented automatic creation of player data entries if they do not exist, initializing water levels to the starting value from the configuration. Introduced getPlayerConfig() and savePlayerConfig(FileConfiguration playerConfig) methods to handle player data storage in player.yml. Water Level Updates:
Updated the logic in onPlayerDrink(PlayerItemConsumeEvent event) to use configurable values for restoring water levels when consuming dirty or clean water. Dynamic Water Loss:
Updated the updatePlayerThirst(Player player) method to use the loaded biome loss rates, including a default loss rate for unspecified biomes. Removed Hardcoded Values:
Replaced hardcoded values for maximum water, starting water, and restoration amounts with values loaded from the configuration. Updated Player Join Logic:
Modified onPlayerJoin(PlayerJoinEvent event) to load player data upon joining, ensuring that player water levels are initialized correctly. Removed Unused Code:
Removed any code that was not necessary for the new configuration and functionality.
Projects on Modrinth are automatically available through a Maven repository for use with JVM build tools such as Gradle. To learn more about the Modrinth Maven API, click here.
Note: When available, you should use the creator's maven repo instead as it will have transitive dependency information that the Modrinth Maven API does not. You may also end up with duplicate dependencies if you use a mix of Modrinth and non-Modrinth Maven repositories for your dependencies, because the group identifier will be different when served through the Modrinth Maven API.
Maven coordinates:
Version ID:
build.gradle:
repositories {
exclusiveContent {
forRepository {
maven {
name = "Modrinth"
url = "https://api.modrinth.com/maven"
}
}
// forRepositories(fg.repository) // Uncomment when using ForgeGradle
filter {
includeGroup "maven.modrinth"
}
}
}
// Standard Gradle dependency
dependencies {
implementation "maven.modrinth:aqGMe93x:pCaU1kGM"
}
// Legacy Loom dependency
dependencies {
modImplementation "maven.modrinth:aqGMe93x:pCaU1kGM"
}

