mirror of
https://github.com/TeamMidnightDust/ThisRocks.git
synced 2025-12-15 18:55:08 +01:00
This Rocks 1.1.0
Added Starfish Added Underwater Generation Changed Block Sounds Changed SelectionBox sizes New Seashell Loot Table Update MidnightHats
This commit is contained in:
@@ -8,11 +8,11 @@ org.gradle.jvmargs=-Xmx2G
|
||||
loader_version=0.9.1+build.205
|
||||
|
||||
# Mod Properties
|
||||
mod_version = 1.0.0
|
||||
mod_version = 1.1.0
|
||||
maven_group = eu.midnightdust.motschen
|
||||
archives_base_name = rocks
|
||||
|
||||
# Dependencies
|
||||
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api
|
||||
fabric_version=0.17.2+build.396-1.16
|
||||
midnighthats_version=1.0.2
|
||||
midnighthats_version=2.0.0
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
package eu.midnightdust.motschen.rocks;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.block.*;
|
||||
import eu.midnightdust.motschen.rocks.block.blockentity.BlockEntityInit;
|
||||
import eu.midnightdust.motschen.rocks.block.render.StarfishBlockEntityRenderer;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.RockVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StickVariation;
|
||||
import eu.midnightdust.motschen.rocks.world.FeatureInjector;
|
||||
import eu.midnightdust.motschen.rocks.world.MiscFeatures;
|
||||
import eu.midnightdust.motschen.rocks.world.RockFeatures;
|
||||
import eu.midnightdust.motschen.rocks.world.StickFeatures;
|
||||
import net.fabricmc.api.ClientModInitializer;
|
||||
import net.fabricmc.api.ModInitializer;
|
||||
import net.fabricmc.fabric.api.client.itemgroup.FabricItemGroupBuilder;
|
||||
import net.fabricmc.fabric.api.client.rendereregistry.v1.BlockEntityRendererRegistry;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.BlockItem;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemGroup;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.state.property.EnumProperty;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
|
||||
public class RocksClient implements ClientModInitializer {
|
||||
|
||||
@Override
|
||||
public void onInitializeClient() {
|
||||
BlockEntityRendererRegistry.INSTANCE.register(BlockEntityInit.STARFISH_BE, StarfishBlockEntityRenderer::new);
|
||||
}
|
||||
}
|
||||
@@ -1,13 +1,12 @@
|
||||
package eu.midnightdust.motschen.rocks;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.block.*;
|
||||
import eu.midnightdust.motschen.rocks.block.blockentity.BlockEntityInit;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.RockVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StickVariation;
|
||||
import eu.midnightdust.motschen.rocks.world.FeatureInjector;
|
||||
import eu.midnightdust.motschen.rocks.world.MiscFeatures;
|
||||
import eu.midnightdust.motschen.rocks.world.RockFeatures;
|
||||
import eu.midnightdust.motschen.rocks.world.StickFeatures;
|
||||
import eu.midnightdust.motschen.rocks.world.*;
|
||||
import net.fabricmc.api.ModInitializer;
|
||||
import net.fabricmc.fabric.api.client.itemgroup.FabricItemGroupBuilder;
|
||||
import net.minecraft.block.Block;
|
||||
@@ -25,6 +24,7 @@ public class RocksMain implements ModInitializer {
|
||||
public static final EnumProperty<RockVariation> ROCK_VARIATION = EnumProperty.of("variation", RockVariation.class);
|
||||
public static final EnumProperty<StickVariation> STICK_VARIATION = EnumProperty.of("variation", StickVariation.class);
|
||||
public static final EnumProperty<SeashellVariation> SEASHELL_VARIATION = EnumProperty.of("variation", SeashellVariation.class);
|
||||
public static final EnumProperty<StarfishVariation> STARFISH_VARIATION = EnumProperty.of("variation", StarfishVariation.class);
|
||||
|
||||
public static Block Rock = new Rock();
|
||||
public static Block SandRock = new Rock();
|
||||
@@ -40,6 +40,7 @@ public class RocksMain implements ModInitializer {
|
||||
|
||||
public static Block Pinecone = new Pinecone();
|
||||
public static Block Seashell = new Seashell();
|
||||
public static Block Starfish = new Starfish();
|
||||
|
||||
public static Item CobbleStoneSplitter = new Item(new Item.Settings().group(RocksMain.RocksGroup));
|
||||
public static Item SandStoneSplitter = new Item(new Item.Settings().group(RocksMain.RocksGroup));
|
||||
@@ -74,15 +75,19 @@ public class RocksMain implements ModInitializer {
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"pinecone"), new BlockItem(Pinecone, new Item.Settings().group(RocksMain.RocksGroup)));
|
||||
Registry.register(Registry.BLOCK, new Identifier(MOD_ID,"seashell"), Seashell);
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"seashell"), new BlockItem(Seashell, new Item.Settings().group(RocksMain.RocksGroup)));
|
||||
Registry.register(Registry.BLOCK, new Identifier(MOD_ID,"starfish"), Starfish);
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"starfish"), new BlockItem(Starfish, new Item.Settings().group(RocksMain.RocksGroup)));
|
||||
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"cobblestone_splitter"), CobbleStoneSplitter);
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"sandstone_splitter"), SandStoneSplitter);
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"red_sandstone_splitter"), RedSandStoneSplitter);
|
||||
Registry.register(Registry.ITEM, new Identifier(MOD_ID,"end_stone_splitter"), EndStoneSplitter);
|
||||
|
||||
new FeatureRegistry();
|
||||
RockFeatures.init();
|
||||
StickFeatures.init();
|
||||
MiscFeatures.init();
|
||||
FeatureInjector.init();
|
||||
BlockEntityInit.init();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ public class Pinecone extends Block {
|
||||
private static final VoxelShape SHAPE;
|
||||
|
||||
public Pinecone() {
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.STONE));
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.WOOD));
|
||||
this.setDefaultState(this.stateManager.getDefaultState());
|
||||
}
|
||||
|
||||
|
||||
@@ -2,19 +2,21 @@ package eu.midnightdust.motschen.rocks.block;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StickVariation;
|
||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.block.Blocks;
|
||||
import net.minecraft.block.ShapeContext;
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.fluid.FluidState;
|
||||
import net.minecraft.fluid.Fluids;
|
||||
import net.minecraft.item.ItemPlacementContext;
|
||||
import net.minecraft.sound.BlockSoundGroup;
|
||||
import net.minecraft.sound.SoundCategory;
|
||||
import net.minecraft.sound.SoundEvents;
|
||||
import net.minecraft.state.StateManager;
|
||||
import net.minecraft.state.property.BooleanProperty;
|
||||
import net.minecraft.state.property.EnumProperty;
|
||||
import net.minecraft.state.property.Properties;
|
||||
import net.minecraft.util.ActionResult;
|
||||
import net.minecraft.util.Hand;
|
||||
import net.minecraft.util.hit.BlockHitResult;
|
||||
@@ -25,20 +27,27 @@ import net.minecraft.world.BlockView;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldView;
|
||||
|
||||
public class Seashell extends Block {
|
||||
public class Seashell extends Block implements Waterloggable {
|
||||
|
||||
private static final VoxelShape SHAPE;
|
||||
private static final EnumProperty<SeashellVariation> SEASHELL_VARIATION = RocksMain.SEASHELL_VARIATION;
|
||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||
|
||||
public Seashell() {
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.STONE));
|
||||
this.setDefaultState(this.stateManager.getDefaultState().with(SEASHELL_VARIATION, SeashellVariation.PINK));
|
||||
this.setDefaultState(this.stateManager.getDefaultState().with(SEASHELL_VARIATION, SeashellVariation.PINK).with(WATERLOGGED, false));
|
||||
}
|
||||
|
||||
@Override
|
||||
public FluidState getFluidState(BlockState blockState_1) {
|
||||
return blockState_1.get(WATERLOGGED) ? Fluids.WATER.getStill(true) : super.getFluidState(blockState_1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BlockState getPlacementState(ItemPlacementContext itemPlacementContext) {
|
||||
FluidState fluidState = itemPlacementContext.getWorld().getFluidState(itemPlacementContext.getBlockPos());
|
||||
return super.getPlacementState(itemPlacementContext)
|
||||
.with(SEASHELL_VARIATION, SeashellVariation.PINK);
|
||||
.with(SEASHELL_VARIATION, SeashellVariation.PINK).with(WATERLOGGED, fluidState.getFluid() == Fluids.WATER);
|
||||
}
|
||||
|
||||
public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) {
|
||||
@@ -59,7 +68,7 @@ public class Seashell extends Block {
|
||||
|
||||
@Override
|
||||
protected void appendProperties(StateManager.Builder<Block, BlockState> builder) {
|
||||
builder.add(SEASHELL_VARIATION);
|
||||
builder.add(SEASHELL_VARIATION, WATERLOGGED);
|
||||
}
|
||||
@Override
|
||||
public VoxelShape getOutlineShape(BlockState state, BlockView view, BlockPos pos, ShapeContext context) {
|
||||
|
||||
@@ -0,0 +1,90 @@
|
||||
package eu.midnightdust.motschen.rocks.block;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.block.blockentity.StarfishBlockEntity;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.fluid.FluidState;
|
||||
import net.minecraft.fluid.Fluids;
|
||||
import net.minecraft.item.ItemPlacementContext;
|
||||
import net.minecraft.sound.BlockSoundGroup;
|
||||
import net.minecraft.state.StateManager;
|
||||
import net.minecraft.state.property.BooleanProperty;
|
||||
import net.minecraft.state.property.EnumProperty;
|
||||
import net.minecraft.state.property.Properties;
|
||||
import net.minecraft.util.ActionResult;
|
||||
import net.minecraft.util.Hand;
|
||||
import net.minecraft.util.hit.BlockHitResult;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.Direction;
|
||||
import net.minecraft.util.shape.VoxelShape;
|
||||
import net.minecraft.world.BlockView;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldView;
|
||||
|
||||
public class Starfish extends Block implements BlockEntityProvider, Waterloggable {
|
||||
|
||||
private static final VoxelShape SHAPE;
|
||||
private static final EnumProperty<StarfishVariation> STARFISH_VARIATION = RocksMain.STARFISH_VARIATION;
|
||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||
|
||||
public Starfish() {
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.CORAL));
|
||||
this.setDefaultState(this.stateManager.getDefaultState().with(STARFISH_VARIATION, StarfishVariation.RED).with(WATERLOGGED, false));
|
||||
}
|
||||
|
||||
@Override
|
||||
public FluidState getFluidState(BlockState blockState_1) {
|
||||
return blockState_1.get(WATERLOGGED) ? Fluids.WATER.getStill(true) : super.getFluidState(blockState_1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BlockEntity createBlockEntity(BlockView view) {
|
||||
return new StarfishBlockEntity();
|
||||
}
|
||||
|
||||
@Override
|
||||
public BlockState getPlacementState(ItemPlacementContext itemPlacementContext) {
|
||||
FluidState fluidState = itemPlacementContext.getWorld().getFluidState(itemPlacementContext.getBlockPos());
|
||||
return super.getPlacementState(itemPlacementContext)
|
||||
.with(STARFISH_VARIATION, StarfishVariation.RED).with(WATERLOGGED, fluidState.getFluid() == Fluids.WATER);
|
||||
}
|
||||
|
||||
public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) {
|
||||
if (player.isCreative()) {
|
||||
if (state.get(STARFISH_VARIATION) == StarfishVariation.RED) {
|
||||
world.setBlockState(pos, state.with(STARFISH_VARIATION, StarfishVariation.PINK));
|
||||
}
|
||||
if (state.get(STARFISH_VARIATION) == StarfishVariation.PINK) {
|
||||
world.setBlockState(pos, state.with(STARFISH_VARIATION, StarfishVariation.ORANGE));
|
||||
}
|
||||
if (state.get(STARFISH_VARIATION) == StarfishVariation.ORANGE) {
|
||||
world.setBlockState(pos, state.with(STARFISH_VARIATION, StarfishVariation.RED));
|
||||
}
|
||||
return ActionResult.SUCCESS;
|
||||
}
|
||||
else return ActionResult.FAIL;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void appendProperties(StateManager.Builder<Block, BlockState> builder) {
|
||||
builder.add(STARFISH_VARIATION,WATERLOGGED);
|
||||
}
|
||||
@Override
|
||||
public VoxelShape getOutlineShape(BlockState state, BlockView view, BlockPos pos, ShapeContext context) {
|
||||
return SHAPE;
|
||||
}
|
||||
static {
|
||||
VoxelShape shape = createCuboidShape(0, 0, 0, 16, 1, 16);
|
||||
|
||||
SHAPE = shape;
|
||||
}
|
||||
|
||||
public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) {
|
||||
return world.getBlockState(pos.down()).isSideSolidFullSquare(world,pos,Direction.UP);
|
||||
}
|
||||
}
|
||||
@@ -26,7 +26,7 @@ public class Stick extends Block {
|
||||
private static final EnumProperty<StickVariation> STICK_VARIATION = RocksMain.STICK_VARIATION;
|
||||
|
||||
public Stick() {
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.STONE));
|
||||
super(FabricBlockSettings.copy(Blocks.POPPY).nonOpaque().sounds(BlockSoundGroup.WOOD));
|
||||
this.setDefaultState(this.stateManager.getDefaultState().with(STICK_VARIATION, StickVariation.SMALL));
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ public class Stick extends Block {
|
||||
return SHAPE;
|
||||
}
|
||||
static {
|
||||
VoxelShape shape = createCuboidShape(0, 0, 0, 16, 3, 16);
|
||||
VoxelShape shape = createCuboidShape(0, 0, 0, 16, 1, 16);
|
||||
|
||||
SHAPE = shape;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
package eu.midnightdust.motschen.rocks.block.blockentity;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import net.minecraft.block.entity.BlockEntityType;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
|
||||
public class BlockEntityInit {
|
||||
public static BlockEntityType<StarfishBlockEntity> STARFISH_BE;
|
||||
|
||||
public static void init() {
|
||||
STARFISH_BE = Registry.register(Registry.BLOCK_ENTITY_TYPE, new Identifier(RocksMain.MOD_ID,"starfish_blockentity"), BlockEntityType.Builder.create(StarfishBlockEntity::new, RocksMain.Starfish).build(null));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
package eu.midnightdust.motschen.rocks.block.blockentity;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.sound.SoundCategory;
|
||||
import net.minecraft.util.Tickable;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
|
||||
public class StarfishBlockEntity extends BlockEntity implements Tickable {
|
||||
private String variation;
|
||||
|
||||
public StarfishBlockEntity() {
|
||||
super(BlockEntityInit.STARFISH_BE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
BlockPos pos = this.pos;
|
||||
BlockState state = this.world.getBlockState(pos);
|
||||
|
||||
if (world != null && state.get(RocksMain.STARFISH_VARIATION) == StarfishVariation.RED) {
|
||||
variation = String.valueOf(StarfishVariation.RED);
|
||||
return;
|
||||
}
|
||||
else if (world != null && state.get(RocksMain.STARFISH_VARIATION) == StarfishVariation.PINK) {
|
||||
variation = String.valueOf(StarfishVariation.PINK);
|
||||
return;
|
||||
}
|
||||
else {
|
||||
variation = String.valueOf(StarfishVariation.ORANGE);
|
||||
return;
|
||||
}
|
||||
}
|
||||
public String getVariation() {
|
||||
return variation;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,122 @@
|
||||
package eu.midnightdust.motschen.rocks.block.render;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.block.blockentity.StarfishBlockEntity;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
import net.minecraft.client.model.ModelPart;
|
||||
import net.minecraft.client.render.RenderLayer;
|
||||
import net.minecraft.client.render.VertexConsumer;
|
||||
import net.minecraft.client.render.VertexConsumerProvider;
|
||||
import net.minecraft.client.render.block.entity.BlockEntityRenderDispatcher;
|
||||
import net.minecraft.client.render.block.entity.BlockEntityRenderer;
|
||||
import net.minecraft.client.util.math.MatrixStack;
|
||||
import net.minecraft.client.util.math.Vector3f;
|
||||
import net.minecraft.util.Identifier;
|
||||
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class StarfishBlockEntityRenderer extends BlockEntityRenderer<StarfishBlockEntity> {
|
||||
private final ModelPart side1;
|
||||
private final ModelPart side2;
|
||||
private final ModelPart side3;
|
||||
private final ModelPart side4;
|
||||
private final ModelPart side5;
|
||||
private final ModelPart bb_main;
|
||||
|
||||
public StarfishBlockEntityRenderer(BlockEntityRenderDispatcher blockEntityRenderDispatcher) {
|
||||
super(blockEntityRenderDispatcher);
|
||||
side1 = new ModelPart(16, 16, 0, 0);
|
||||
side1.setPivot(0.0F, 24.0F, 0.0F);
|
||||
side1.setTextureOffset(0, 0).addCuboid(-0.5F, -1.0F, 1.0F, 1.0F, 1.0F, 4.0F, 0.0F, false);
|
||||
side1.setTextureOffset(1, 1).addCuboid(-0.75F, -1.02F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side1.setTextureOffset(1, 2).addCuboid(-1.0F, -0.99F, 1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
side1.setTextureOffset(1, 1).addCuboid(-0.25F, -1.01F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
|
||||
side2 = new ModelPart(16, 16, 0, 0);
|
||||
side2.setPivot(0.0F, 24.0F, 0.0F);
|
||||
setRotationAngle(side2, 0.0F, -1.2654F, 0.0F);
|
||||
side2.setTextureOffset(0, 0).addCuboid(-0.5F, -1.0F, 1.0F, 1.0F, 1.0F, 4.0F, 0.0F, false);
|
||||
side2.setTextureOffset(1, 1).addCuboid(-0.75F, -1.02F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side2.setTextureOffset(1, 1).addCuboid(-0.25F, -1.01F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side2.setTextureOffset(1, 2).addCuboid(-1.0F, -0.99F, 1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
|
||||
side3 = new ModelPart(16, 16, 0, 0);
|
||||
side3.setPivot(0.0F, 24.0F, 0.0F);
|
||||
setRotationAngle(side3, 0.0F, 1.2654F, 0.0F);
|
||||
side3.setTextureOffset(0, 0).addCuboid(-0.5F, -1.0F, 1.0F, 1.0F, 1.0F, 4.0F, 0.0F, false);
|
||||
side3.setTextureOffset(1, 1).addCuboid(-0.75F, -1.02F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side3.setTextureOffset(1, 1).addCuboid(-0.25F, -1.01F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side3.setTextureOffset(1, 2).addCuboid(-1.0F, -0.99F, 1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
|
||||
side4 = new ModelPart(16, 16, 0, 0);
|
||||
side4.setPivot(0.0F, 24.0F, 0.0F);
|
||||
setRotationAngle(side4, 0.0F, 2.5307F, 0.0F);
|
||||
side4.setTextureOffset(0, 0).addCuboid(-0.5F, -1.0F, 1.0F, 1.0F, 1.0F, 4.0F, 0.0F, false);
|
||||
side4.setTextureOffset(1, 1).addCuboid(-0.75F, -1.02F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side4.setTextureOffset(1, 1).addCuboid(-0.25F, -1.01F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side4.setTextureOffset(1, 2).addCuboid(-1.0F, -0.99F, 1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
|
||||
side5 = new ModelPart(16, 16, 0, 0);
|
||||
side5.setPivot(0.0F, 24.0F, 0.0F);
|
||||
setRotationAngle(side5, 0.0F, -2.5307F, 0.0F);
|
||||
side5.setTextureOffset(0, 0).addCuboid(-0.5F, -1.0F, 1.0F, 1.0F, 1.0F, 4.0F, 0.0F, false);
|
||||
side5.setTextureOffset(1, 1).addCuboid(-0.75F, -1.02F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side5.setTextureOffset(1, 1).addCuboid(-0.25F, -1.01F, 1.0F, 1.0F, 1.0F, 3.0F, 0.0F, false);
|
||||
side5.setTextureOffset(1, 2).addCuboid(-1.0F, -0.99F, 1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
|
||||
bb_main = new ModelPart(16, 16, 0, 0);
|
||||
bb_main.setPivot(0.0F, 24.0F, 0.0F);
|
||||
bb_main.setTextureOffset(1, 2).addCuboid(-1.0F, -1.005F, -1.0F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
bb_main.setTextureOffset(1, 2).addCuboid(-0.8F, -1.0F, -1.25F, 2.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
bb_main.setTextureOffset(2, 2).addCuboid(-1.2F, -1.0F, -1.25F, 1.0F, 1.0F, 2.0F, 0.0F, false);
|
||||
}
|
||||
@Override
|
||||
public void render(StarfishBlockEntity blockEntity, float tickDelta, MatrixStack matrixStack, VertexConsumerProvider vertexConsumers, int light, int overlay) {
|
||||
if (blockEntity.getVariation() == String.valueOf(StarfishVariation.RED)) {
|
||||
matrixStack.push();
|
||||
VertexConsumer vertexConsumer = vertexConsumers.getBuffer(RenderLayer.getEntityCutoutNoCull(new Identifier("rocks:textures/block/starfish_red.png")));
|
||||
|
||||
matrixStack.translate(0.4, -1.44, 0.6);
|
||||
side1.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side2.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side3.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side4.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side5.render(matrixStack, vertexConsumer, light, overlay);
|
||||
bb_main.render(matrixStack, vertexConsumer, light, overlay);
|
||||
matrixStack.pop();
|
||||
}
|
||||
else if (blockEntity.getVariation() == String.valueOf(StarfishVariation.PINK)) {
|
||||
matrixStack.push();
|
||||
VertexConsumer vertexConsumer = vertexConsumers.getBuffer(RenderLayer.getEntityCutoutNoCull(new Identifier("rocks:textures/block/starfish_pink.png")));
|
||||
|
||||
matrixStack.translate(0.4, -1.44, 0.4);
|
||||
matrixStack.multiply(Vector3f.POSITIVE_Y.getDegreesQuaternion(90));
|
||||
side1.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side2.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side3.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side4.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side5.render(matrixStack, vertexConsumer, light, overlay);
|
||||
bb_main.render(matrixStack, vertexConsumer, light, overlay);
|
||||
matrixStack.pop();
|
||||
}
|
||||
else {
|
||||
matrixStack.push();
|
||||
VertexConsumer vertexConsumer = vertexConsumers.getBuffer(RenderLayer.getEntityCutoutNoCull(new Identifier("rocks:textures/block/starfish_orange.png")));
|
||||
|
||||
matrixStack.translate(0.65, -1.44, 0.65);
|
||||
matrixStack.multiply(Vector3f.POSITIVE_Y.getDegreesQuaternion(123));
|
||||
side1.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side2.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side3.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side4.render(matrixStack, vertexConsumer, light, overlay);
|
||||
side5.render(matrixStack, vertexConsumer, light, overlay);
|
||||
bb_main.render(matrixStack, vertexConsumer, light, overlay);
|
||||
matrixStack.pop();
|
||||
}
|
||||
}
|
||||
public void setRotationAngle(ModelPart bone, float x, float y, float z) {
|
||||
bone.pitch = x;
|
||||
bone.yaw = y;
|
||||
bone.roll = z;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
package eu.midnightdust.motschen.rocks.blockstates;
|
||||
|
||||
import net.minecraft.util.StringIdentifiable;
|
||||
|
||||
public enum StarfishVariation implements StringIdentifiable {
|
||||
RED("red"),
|
||||
PINK("pink"),
|
||||
ORANGE("orange");
|
||||
|
||||
private final String name;
|
||||
|
||||
StarfishVariation(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public String asString() {
|
||||
return this.name;
|
||||
}
|
||||
}
|
||||
@@ -36,37 +36,35 @@ public class FeatureInjector {
|
||||
// Sticks
|
||||
if (biome.toString().contains("minecraft:forest") || biome.toString().contains("minecraft:wooded_hills") ||
|
||||
biome.toString().contains("minecraft:wooded_mountains") || biome.toString().contains("minecraft:plains") ||
|
||||
biome.toString().contains("minecraft:flower_forest") || biome.toString().contains("minecraft:swamp") ||
|
||||
biome.toString().contains("minecraft:swamp_hills") || biome.toString().contains("minecraft:wooded_badlands_plateau") ||
|
||||
biome.toString().contains("minecraft:modified_wooded_badlands_plateau")) {
|
||||
biome.toString().contains("minecraft:flower_forest") || biome.toString().contains("minecraft:wooded_badlands_plateau") ||
|
||||
biome.toString().contains("minecraft:modified_wooded_badlands_plateau") || biome.getCategory() == Biome.Category.SWAMP) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, StickFeatures.OAK_STICK_FEATURE);
|
||||
}
|
||||
if (biome.toString().contains("minecraft:forest") || biome.toString().contains("minecraft:birch_forest") ||
|
||||
biome.toString().contains("minecraft:birch_forest_hills") || biome.toString().contains("minecraft:flower_forest")) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, StickFeatures.BIRCH_STICK_FEATURE);
|
||||
}
|
||||
if (biome.toString().contains("minecraft:taiga") || biome.toString().contains("minecraft:taiga_mountains") ||
|
||||
biome.toString().contains("minecraft:giant_spruce_taiga") || biome.toString().contains("minecraft:taiga_hills")||
|
||||
biome.toString().contains("minecraft:giant_spruce_taiga_hills") || biome.toString().contains("minecraft:snowy_taiga_mountain") ||
|
||||
biome.toString().contains("minecraft:snowy_taiga") || biome.toString().contains("minecraft:snowy_taiga_hills") ||
|
||||
biome.toString().contains("minecraft:giant_tree_taiga") || biome.toString().contains("minecraft:giant_tree_taiga_hills") ||
|
||||
biome.toString().contains("minecraft:wooded_mountains")) {
|
||||
if (biome.toString().contains("minecraft:wooded_mountains") || biome.getCategory() == Biome.Category.TAIGA) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, StickFeatures.SPRUCE_STICK_FEATURE);
|
||||
}
|
||||
if (biome.toString().contains("minecraft:savanna") || biome.toString().contains("minecraft:savanna_plateau") ||
|
||||
biome.toString().contains("minecraft:shattered_savanna") || biome.toString().contains("minecraft:shattered_savanna_plateau")) {
|
||||
if (biome.getCategory() == Biome.Category.SAVANNA) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, StickFeatures.ACACIA_STICK_FEATURE);
|
||||
}
|
||||
if (biome.getCategory() == Biome.Category.JUNGLE) {
|
||||
addFeature(biome, GenerationStep.Feature.UNDERGROUND_DECORATION, StickFeatures.JUNGLE_STICK_FEATURE);
|
||||
}
|
||||
if (biome.toString().contains("minecraft:dark_forest") || biome.toString().contains("minecraft:dark_forest_hills") ||
|
||||
biome.toString().contains("minecraft:birch_forest_hills") || biome.toString().contains("minecraft:flower_forest")) {
|
||||
biome.toString().contains("minecraft:dark_forest_mountains")) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, StickFeatures.DARK_OAK_STICK_FEATURE);
|
||||
}
|
||||
// Misc
|
||||
if (biome.getCategory() == Biome.Category.BEACH) {
|
||||
if (biome.getCategory() == Biome.Category.BEACH && !biome.toString().contains("minecraft:snowy_beach")) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, MiscFeatures.SEASHELL_FEATURE);
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, MiscFeatures.STARFISH_FEATURE);
|
||||
}
|
||||
if (biome.getCategory() == Biome.Category.OCEAN) {
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, MiscFeatures.UNDERWATER_STARFISH_FEATURE);
|
||||
addFeature(biome, GenerationStep.Feature.TOP_LAYER_MODIFICATION, MiscFeatures.UNDERWATER_SEASHELL_FEATURE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
package eu.midnightdust.motschen.rocks.world;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import net.minecraft.state.property.Properties;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
import net.minecraft.world.gen.ProbabilityConfig;
|
||||
import net.minecraft.world.gen.feature.Feature;
|
||||
import net.minecraft.world.gen.feature.FeatureConfig;
|
||||
import net.minecraft.world.gen.stateprovider.WeightedBlockStateProvider;
|
||||
|
||||
public class FeatureRegistry<FC extends FeatureConfig> {
|
||||
|
||||
public static final UnderwaterFeature UNDERWATER_STARFISH_FEATURE;
|
||||
public static final UnderwaterFeature UNDERWATER_SEASHELL_FEATURE;
|
||||
|
||||
private static <C extends FeatureConfig, F extends Feature<C>> F register(String name, F feature) {
|
||||
return Registry.register(Registry.FEATURE, name, feature);
|
||||
}
|
||||
|
||||
private static final WeightedBlockStateProvider StarfishStates = new WeightedBlockStateProvider()
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION, StarfishVariation.RED).with(Properties.WATERLOGGED, true), 6)
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION,StarfishVariation.PINK).with(Properties.WATERLOGGED, true), 7)
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION,StarfishVariation.ORANGE).with(Properties.WATERLOGGED, true), 2);
|
||||
|
||||
private static final WeightedBlockStateProvider SeashellStates = new WeightedBlockStateProvider()
|
||||
.addState(RocksMain.Seashell.getDefaultState().with(RocksMain.SEASHELL_VARIATION, SeashellVariation.YELLOW).with(Properties.WATERLOGGED, true), 7)
|
||||
.addState(RocksMain.Seashell.getDefaultState().with(RocksMain.SEASHELL_VARIATION,SeashellVariation.PINK).with(Properties.WATERLOGGED, true), 2)
|
||||
.addState(RocksMain.Seashell.getDefaultState().with(RocksMain.SEASHELL_VARIATION,SeashellVariation.WHITE).with(Properties.WATERLOGGED, true), 6);
|
||||
|
||||
static {
|
||||
UNDERWATER_STARFISH_FEATURE = (UnderwaterFeature)register("underwater_starfish", new UnderwaterFeature(ProbabilityConfig.CODEC, StarfishStates));
|
||||
UNDERWATER_SEASHELL_FEATURE = (UnderwaterFeature)register("underwater_seashell", new UnderwaterFeature(ProbabilityConfig.CODEC, SeashellStates));
|
||||
}
|
||||
}
|
||||
@@ -2,14 +2,13 @@ package eu.midnightdust.motschen.rocks.world;
|
||||
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.SeashellVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StickVariation;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.registry.BuiltinRegistries;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
import net.minecraft.world.gen.feature.ConfiguredFeature;
|
||||
import net.minecraft.world.gen.feature.ConfiguredFeatures;
|
||||
import net.minecraft.world.gen.feature.Feature;
|
||||
import net.minecraft.world.gen.feature.RandomPatchFeatureConfig;
|
||||
import net.minecraft.world.gen.ProbabilityConfig;
|
||||
import net.minecraft.world.gen.feature.*;
|
||||
import net.minecraft.world.gen.placer.SimpleBlockPlacer;
|
||||
import net.minecraft.world.gen.stateprovider.SimpleBlockStateProvider;
|
||||
import net.minecraft.world.gen.stateprovider.WeightedBlockStateProvider;
|
||||
@@ -24,9 +23,25 @@ public class MiscFeatures {
|
||||
SimpleBlockPlacer.INSTANCE))
|
||||
.tries(1).spreadX(0).spreadY(0).spreadZ(0)
|
||||
.build()).decorate(ConfiguredFeatures.Decorators.FIRE).applyChance(1);
|
||||
public static ConfiguredFeature<?, ?> STARFISH_FEATURE = Feature.RANDOM_PATCH.configure(
|
||||
(new RandomPatchFeatureConfig.Builder(
|
||||
new WeightedBlockStateProvider()
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION,StarfishVariation.RED), 2)
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION,StarfishVariation.PINK), 6)
|
||||
.addState(RocksMain.Starfish.getDefaultState().with(RocksMain.STARFISH_VARIATION,StarfishVariation.ORANGE), 7),
|
||||
SimpleBlockPlacer.INSTANCE))
|
||||
.tries(1).spreadX(0).spreadY(0).spreadZ(0)
|
||||
.build()).decorate(ConfiguredFeatures.Decorators.FIRE).applyChance(1);
|
||||
|
||||
public static ConfiguredFeature<?, ?> UNDERWATER_STARFISH_FEATURE = FeatureRegistry.UNDERWATER_STARFISH_FEATURE.configure(new ProbabilityConfig(1));
|
||||
public static ConfiguredFeature<?, ?> UNDERWATER_SEASHELL_FEATURE = FeatureRegistry.UNDERWATER_SEASHELL_FEATURE.configure(new ProbabilityConfig(1));
|
||||
|
||||
public static void init() {
|
||||
Registry<ConfiguredFeature<?, ?>> registry = BuiltinRegistries.CONFIGURED_FEATURE;
|
||||
Registry.register(registry, new Identifier(RocksMain.MOD_ID, "seashell"), SEASHELL_FEATURE);
|
||||
Registry.register(registry, new Identifier(RocksMain.MOD_ID, "starfish"), STARFISH_FEATURE);
|
||||
Registry.register(registry, new Identifier(RocksMain.MOD_ID, "underwater_starfish"), UNDERWATER_STARFISH_FEATURE);
|
||||
Registry.register(registry, new Identifier(RocksMain.MOD_ID, "underwater_seashell"), UNDERWATER_SEASHELL_FEATURE);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
package eu.midnightdust.motschen.rocks.world;
|
||||
|
||||
import com.mojang.serialization.Codec;
|
||||
import eu.midnightdust.motschen.rocks.RocksMain;
|
||||
import eu.midnightdust.motschen.rocks.blockstates.StarfishVariation;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.block.Blocks;
|
||||
import net.minecraft.block.RailPlacementHelper;
|
||||
import net.minecraft.block.TallSeagrassBlock;
|
||||
import net.minecraft.block.enums.DoubleBlockHalf;
|
||||
import net.minecraft.state.property.Properties;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.Heightmap;
|
||||
import net.minecraft.world.StructureWorldAccess;
|
||||
import net.minecraft.world.gen.ProbabilityConfig;
|
||||
import net.minecraft.world.gen.chunk.ChunkGenerator;
|
||||
import net.minecraft.world.gen.feature.Feature;
|
||||
import net.minecraft.world.gen.placer.SimpleBlockPlacer;
|
||||
import net.minecraft.world.gen.stateprovider.WeightedBlockStateProvider;
|
||||
|
||||
import java.util.Random;
|
||||
|
||||
public class UnderwaterFeature extends Feature<ProbabilityConfig> {
|
||||
WeightedBlockStateProvider weightedBlockStateProvider1;
|
||||
public UnderwaterFeature(Codec<ProbabilityConfig> codec, WeightedBlockStateProvider weightedBlockStateProvider) {
|
||||
super(codec);
|
||||
weightedBlockStateProvider1 = weightedBlockStateProvider;
|
||||
}
|
||||
|
||||
public boolean generate(StructureWorldAccess structureWorldAccess, ChunkGenerator chunkGenerator, Random random, BlockPos blockPos, ProbabilityConfig probabilityConfig) {
|
||||
boolean bl = false;
|
||||
int i = random.nextInt(8) - random.nextInt(8);
|
||||
int j = random.nextInt(8) - random.nextInt(8);
|
||||
int k = structureWorldAccess.getTopY(Heightmap.Type.OCEAN_FLOOR, blockPos.getX() + i, blockPos.getZ() + j);
|
||||
BlockPos blockPos2 = new BlockPos(blockPos.getX() + i, k, blockPos.getZ() + j);
|
||||
|
||||
if (structureWorldAccess.getBlockState(blockPos2).isOf(Blocks.WATER)) {
|
||||
boolean bl2 = random.nextDouble() < (double)probabilityConfig.probability;
|
||||
boolean bl3 = random.nextDouble() < (double)2;
|
||||
|
||||
BlockState blockState = weightedBlockStateProvider1.getBlockState(random,blockPos);
|
||||
|
||||
if (blockState.canPlaceAt(structureWorldAccess, blockPos2)) {
|
||||
structureWorldAccess.setBlockState(blockPos2, blockState, 2);
|
||||
|
||||
bl = true;
|
||||
}
|
||||
}
|
||||
|
||||
return bl;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"variants": {
|
||||
"variation=red": { "model": "rocks:block/starfish_red" },
|
||||
"variation=pink": { "model": "rocks:block/starfish_pink" },
|
||||
"variation=orange": { "model": "rocks:block/starfish_orange" }
|
||||
}
|
||||
}
|
||||
24
src/main/resources/assets/rocks/lang/de_de.json
Normal file
24
src/main/resources/assets/rocks/lang/de_de.json
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"itemGroup.rocks.rocks":"This Rocks!",
|
||||
|
||||
"block.rocks.rock":"Steinbrocken",
|
||||
"block.rocks.sand_rock":"Sandsteinbrocken",
|
||||
"block.rocks.red_sand_rock":"Roter Sandsteinbrocken",
|
||||
"block.rocks.end_stone_rock":"Endsteinbrocken",
|
||||
|
||||
"block.rocks.oak_stick":"Eichenholzstock",
|
||||
"block.rocks.birch_stick":"Birkenholzstock",
|
||||
"block.rocks.spruce_stick":"Fichtenholzstock",
|
||||
"block.rocks.jungle_stick":"Tropenholzstock",
|
||||
"block.rocks.acacia_stick":"Akazienholzstock",
|
||||
"block.rocks.dark_oak_stick":"Schwarzeichenholzstock",
|
||||
|
||||
"block.rocks.pinecone":"Tannenzapfen",
|
||||
"block.rocks.seashell":"Muschel",
|
||||
"block.rocks.starfish":"Seestern",
|
||||
|
||||
"item.rocks.cobblestone_splitter":"Bruchsteinsplitter",
|
||||
"item.rocks.sandstone_splitter":"Sandsteinsplitter",
|
||||
"item.rocks.red_sandstone_splitter":"Roter Sandsteinsplitter",
|
||||
"item.rocks.end_stone_splitter":"Endsteinsplitter"
|
||||
}
|
||||
@@ -15,6 +15,7 @@
|
||||
|
||||
"block.rocks.pinecone":"Pinecone",
|
||||
"block.rocks.seashell":"Seashell",
|
||||
"block.rocks.starfish":"Starfish",
|
||||
|
||||
"item.rocks.cobblestone_splitter":"Cobblestone Splitter",
|
||||
"item.rocks.sandstone_splitter":"Sandstone Splitter",
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "block/air",
|
||||
"textures": {
|
||||
"particle": "rocks:block/starfish_orange"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "block/air",
|
||||
"textures": {
|
||||
"particle": "rocks:block/starfish_pink"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "block/air",
|
||||
"textures": {
|
||||
"particle": "rocks:block/starfish_red"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "item/generated",
|
||||
"textures": {
|
||||
"layer0": "rocks:item/starfish"
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 229 B |
BIN
src/main/resources/assets/rocks/textures/block/starfish_pink.png
Normal file
BIN
src/main/resources/assets/rocks/textures/block/starfish_pink.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 231 B |
BIN
src/main/resources/assets/rocks/textures/block/starfish_red.png
Normal file
BIN
src/main/resources/assets/rocks/textures/block/starfish_red.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 234 B |
BIN
src/main/resources/assets/rocks/textures/item/starfish.png
Normal file
BIN
src/main/resources/assets/rocks/textures/item/starfish.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 379 B |
@@ -6,12 +6,25 @@
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "rocks:seashell"
|
||||
}
|
||||
],
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:survives_explosion"
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:table_bonus",
|
||||
"enchantment": "minecraft:fortune",
|
||||
"chances": [
|
||||
0.02,
|
||||
0.022222223,
|
||||
0.025,
|
||||
0.033333335,
|
||||
0.1
|
||||
]
|
||||
}
|
||||
],
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:explosion_decay"
|
||||
}
|
||||
],
|
||||
"name": "minecraft:nautilus_shell"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"type": "minecraft:block",
|
||||
"pools": [
|
||||
{
|
||||
"rolls": 1,
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "rocks:starfish"
|
||||
}
|
||||
],
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:survives_explosion"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -4,7 +4,7 @@
|
||||
"version": "${version}",
|
||||
|
||||
"name": "This Rocks!",
|
||||
"description": "Adds little rocks, sticks, pinecones and seashells to your world to make it feel more natural.",
|
||||
"description": "Adds little rocks, sticks, pinecones, seashells and starfish to your world to make it feel more natural.",
|
||||
"authors": [
|
||||
"Motschen",
|
||||
"TeamMidnightDust"
|
||||
@@ -21,6 +21,9 @@
|
||||
"entrypoints": {
|
||||
"main": [
|
||||
"eu.midnightdust.motschen.rocks.RocksMain"
|
||||
],
|
||||
"client": [
|
||||
"eu.midnightdust.motschen.rocks.RocksClient"
|
||||
]
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user