mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-04-18 06:10:16 +00:00
create pipeline BiomeDelegate
This commit is contained in:
@@ -0,0 +1,23 @@
|
|||||||
|
package com.dfsek.terra.addons.biome.pipeline.api;
|
||||||
|
|
||||||
|
import com.dfsek.terra.api.util.StringIdentifiable;
|
||||||
|
import com.dfsek.terra.api.world.biome.Biome;
|
||||||
|
|
||||||
|
|
||||||
|
public interface BiomeDelegate extends StringIdentifiable {
|
||||||
|
Biome getBiome();
|
||||||
|
|
||||||
|
static BiomeDelegate ephemeral(String id) {
|
||||||
|
return new BiomeDelegate() {
|
||||||
|
@Override
|
||||||
|
public Biome getBiome() {
|
||||||
|
throw new UnsupportedOperationException("Cannot get biome from ephemeral delegate");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getID() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user