Enhancements, fixes, new texture
This commit is contained in:
parent
86a2459b0f
commit
9a4bfa1698
19 changed files with 131 additions and 4 deletions
|
@ -12,11 +12,9 @@ import net.minecraft.util.Hand;
|
|||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.TypedActionResult;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import ru.betterend.BetterEnd;
|
||||
import ru.betterend.registry.EndItems;
|
||||
import ru.betterend.util.LangUtil;
|
||||
|
||||
import vazkii.patchouli.api.PatchouliAPI;
|
||||
|
||||
public class GuideBook extends PatternedItem {
|
||||
|
|
|
@ -12,6 +12,7 @@ import net.minecraft.world.gen.feature.ConfiguredFeature;
|
|||
import ru.betterend.world.biome.EndBiome;
|
||||
import ru.betterend.world.features.BlueVineFeature;
|
||||
import ru.betterend.world.features.CavePlantFeature;
|
||||
import ru.betterend.world.features.CharniaFeature;
|
||||
import ru.betterend.world.features.CrashedShipFeature;
|
||||
import ru.betterend.world.features.DoublePlantFeature;
|
||||
import ru.betterend.world.features.EndFeature;
|
||||
|
@ -19,6 +20,7 @@ import ru.betterend.world.features.EndLilyFeature;
|
|||
import ru.betterend.world.features.EndLotusFeature;
|
||||
import ru.betterend.world.features.EndLotusLeafFeature;
|
||||
import ru.betterend.world.features.HydraluxFeature;
|
||||
import ru.betterend.world.features.MengerSpongeFeature;
|
||||
import ru.betterend.world.features.SinglePlantFeature;
|
||||
import ru.betterend.world.features.UnderwaterPlantFeature;
|
||||
import ru.betterend.world.features.VineFeature;
|
||||
|
@ -82,14 +84,21 @@ public class EndFeatures {
|
|||
public static final EndFeature TWISTED_MOSS_WOOD = new EndFeature("twisted_moss_wood", new WallPlantOnLogFeature(EndBlocks.TWISTED_MOSS, 6), 25);
|
||||
|
||||
// Water //
|
||||
public static final EndFeature BUBBLE_CORAL = new EndFeature("bubble_coral", new UnderwaterPlantFeature(EndBlocks.BUBBLE_CORAL, 10), 10);
|
||||
public static final EndFeature BUBBLE_CORAL = new EndFeature("bubble_coral", new UnderwaterPlantFeature(EndBlocks.BUBBLE_CORAL, 6), 10);
|
||||
public static final EndFeature BUBBLE_CORAL_RARE = new EndFeature("bubble_coral_rare", new UnderwaterPlantFeature(EndBlocks.BUBBLE_CORAL, 3), 4);
|
||||
public static final EndFeature END_LILY = new EndFeature("end_lily", new EndLilyFeature(10), 10);
|
||||
public static final EndFeature END_LILY = new EndFeature("end_lily", new EndLilyFeature(6), 10);
|
||||
public static final EndFeature END_LILY_RARE = new EndFeature("end_lily_rare", new EndLilyFeature(3), 4);
|
||||
public static final EndFeature END_LOTUS = new EndFeature("end_lotus", new EndLotusFeature(7), 5);
|
||||
public static final EndFeature END_LOTUS_LEAF = new EndFeature("end_lotus_leaf", new EndLotusLeafFeature(20), 25);
|
||||
public static final EndFeature HYDRALUX = new EndFeature("hydralux", new HydraluxFeature(5), 5);
|
||||
|
||||
public static final EndFeature CHARNIA_RED = new EndFeature("charnia_red", new CharniaFeature(EndBlocks.CHARNIA_RED), 10);
|
||||
public static final EndFeature CHARNIA_PURPLE = new EndFeature("charnia_purple", new CharniaFeature(EndBlocks.CHARNIA_PURPLE), 10);
|
||||
public static final EndFeature CHARNIA_CYAN = new EndFeature("charnia_cyan", new CharniaFeature(EndBlocks.CHARNIA_CYAN), 10);
|
||||
public static final EndFeature CHARNIA_LIGHT_BLUE = new EndFeature("charnia_light_blue", new CharniaFeature(EndBlocks.CHARNIA_LIGHT_BLUE), 10);
|
||||
public static final EndFeature CHARNIA_ORANGE = new EndFeature("charnia_orange", new CharniaFeature(EndBlocks.CHARNIA_ORANGE), 10);
|
||||
public static final EndFeature MENGER_SPONGE = new EndFeature("menger_sponge", new MengerSpongeFeature(5), 1);
|
||||
|
||||
// Terrain //
|
||||
public static final EndFeature END_LAKE = EndFeature.makeLakeFeature("end_lake", new EndLakeFeature(), 4);
|
||||
public static final EndFeature END_LAKE_RARE = EndFeature.makeLakeFeature("end_lake_rare", new EndLakeFeature(), 40);
|
||||
|
|
|
@ -14,6 +14,8 @@ public class BiomeAmberLand extends EndBiome {
|
|||
.setSurface(EndBlocks.AMBER_GRASS)
|
||||
.addFeature(EndFeatures.AMBER_ORE)
|
||||
.addFeature(EndFeatures.END_LAKE_RARE)
|
||||
.addFeature(EndFeatures.CHARNIA_ORANGE)
|
||||
.addFeature(EndFeatures.CHARNIA_RED)
|
||||
.addStructureFeature(ConfiguredStructureFeatures.END_CITY)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 50, 1, 4));
|
||||
}
|
||||
|
|
|
@ -16,6 +16,7 @@ public class BiomeChorusForest extends EndBiome {
|
|||
.setFogColor(87, 26, 87)
|
||||
.setFogDensity(1.5F)
|
||||
.setPlantsColor(122, 45, 122)
|
||||
.setWaterAndFogColor(73, 30, 73)
|
||||
.setSurface(EndBlocks.CHORUS_NYLIUM)
|
||||
.setParticles(ParticleTypes.PORTAL, 0.01F)
|
||||
.setLoop(EndSounds.AMBIENT_CHORUS_FOREST)
|
||||
|
@ -30,6 +31,7 @@ public class BiomeChorusForest extends EndBiome {
|
|||
.addFeature(EndFeatures.CHORUS_GRASS)
|
||||
.addFeature(EndFeatures.TAIL_MOSS)
|
||||
.addFeature(EndFeatures.TAIL_MOSS_WOOD)
|
||||
.addFeature(EndFeatures.CHARNIA_PURPLE)
|
||||
.addStructureFeature(ConfiguredStructureFeatures.END_CITY)
|
||||
.addMobSpawn(EndEntities.END_SLIME, 5, 1, 2)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 50, 1, 4));
|
||||
|
|
|
@ -31,6 +31,8 @@ public class BiomeFoggyMushroomland extends EndBiome {
|
|||
.addFeature(EndFeatures.CYAN_MOSS_WOOD)
|
||||
.addFeature(EndFeatures.END_LILY)
|
||||
.addFeature(EndFeatures.BUBBLE_CORAL)
|
||||
.addFeature(EndFeatures.CHARNIA_CYAN)
|
||||
.addFeature(EndFeatures.CHARNIA_LIGHT_BLUE)
|
||||
.addStructureFeature(ConfiguredStructureFeatures.END_CITY)
|
||||
.addMobSpawn(EndEntities.DRAGONFLY, 80, 2, 5)
|
||||
.addMobSpawn(EndEntities.END_FISH, 20, 2, 5)
|
||||
|
|
|
@ -24,6 +24,9 @@ public class BiomeMegalake extends EndBiome {
|
|||
.addFeature(EndFeatures.END_LILY_RARE)
|
||||
.addFeature(EndFeatures.UMBRELLA_MOSS)
|
||||
.addFeature(EndFeatures.CREEPING_MOSS)
|
||||
.addFeature(EndFeatures.CHARNIA_CYAN)
|
||||
.addFeature(EndFeatures.CHARNIA_LIGHT_BLUE)
|
||||
.addFeature(EndFeatures.MENGER_SPONGE)
|
||||
.addMobSpawn(EndEntities.DRAGONFLY, 50, 1, 3)
|
||||
.addMobSpawn(EndEntities.END_FISH, 50, 3, 8)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 10, 1, 2));
|
||||
|
|
|
@ -27,6 +27,9 @@ public class BiomeMegalakeGrove extends EndBiome {
|
|||
.addFeature(EndFeatures.END_LILY_RARE)
|
||||
.addFeature(EndFeatures.UMBRELLA_MOSS)
|
||||
.addFeature(EndFeatures.CREEPING_MOSS)
|
||||
.addFeature(EndFeatures.CHARNIA_CYAN)
|
||||
.addFeature(EndFeatures.CHARNIA_LIGHT_BLUE)
|
||||
.addFeature(EndFeatures.MENGER_SPONGE)
|
||||
.addMobSpawn(EndEntities.DRAGONFLY, 20, 1, 3)
|
||||
.addMobSpawn(EndEntities.END_FISH, 20, 3, 8)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 10, 1, 2));
|
||||
|
|
|
@ -31,6 +31,7 @@ public class BiomeShadowForest extends EndBiome {
|
|||
.addFeature(EndFeatures.PURPLE_POLYPORE)
|
||||
.addFeature(EndFeatures.TAIL_MOSS)
|
||||
.addFeature(EndFeatures.TAIL_MOSS_WOOD)
|
||||
.addFeature(EndFeatures.CHARNIA_PURPLE)
|
||||
.addStructureFeature(ConfiguredStructureFeatures.END_CITY)
|
||||
.addMobSpawn(EndEntities.SHADOW_WALKER, 80, 2, 4)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 40, 1, 4)
|
||||
|
|
|
@ -19,6 +19,8 @@ public class BiomeSulphurSprings extends EndBiome {
|
|||
.addFeature(EndFeatures.SULPHURIC_LAKE)
|
||||
.addFeature(EndFeatures.SULPHURIC_CAVE)
|
||||
.addFeature(EndFeatures.HYDRALUX)
|
||||
.addFeature(EndFeatures.CHARNIA_ORANGE)
|
||||
.addFeature(EndFeatures.CHARNIA_RED)
|
||||
.addMobSpawn(EntityType.ENDERMAN, 50, 1, 4));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
package ru.betterend.world.features;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
|
||||
public class CharniaFeature extends UnderwaterPlantFeature {
|
||||
public CharniaFeature(Block plant) {
|
||||
super(plant, 6);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getChance() {
|
||||
return 3;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
package ru.betterend.world.features;
|
||||
|
||||
import java.util.Random;
|
||||
import java.util.function.Function;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.Direction;
|
||||
import net.minecraft.world.StructureWorldAccess;
|
||||
import ru.betterend.registry.EndBlocks;
|
||||
import ru.betterend.util.BlocksHelper;
|
||||
|
||||
public class MengerSpongeFeature extends UnderwaterPlantScatter {
|
||||
private static final Function<BlockState, Boolean> REPLACE;
|
||||
|
||||
public MengerSpongeFeature(int radius) {
|
||||
super(radius);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void generate(StructureWorldAccess world, Random random, BlockPos blockPos) {
|
||||
BlocksHelper.setWithoutUpdate(world, blockPos, EndBlocks.MENGER_SPONGE_WET);
|
||||
if (random.nextBoolean()) {
|
||||
for (Direction dir: BlocksHelper.DIRECTIONS) {
|
||||
BlockPos pos = blockPos.offset(dir);
|
||||
if (REPLACE.apply(world.getBlockState(pos))) {
|
||||
BlocksHelper.setWithoutUpdate(world, pos, EndBlocks.MENGER_SPONGE_WET);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static {
|
||||
REPLACE = (state) -> {
|
||||
if (state.isOf(EndBlocks.END_LOTUS_STEM)) {
|
||||
return false;
|
||||
}
|
||||
return !state.getFluidState().isEmpty() || state.getMaterial().isReplaceable();
|
||||
};
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue