Skip to content

Commit

Permalink
Merge pull request #404 from BentoBoxWorld/2.1.3_compatibility
Browse files Browse the repository at this point in the history
2.3.1 compatibility
  • Loading branch information
tastybento authored Nov 9, 2024
2 parents 252fe35 + 0f18232 commit b6740da
Show file tree
Hide file tree
Showing 15 changed files with 1,089 additions and 915 deletions.
16 changes: 8 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,9 @@
</issueManagement>

<distributionManagement>
<snapshotRepository>
<id>codemc-snapshots</id>
<url>https://repo.codemc.org/repository/maven-snapshots</url>
</snapshotRepository>
<repository>
<id>codemc-releases</id>
<url>https://repo.codemc.org/repository/maven-releases</url>
<id>bentoboxworld</id>
<url>https://repo.codemc.org/repository/bentoboxworld/</url>
</repository>
</distributionManagement>

Expand All @@ -58,8 +54,8 @@
<!-- Non-minecraft related dependencies -->
<powermock.version>2.0.9</powermock.version>
<!-- More visible way how to change dependency versions -->
<spigot.version>1.20.4-R0.1-SNAPSHOT</spigot.version>
<bentobox.version>2.5.0-SNAPSHOT</bentobox.version>
<spigot.version>1.21.3-R0.1-SNAPSHOT</spigot.version>
<bentobox.version>2.7.1-SNAPSHOT</bentobox.version>
<level.version>2.6.2</level.version>
<bank.version>1.3.0</bank.version>
<!-- Revision variable removes warning about dynamic version -->
Expand Down Expand Up @@ -133,6 +129,10 @@
<id>minecraft-repo</id>
<url>https://libraries.minecraft.net/</url>
</repository>
<repository>
<id>bentoboxworld</id>
<url>https://repo.codemc.org/repository/bentoboxworld/</url>
</repository>
<repository>
<id>codemc</id>
<url>https://repo.codemc.org/repository/maven-snapshots/</url>
Expand Down
14 changes: 6 additions & 8 deletions src/main/java/world/bentobox/aoneblock/Settings.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@
import org.bukkit.block.Biome;
import org.bukkit.entity.EntityType;

import com.google.common.base.Enums;

import world.bentobox.aoneblock.listeners.BlockListener;
import world.bentobox.bentobox.BentoBox;
import world.bentobox.bentobox.api.configuration.ConfigComment;
Expand Down Expand Up @@ -232,13 +230,13 @@ public class Settings implements WorldSettings {

@ConfigComment("The default biome for the overworld")
@ConfigEntry(path = "world.default-biome")
private Biome defaultBiome = Biome.PLAINS;
private Biome defaultBiome;
@ConfigComment("The default biome for the nether world (this may affect what mobs can spawn)")
@ConfigEntry(path = "world.default-nether-biome")
private Biome defaultNetherBiome = Enums.getIfPresent(Biome.class, "NETHER").or(Enums.getIfPresent(Biome.class, "NETHER_WASTES").or(Biome.BADLANDS));
private Biome defaultNetherBiome;
@ConfigComment("The default biome for the end world (this may affect what mobs can spawn)")
@ConfigEntry(path = "world.default-end-biome")
private Biome defaultEndBiome = Biome.THE_END;
private Biome defaultEndBiome;

@ConfigComment("The maximum number of players a player can ban at any one time in this game mode.")
@ConfigComment("The permission acidisland.ban.maxlimit.X where X is a number can also be used per player")
Expand Down Expand Up @@ -1446,7 +1444,7 @@ public boolean isWaterUnsafe() {
* @return default biome
*/
public Biome getDefaultBiome() {
return defaultBiome;
return defaultBiome == null ? Biome.PLAINS : defaultBiome;
}

/**
Expand Down Expand Up @@ -1891,7 +1889,7 @@ public void setDropOnTop(boolean dropOnTop) {
* @return the defaultNetherBiome
*/
public Biome getDefaultNetherBiome() {
return defaultNetherBiome;
return defaultNetherBiome == null ? Biome.NETHER_WASTES : defaultNetherBiome;
}

/**
Expand All @@ -1905,7 +1903,7 @@ public void setDefaultNetherBiome(Biome defaultNetherBiome) {
* @return the defaultEndBiome
*/
public Biome getDefaultEndBiome() {
return defaultEndBiome;
return defaultEndBiome == null ? Biome.THE_END : defaultEndBiome;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ else if (Material.BEDROCK.equals(island.getCenter().getBlock().getType()) ||
for (double x = 0.0; x <= 1.0; x += 0.5) {
for (double y = 0.0; y <= 1.0; y += 0.5) {
for (double z = 0.0; z < 1.0; z += 0.5) {
island.getWorld().spawnParticle(Particle.REDSTONE, island.getCenter().add(new Vector(x, y, z)),
island.getWorld().spawnParticle(Particle.DUST, island.getCenter().add(new Vector(x, y, z)),
5, 0.1, 0, 0.1, 1, new Particle.DustOptions(BlockProtect.GREEN, 1));
}
}
Expand Down
Loading

0 comments on commit b6740da

Please sign in to comment.