Hello There,
I've recently made an API for custom biomes for SpigotMC. This API is pretty useful for builders / developers to improve their server.
I am working on this everyday and listening to suggestions.
Here's a little snippet of how to create / set a CustomBiome inside BiomesAPI:
Code (Java):
public
final
class Example
extends JavaPlugin
implements Listener
{
@Override
public void onEnable ( ) {
getServer ( ). getPluginManager ( ). registerEvents ( this, this ) ;
CustomBiome biome = CustomBiome. builder ( )
. resourceKey (BiomeResourceKey. of ( "test", "custombiome" ) )
. settings (BiomeSettings. defaultSettings ( ) )
. fogColor ( "#db4929" )
. foliageColor ( "#22c1c8" )
. skyColor ( "#c8227d" )
. waterColor ( "#c82222" )
. waterFogColor ( "#b9de2e" )
. grassColor ( "#40df8b" )
. build ( ) ;
biome. register ( ) ;
}
@EventHandler
public void onBlockBreak (BlockBreakEvent e ) {
CustomBiome biome = BiomeHandler. getBiome (BiomeResourceKey. of ( "test", "custombiome" ) ) ;
if (biome == null ) return ;
Location loc = e. getPlayer ( ). getLocation ( ) ;;
Location loc1 = loc. clone ( ). add ( 100, 50, 100 ) ;
Location loc2 = loc. clone ( ). add ( - 100, - 50, - 100 ) ;
BiomeSetter. of ( ). setRegionBiome (loc1, loc2, biome, true ) ;
}
}
@Override
public void onEnable ( ) {
getServer ( ). getPluginManager ( ). registerEvents ( this, this ) ;
CustomBiome biome = CustomBiome. builder ( )
. resourceKey (BiomeResourceKey. of ( "test", "custombiome" ) )
. settings (BiomeSettings. defaultSettings ( ) )
. fogColor ( "#db4929" )
. foliageColor ( "#22c1c8" )
. skyColor ( "#c8227d" )
. waterColor ( "#c82222" )
. waterFogColor ( "#b9de2e" )
. grassColor ( "#40df8b" )
. build ( ) ;
biome. register ( ) ;
}
@EventHandler
public void onBlockBreak (BlockBreakEvent e ) {
CustomBiome biome = BiomeHandler. getBiome (BiomeResourceKey. of ( "test", "custombiome" ) ) ;
if (biome == null ) return ;
Location loc = e. getPlayer ( ). getLocation ( ) ;;
Location loc1 = loc. clone ( ). add ( 100, 50, 100 ) ;
Location loc2 = loc. clone ( ). add ( - 100, - 50, - 100 ) ;
BiomeSetter. of ( ). setRegionBiome (loc1, loc2, biome, true ) ;
}
}
Here's some images of the API:
Spoiler: Images
Quick facts
- Edition: Minecraft Java
- File type: .jar
- Minecraft versions listed: 1.19, 1.20
- How to install: Install the matching mod loader (Forge, Fabric or NeoForge) for your Minecraft version. → Download the .jar. → Put it in the .minecraft/mods folder and launch that loader profile.
- Where to get it: Opens on Spigot — not every file is mirrored on our own servers.
Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.
BiomesAPI - Custom Biomes is a free Minecraft Java mod. Compatible with Minecraft 1.19, 1.20. Downloaded 301 times (via Spigot). Download it and open it directly in the game.