Constants interface
Пакет: com.hypixel.hytale.server.worldgen.loader.biome
Файл: com/hypixel/hytale/server/worldgen/loader/biome/CustomBiomeJsonLoader.java
Поля (2)
| Модификаторы | Тип | Имя |
|---|---|---|
|
String |
KEY_CUSTOM_BIOME_GENERATOR |
|
String |
SEED_PREFIX |
Исходный код
Показать/скрыть
class="kw">package com.hypixel.hytale.server.worldgen.loader.biome;
class="kw">import com.google.gson.JsonElement;
class="kw">import com.hypixel.hytale.procedurallib.json.SeedString;
class="kw">import com.hypixel.hytale.server.worldgen.SeedStringResource;
class="kw">import com.hypixel.hytale.server.worldgen.biome.Biome;
class="kw">import com.hypixel.hytale.server.worldgen.biome.CustomBiome;
class="kw">import com.hypixel.hytale.server.worldgen.biome.CustomBiomeGenerator;
class="kw">import com.hypixel.hytale.server.worldgen.loader.context.BiomeFileContext;
class="kw">import java.nio.file.Path;
class="kw">import javax.annotation.Nonnull;
class="kw">import javax.annotation.Nullable;
class="kw">public class CustomBiomeJsonLoader class="kw">extends BiomeJsonLoader {
class="kw">protected class="kw">final Biome[] tileBiomes;
class="kw">public CustomBiomeJsonLoader(@Nonnull SeedString<SeedStringResource> var1, Path var2, JsonElement var3, @Nonnull BiomeFileContext var4, Biome[] var5) {
super(var1.append(String.format("TileBiome-%s", var4.getName())), var2, var3, var4);
this.tileBiomes = var5;
}
@Nonnull
class="kw">public CustomBiome load() {
class="kw">return new CustomBiome(
this.biomeContext.getId(),
this.biomeContext.getName(),
this.loadInterpolation(),
this.loadCustomBiomeGenerator(),
this.loadTerrainHeightThreshold(),
this.loadCoverContainer(),
this.loadLayerContainers(),
this.loadPrefabContainer(),
this.loadTintContainer(),
this.loadEnvironmentContainer(),
this.loadWaterContainer(),
this.loadFadeContainer(),
this.loadHeightmapNoise(),
this.loadColor()
);
}
@Nullable
class="kw">protected CustomBiomeGenerator loadCustomBiomeGenerator() {
CustomBiomeGenerator var1 = null;
if (this.has("CustomBiomeGenerator")) {
var1 = new CustomBiomeGeneratorJsonLoader(this.seed, this.dataFolder, this.get("CustomBiomeGenerator"), this.biomeContext, this.tileBiomes).load();
}
class="kw">return var1;
}
class="kw">public class="kw">interface Constants {
String KEY_CUSTOM_BIOME_GENERATOR = "CustomBiomeGenerator";
String SEED_PREFIX = "TileBiome-%s";
}
}