Compare commits
12 Commits
block
...
12130a9602
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
12130a9602 | ||
|
|
4d6301ce95 | ||
|
|
d7c85d04bb | ||
|
|
28761d44c0 | ||
|
|
042df08b9b | ||
|
|
d4654623f4 | ||
|
|
6f059abcce | ||
|
|
367a48218f | ||
|
|
d6ea5ab7e0 | ||
|
|
a1d8b2cb58 | ||
|
|
bf18dbf49b | ||
|
|
4712edc42d |
@@ -4,10 +4,10 @@ org.gradle.parallel=true
|
||||
|
||||
# Fabric Properties
|
||||
# check these on https://fabricmc.net/develop
|
||||
minecraft_version=1.21.8
|
||||
yarn_mappings=1.21.8+build.1
|
||||
loader_version=0.16.14
|
||||
loom_version=1.11-SNAPSHOT
|
||||
minecraft_version=1.21.11
|
||||
yarn_mappings=1.21.11+build.4
|
||||
loader_version=0.18.4
|
||||
loom_version=1.15-SNAPSHOT
|
||||
|
||||
# Mod Properties
|
||||
mod_version=1.0.0
|
||||
@@ -15,4 +15,4 @@ maven_group=de.jottyfan.minecraft
|
||||
archives_base_name=gtamfmd
|
||||
|
||||
# Dependencies
|
||||
fabric_version=0.129.0+1.21.8
|
||||
fabric_version=0.141.2+1.21.11
|
||||
2
gradle/wrapper/gradle-wrapper.properties
vendored
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.2-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-9.3.0-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
||||
@@ -7,6 +7,7 @@ import org.slf4j.LoggerFactory;
|
||||
|
||||
import de.jottyfan.minecraft.block.ModBlocks;
|
||||
import de.jottyfan.minecraft.item.ModItems;
|
||||
import de.jottyfan.minecraft.world.gen.ModOreGeneration;
|
||||
|
||||
public class Gtamfmd implements ModInitializer {
|
||||
public static final String MOD_ID = "gtamfmd";
|
||||
@@ -16,6 +17,7 @@ public class Gtamfmd implements ModInitializer {
|
||||
public void onInitialize() {
|
||||
ModItems.registerModItems();
|
||||
ModBlocks.registerModBlocks();
|
||||
ModOreGeneration.generateOres();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,13 @@
|
||||
package de.jottyfan.minecraft;
|
||||
|
||||
import de.jottyfan.minecraft.block.ModBlocks;
|
||||
import net.fabricmc.api.ClientModInitializer;
|
||||
import net.fabricmc.fabric.api.client.rendering.v1.BlockRenderLayerMap;
|
||||
import net.minecraft.client.render.BlockRenderLayer;
|
||||
|
||||
public class GtamfmdClient implements ClientModInitializer {
|
||||
@Override
|
||||
public void onInitializeClient() {
|
||||
BlockRenderLayerMap.putBlock(ModBlocks.CHRISTMASTREE, BlockRenderLayer.CUTOUT);
|
||||
}
|
||||
}
|
||||
|
||||
49
src/main/java/de/jottyfan/minecraft/block/ChristmasTree.java
Normal file
@@ -0,0 +1,49 @@
|
||||
package de.jottyfan.minecraft.block;
|
||||
|
||||
import de.jottyfan.minecraft.item.ModItems;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.block.SweetBerryBushBlock;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.state.StateManager.Builder;
|
||||
import net.minecraft.state.property.BooleanProperty;
|
||||
import net.minecraft.util.ActionResult;
|
||||
import net.minecraft.util.hit.BlockHitResult;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.WorldView;
|
||||
import net.minecraft.world.event.GameEvent;
|
||||
|
||||
public class ChristmasTree extends SweetBerryBushBlock {
|
||||
public static final BooleanProperty ACTIVATED = BooleanProperty.of("activated");
|
||||
|
||||
public ChristmasTree(Settings settings) {
|
||||
super(settings.ticksRandomly().noCollision().luminance(state -> state.get(ACTIVATED) ? 15 : 0));
|
||||
setDefaultState(getDefaultState().with(ACTIVATED, false));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void appendProperties(Builder<Block, BlockState> builder) {
|
||||
builder.add(ACTIVATED);
|
||||
super.appendProperties(builder);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ItemStack getPickStack(WorldView world, BlockPos pos, BlockState state, boolean includeData) {
|
||||
return new ItemStack(ModItems.GINGERBREAD);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, BlockHitResult hit) {
|
||||
if (state.get(AGE) > 1 && state.get(ACTIVATED)) {
|
||||
dropStack(world, pos, new ItemStack(ModItems.GINGERBREAD));
|
||||
BlockState blockState = state.with(AGE, 0).cycle(ACTIVATED);
|
||||
world.setBlockState(pos, blockState, Block.NOTIFY_LISTENERS);
|
||||
world.emitGameEvent(GameEvent.BLOCK_CHANGE, pos, GameEvent.Emitter.of(player, blockState));
|
||||
} else if (state.get(AGE) <= 1) {
|
||||
world.setBlockState(pos, state.cycle(ACTIVATED));
|
||||
}
|
||||
return ActionResult.SUCCESS;
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,11 @@
|
||||
package de.jottyfan.minecraft.block;
|
||||
|
||||
import java.util.function.Function;
|
||||
|
||||
import de.jottyfan.minecraft.Gtamfmd;
|
||||
import net.fabricmc.fabric.api.itemgroup.v1.ItemGroupEvents;
|
||||
import net.minecraft.block.AbstractBlock;
|
||||
import net.minecraft.block.AbstractBlock.Settings;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.BlockItem;
|
||||
import net.minecraft.item.Item;
|
||||
@@ -11,30 +14,40 @@ import net.minecraft.registry.Registries;
|
||||
import net.minecraft.registry.Registry;
|
||||
import net.minecraft.registry.RegistryKey;
|
||||
import net.minecraft.registry.RegistryKeys;
|
||||
import net.minecraft.sound.BlockSoundGroup;
|
||||
import net.minecraft.util.Identifier;
|
||||
|
||||
public class ModBlocks {
|
||||
|
||||
public static final Block RUBY_BLOCK = registerBlock(Identifier.of(Gtamfmd.MOD_ID, "ruby_block"),
|
||||
AbstractBlock.Settings.create().strength(4f).requiresTool().sounds(BlockSoundGroup.AMETHYST_BLOCK));
|
||||
public static final Block RUBY_BLOCK = registerBlock(Identifier.of(Gtamfmd.MOD_ID, "ruby_block"), x -> new Block(x));
|
||||
public static final Block RUBY_ORE = registerBlock(Identifier.of(Gtamfmd.MOD_ID, "ruby_ore"),
|
||||
x -> new Block(x.strength(4).requiresTool()));
|
||||
public static final Block RUBY_DEEPSLATE_ORE = registerBlock(Identifier.of(Gtamfmd.MOD_ID, "ruby_deepslate_ore"),
|
||||
x -> new Block(x.strength(4).requiresTool()));
|
||||
public static final Block CHRISTMASTREE = registerBlock(Identifier.of(Gtamfmd.MOD_ID, "christmastree"),
|
||||
x -> new ChristmasTree(x));
|
||||
|
||||
private static Block registerBlock(Identifier identifier, Block.Settings settings) {
|
||||
Block block = new Block(settings.registryKey(RegistryKey.of(RegistryKeys.BLOCK, identifier)));
|
||||
registerBlockItem(identifier, block, new Item.Settings());
|
||||
return Registry.register(Registries.BLOCK, identifier, block);
|
||||
}
|
||||
private static Block registerBlock(Identifier identifier, Function<Settings, Block> function) {
|
||||
return registerBlock(identifier, AbstractBlock.Settings.create(), function);
|
||||
}
|
||||
|
||||
private static void registerBlockItem(Identifier identifier, Block block, Item.Settings settings) {
|
||||
Registry.register(Registries.ITEM, identifier, new BlockItem(block,
|
||||
settings.useItemPrefixedTranslationKey().registryKey(RegistryKey.of(RegistryKeys.ITEM, identifier))));
|
||||
}
|
||||
// functional interface
|
||||
private static Block registerBlock(Identifier identifier, Settings settings, Function<Settings, Block> function) {
|
||||
Block block = function.apply(settings.registryKey(RegistryKey.of(RegistryKeys.BLOCK, identifier)));
|
||||
registerBlockItem(identifier, block, new Item.Settings());
|
||||
return Registry.register(Registries.BLOCK, identifier, block);
|
||||
}
|
||||
|
||||
public static void registerModBlocks() {
|
||||
Gtamfmd.LOGGER.info("Registering Mod Blocks for {}", Gtamfmd.MOD_ID);
|
||||
ItemGroupEvents.modifyEntriesEvent(ItemGroups.BUILDING_BLOCKS)
|
||||
.register(entries -> {
|
||||
entries.add(RUBY_BLOCK);
|
||||
});
|
||||
}
|
||||
private static void registerBlockItem(Identifier identifier, Block block, Item.Settings settings) {
|
||||
Registry.register(Registries.ITEM, identifier, new BlockItem(block,
|
||||
settings.useItemPrefixedTranslationKey().registryKey(RegistryKey.of(RegistryKeys.ITEM, identifier))));
|
||||
}
|
||||
|
||||
public static void registerModBlocks() {
|
||||
Gtamfmd.LOGGER.info("Registering Mod Blocks for {}", Gtamfmd.MOD_ID);
|
||||
ItemGroupEvents.modifyEntriesEvent(ItemGroups.BUILDING_BLOCKS).register(entries -> {
|
||||
entries.add(RUBY_BLOCK);
|
||||
entries.add(RUBY_ORE);
|
||||
entries.add(RUBY_DEEPSLATE_ORE);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
20
src/main/java/de/jottyfan/minecraft/item/Food.java
Normal file
@@ -0,0 +1,20 @@
|
||||
package de.jottyfan.minecraft.item;
|
||||
|
||||
import net.minecraft.component.type.FoodComponent;
|
||||
|
||||
public enum Food {
|
||||
GINGERBREAD(new FoodComponent.Builder()
|
||||
.nutrition(1).saturationModifier(0.1f)
|
||||
.build());
|
||||
|
||||
private final FoodComponent component;
|
||||
|
||||
private Food(FoodComponent component) {
|
||||
this.component = component;
|
||||
}
|
||||
|
||||
public FoodComponent get() {
|
||||
return component;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
package de.jottyfan.minecraft.item;
|
||||
|
||||
import java.util.EnumMap;
|
||||
|
||||
import de.jottyfan.minecraft.Gtamfmd;
|
||||
import net.minecraft.item.equipment.ArmorMaterial;
|
||||
import net.minecraft.item.equipment.EquipmentAsset;
|
||||
import net.minecraft.item.equipment.EquipmentType;
|
||||
import net.minecraft.registry.Registry;
|
||||
import net.minecraft.registry.RegistryKey;
|
||||
import net.minecraft.sound.SoundEvents;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.Util;
|
||||
|
||||
public class ModArmorMaterial {
|
||||
public static RegistryKey<? extends Registry<EquipmentAsset>> REGISTRY_KEY = RegistryKey
|
||||
.ofRegistry(Identifier.ofVanilla("equipment_asset"));
|
||||
|
||||
public static final RegistryKey<EquipmentAsset> RUBY_KEY = RegistryKey.of(REGISTRY_KEY,
|
||||
Identifier.of(Gtamfmd.MOD_ID, "ruby"));
|
||||
|
||||
public static final ArmorMaterial RUBY_ARMOR_MATERIAL = new ArmorMaterial(500,
|
||||
Util.make(new EnumMap<>(EquipmentType.class), map -> {
|
||||
map.put(EquipmentType.BOOTS, 3);
|
||||
map.put(EquipmentType.LEGGINGS,4);
|
||||
map.put(EquipmentType.CHESTPLATE, 10);
|
||||
map.put(EquipmentType.HELMET, 3);
|
||||
map.put(EquipmentType.BODY, 5);
|
||||
}), 20, SoundEvents.ITEM_ARMOR_EQUIP_DIAMOND, 0, 0, null, RUBY_KEY);
|
||||
}
|
||||
@@ -5,6 +5,7 @@ import net.fabricmc.fabric.api.itemgroup.v1.ItemGroupEvents;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.Item.Settings;
|
||||
import net.minecraft.item.ItemGroups;
|
||||
import net.minecraft.item.equipment.EquipmentType;
|
||||
import net.minecraft.registry.Registries;
|
||||
import net.minecraft.registry.Registry;
|
||||
import net.minecraft.registry.RegistryKey;
|
||||
@@ -13,10 +14,27 @@ import net.minecraft.util.Identifier;
|
||||
|
||||
public class ModItems {
|
||||
|
||||
public static final Item STUB = registerItem(
|
||||
Identifier.of(Gtamfmd.MOD_ID, "stub"), new Item.Settings());
|
||||
public static final Item RUBY = registerItem(
|
||||
Identifier.of(Gtamfmd.MOD_ID, "ruby"), new Item.Settings());
|
||||
public static final Item STUB = registerStubItem(Identifier.of(Gtamfmd.MOD_ID, "stub"), new Item.Settings());
|
||||
|
||||
public static final Item RUBY = registerItem(Identifier.of(Gtamfmd.MOD_ID, "ruby"), new Item.Settings());
|
||||
public static final Item GINGERBREAD = registerItem(Identifier.of(Gtamfmd.MOD_ID, "gingerbread"),
|
||||
new Item.Settings().food(Food.GINGERBREAD.get()));
|
||||
|
||||
public static final Item RUBY_BOOTS = registerArmorItem("ruby_boots", EquipmentType.BOOTS);
|
||||
public static final Item RUBY_HELMET = registerArmorItem("ruby_helmet", EquipmentType.HELMET);
|
||||
public static final Item RUBY_CHESTPLATE = registerArmorItem("ruby_chestplate", EquipmentType.CHESTPLATE);
|
||||
public static final Item RUBY_LEGGINGS = registerArmorItem("ruby_leggings", EquipmentType.LEGGINGS);
|
||||
|
||||
private static Item registerArmorItem(String name, EquipmentType type) {
|
||||
Identifier identifier = Identifier.of(Gtamfmd.MOD_ID, name);
|
||||
Item.Settings settings = new Item.Settings().maxCount(1).armor(ModArmorMaterial.RUBY_ARMOR_MATERIAL, type);
|
||||
return registerItem(identifier, settings);
|
||||
}
|
||||
|
||||
private static Item registerStubItem(Identifier identifier, Settings settings) {
|
||||
return Registry.register(Registries.ITEM, identifier, new StubItem(
|
||||
settings.useItemPrefixedTranslationKey().registryKey(RegistryKey.of(RegistryKeys.ITEM, identifier))));
|
||||
}
|
||||
|
||||
private static Item registerItem(Identifier identifier, Settings settings) {
|
||||
RegistryKey<Item> registrykey = RegistryKey.of(RegistryKeys.ITEM, identifier);
|
||||
@@ -27,10 +45,14 @@ public class ModItems {
|
||||
public static void registerModItems() {
|
||||
Gtamfmd.LOGGER.info("registering mod items for " + Gtamfmd.MOD_ID);
|
||||
|
||||
ItemGroupEvents.modifyEntriesEvent(ItemGroups.TOOLS)
|
||||
.register(entries -> {
|
||||
entries.add(STUB);
|
||||
entries.add(RUBY);
|
||||
});
|
||||
ItemGroupEvents.modifyEntriesEvent(ItemGroups.TOOLS).register(entries -> {
|
||||
entries.add(STUB);
|
||||
entries.add(RUBY);
|
||||
entries.add(GINGERBREAD);
|
||||
entries.add(RUBY_HELMET);
|
||||
entries.add(RUBY_CHESTPLATE);
|
||||
entries.add(RUBY_LEGGINGS);
|
||||
entries.add(RUBY_BOOTS);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
65
src/main/java/de/jottyfan/minecraft/item/StubItem.java
Normal file
@@ -0,0 +1,65 @@
|
||||
package de.jottyfan.minecraft.item;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.joml.Random;
|
||||
|
||||
import de.jottyfan.minecraft.block.ModBlocks;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.Blocks;
|
||||
import net.minecraft.entity.ItemEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.ItemUsageContext;
|
||||
import net.minecraft.item.Items;
|
||||
import net.minecraft.sound.SoundCategory;
|
||||
import net.minecraft.sound.SoundEvents;
|
||||
import net.minecraft.util.ActionResult;
|
||||
import net.minecraft.util.Hand;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class StubItem extends Item {
|
||||
|
||||
private static final Map<Block, Item> SLASH_MAP = Map.of(
|
||||
Blocks.HAY_BLOCK, Items.WHEAT,
|
||||
Blocks.DRIED_KELP_BLOCK, Items.DRIED_KELP);
|
||||
|
||||
public StubItem(Settings settings) {
|
||||
super(settings);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ActionResult useOnBlock(ItemUsageContext context) {
|
||||
World world = context.getWorld();
|
||||
BlockPos pos = context.getBlockPos();
|
||||
Block clickedBlock = world.getBlockState(pos).getBlock();
|
||||
if (SLASH_MAP.containsKey(clickedBlock)) {
|
||||
if (!world.isClient()) {
|
||||
world.setBlockState(pos, Blocks.AIR.getDefaultState());
|
||||
world.playSound(null, pos, SoundEvents.ITEM_HOE_TILL,
|
||||
SoundCategory.BLOCKS);
|
||||
for (int i = 0; i < 9; i++) {
|
||||
ItemStack stack = new ItemStack(SLASH_MAP.get(clickedBlock));
|
||||
float scatter = new Random().nextFloat();
|
||||
ItemEntity entity = new ItemEntity(world, pos.getX(),
|
||||
pos.getY(), pos.getZ(), stack, scatter, scatter, 0.2);
|
||||
world.spawnEntity(entity);
|
||||
}
|
||||
}
|
||||
} else if (Blocks.DIRT.equals(clickedBlock) && world.getBlockState(pos.up()).isAir()) {
|
||||
if (!world.isClient()) {
|
||||
world.setBlockState(pos.up(), ModBlocks.CHRISTMASTREE.getDefaultState());
|
||||
world.playSound(null, pos, SoundEvents.ITEM_CROP_PLANT,
|
||||
SoundCategory.BLOCKS);
|
||||
Hand hand = context.getHand();
|
||||
PlayerEntity player = context.getPlayer();
|
||||
ItemStack stack = player.getStackInHand(hand);
|
||||
stack.increment(-1);
|
||||
player.setStackInHand(hand, stack);
|
||||
}
|
||||
}
|
||||
return ActionResult.SUCCESS;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
package de.jottyfan.minecraft.world;
|
||||
|
||||
import de.jottyfan.minecraft.Gtamfmd;
|
||||
import net.minecraft.registry.RegistryKey;
|
||||
import net.minecraft.registry.RegistryKeys;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.world.gen.feature.ConfiguredFeature;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jotty
|
||||
*
|
||||
*/
|
||||
public class ModConfiguredFeatures {
|
||||
public static final RegistryKey<ConfiguredFeature<?, ?>> RUBY_ORE_CF = registerKey("ruby_ore_cf");
|
||||
|
||||
private static RegistryKey<ConfiguredFeature<?, ?>> registerKey(String name) {
|
||||
return RegistryKey.of(RegistryKeys.CONFIGURED_FEATURE, Identifier.of(Gtamfmd.MOD_ID, name));
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
package de.jottyfan.minecraft.world;
|
||||
|
||||
import de.jottyfan.minecraft.Gtamfmd;
|
||||
import net.minecraft.registry.RegistryKey;
|
||||
import net.minecraft.registry.RegistryKeys;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.world.gen.feature.PlacedFeature;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jotty
|
||||
*
|
||||
*/
|
||||
public class ModPlacedFeatures {
|
||||
public static final RegistryKey<PlacedFeature> RUBY_ORE_PF = registerKey("ruby_ore_pf");
|
||||
|
||||
private static RegistryKey<PlacedFeature> registerKey(String name) {
|
||||
return RegistryKey.of(RegistryKeys.PLACED_FEATURE, Identifier.of(Gtamfmd.MOD_ID, name));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package de.jottyfan.minecraft.world.gen;
|
||||
|
||||
import de.jottyfan.minecraft.world.ModPlacedFeatures;
|
||||
import net.fabricmc.fabric.api.biome.v1.BiomeModifications;
|
||||
import net.fabricmc.fabric.api.biome.v1.BiomeSelectors;
|
||||
import net.minecraft.world.gen.GenerationStep;
|
||||
|
||||
public class ModOreGeneration {
|
||||
public static void generateOres() {
|
||||
BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(),
|
||||
GenerationStep.Feature.UNDERGROUND_ORES,
|
||||
ModPlacedFeatures.RUBY_ORE_PF);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"variants": {
|
||||
"age=0": { "model": "gtamfmd:block/christmastree0" },
|
||||
"age=1": { "model": "gtamfmd:block/christmastree1" },
|
||||
"age=2": { "model": "gtamfmd:block/christmastree2" },
|
||||
"age=3": { "model": "gtamfmd:block/christmastree3" }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"variants": {
|
||||
"": {
|
||||
"model": "gtamfmd:block/ruby_deepslate_ore"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"variants": {
|
||||
"": {
|
||||
"model": "gtamfmd:block/ruby_ore"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
14
src/main/resources/assets/gtamfmd/equipment/ruby.json
Normal file
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"layers": {
|
||||
"humanoid": [
|
||||
{
|
||||
"texture": "gtamfmd:ruby"
|
||||
}
|
||||
],
|
||||
"humanoid_leggings": [
|
||||
{
|
||||
"texture": "gtamfmd:ruby"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
6
src/main/resources/assets/gtamfmd/items/gingerbread.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:item/gingerbread"
|
||||
}
|
||||
}
|
||||
6
src/main/resources/assets/gtamfmd/items/ruby_boots.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:item/ruby_boots"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:item/ruby_chestplate"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:block/ruby_deepslate_ore"
|
||||
}
|
||||
}
|
||||
6
src/main/resources/assets/gtamfmd/items/ruby_helmet.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:item/ruby_helmet"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:item/ruby_leggings"
|
||||
}
|
||||
}
|
||||
6
src/main/resources/assets/gtamfmd/items/ruby_ore.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"model": {
|
||||
"type": "minecraft:model",
|
||||
"model": "gtamfmd:block/ruby_ore"
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,13 @@
|
||||
{
|
||||
"item.gtamfmd.gingerbread": "Lebkuchen",
|
||||
"item.gtamfmd.stub": "Stummel",
|
||||
"item.gtamfmd.ruby": "Rubin",
|
||||
"item.gtamfmd.ruby_block": "Rubinblock"
|
||||
"item.gtamfmd.ruby_block": "Rubinblock",
|
||||
"item.gtamfmd.ruby_ore": "Rubinerz",
|
||||
"item.gtamfmd.christmastree": "Weihnachtsbaum",
|
||||
"item.gtamfmd.ruby_helmet": "Rubinhelm",
|
||||
"item.gtamfmd.ruby_chestplate": "Rubinbrustpanzer",
|
||||
"item.gtamfmd.ruby_leggings": "Rubinhose",
|
||||
"item.gtamfmd.ruby_boots": "Rubinschuhe",
|
||||
"item.gtamfmd.ruby_deepslate_ore": "Rubinerzklumpen"
|
||||
}
|
||||
|
||||
@@ -1,5 +1,13 @@
|
||||
{
|
||||
"item.gtamfmd.gingerbread": "Gingerbread",
|
||||
"item.gtamfmd.stub": "Stub",
|
||||
"item.gtamfmd.ruby": "Ruby",
|
||||
"item.gtamfmd.ruby_block": "Ruby block"
|
||||
"item.gtamfmd.ruby_block": "Ruby block",
|
||||
"item.gtamfmd.ruby_ore": "Ruby ore",
|
||||
"item.gtamfmd.christmastree": "Christmas tree",
|
||||
"item.gtamfmd.ruby_helmet": "ruby helmet",
|
||||
"item.gtamfmd.ruby_chestplate": "ruby chestplate",
|
||||
"item.gtamfmd.ruby_leggings": "ruby leggings",
|
||||
"item.gtamfmd.ruby_boots": "ruby boots",
|
||||
"item.gtamfmd.ruby_deepslate_ore": "ruby deepslate ore"
|
||||
}
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cross",
|
||||
"textures": {
|
||||
"cross": "gtamfmd:block/christmastree0"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cross",
|
||||
"textures": {
|
||||
"cross": "gtamfmd:block/christmastree1"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cross",
|
||||
"textures": {
|
||||
"cross": "gtamfmd:block/christmastree2"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cross",
|
||||
"textures": {
|
||||
"cross": "gtamfmd:block/christmastree3"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cube_all",
|
||||
"textures": {
|
||||
"all": "gtamfmd:block/ruby_deepslate_ore"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:block/cube_all",
|
||||
"textures": {
|
||||
"all": "gtamfmd:block/ruby_ore"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "minecraft:item/generated",
|
||||
"textures": {
|
||||
"layer0": "gtamfmd:item/gingerbread"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "item/coal",
|
||||
"textures": {
|
||||
"layer0": "gtamfmd:item/ruby_boots"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "item/coal",
|
||||
"textures": {
|
||||
"layer0": "gtamfmd:item/ruby_chestplate"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"parent": "gtamfmd:block/ruby_deepslate_ore"
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "item/coal",
|
||||
"textures": {
|
||||
"layer0": "gtamfmd:item/ruby_helmet"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"parent": "item/coal",
|
||||
"textures": {
|
||||
"layer0": "gtamfmd:item/ruby_leggings"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"parent": "gtamfmd:block/ruby_ore"
|
||||
}
|
||||
|
After Width: | Height: | Size: 295 B |
|
After Width: | Height: | Size: 542 B |
|
After Width: | Height: | Size: 543 B |
|
After Width: | Height: | Size: 580 B |
|
After Width: | Height: | Size: 5.1 KiB |
BIN
src/main/resources/assets/gtamfmd/textures/block/ruby_ore.png
Normal file
|
After Width: | Height: | Size: 4.9 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 730 B |
BIN
src/main/resources/assets/gtamfmd/textures/item/gingerbread.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
BIN
src/main/resources/assets/gtamfmd/textures/item/ruby_boots.png
Normal file
|
After Width: | Height: | Size: 366 B |
|
After Width: | Height: | Size: 465 B |
BIN
src/main/resources/assets/gtamfmd/textures/item/ruby_helmet.png
Normal file
|
After Width: | Height: | Size: 396 B |
|
After Width: | Height: | Size: 379 B |
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"type": "minecraft:block",
|
||||
"pools": [
|
||||
{
|
||||
"bonus_rolls": 0.0,
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:survives_explosion"
|
||||
}
|
||||
],
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "gtamfmd:ruby"
|
||||
}
|
||||
],
|
||||
"rolls": 9.0
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"type": "minecraft:block",
|
||||
"pools": [
|
||||
{
|
||||
"bonus_rolls": 0.0,
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:survives_explosion"
|
||||
}
|
||||
],
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "gtamfmd:ruby_ore"
|
||||
}
|
||||
],
|
||||
"rolls": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"type": "minecraft:block",
|
||||
"pools": [
|
||||
{
|
||||
"bonus_rolls": 0.0,
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:survives_explosion"
|
||||
}
|
||||
],
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": "gtamfmd:ruby"
|
||||
}
|
||||
],
|
||||
"rolls": 1.0
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"type": "minecraft:blasting",
|
||||
"ingredient": "gtamfmd:ruby_ore",
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby"
|
||||
},
|
||||
"experience": 0.1,
|
||||
"cookingtime": 200
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"type": "minecraft:campfire_cooking",
|
||||
"ingredient": "gtamfmd:stub",
|
||||
"result": {
|
||||
"id": "minecraft:torch"
|
||||
},
|
||||
"experience": 0.1,
|
||||
"cookingtime": 20
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"# #",
|
||||
"###",
|
||||
" # "
|
||||
],
|
||||
"key": {
|
||||
"#": "minecraft:wheat"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:gingerbread",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"t t",
|
||||
"t t"
|
||||
],
|
||||
"key": {
|
||||
"t": "gtamfmd:ruby"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby_boots",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"t t",
|
||||
"ttt",
|
||||
"ttt"
|
||||
],
|
||||
"key": {
|
||||
"t": "gtamfmd:ruby"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby_chestplate",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"ttt",
|
||||
"t t"
|
||||
],
|
||||
"key": {
|
||||
"t": "gtamfmd:ruby"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby_helmet",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"ttt",
|
||||
"t t",
|
||||
"t t"
|
||||
],
|
||||
"key": {
|
||||
"t": "gtamfmd:ruby"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby_leggings",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
"###",
|
||||
"###",
|
||||
"###"
|
||||
],
|
||||
"key": {
|
||||
"#": "gtamfmd:ruby"
|
||||
},
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby_block",
|
||||
"count": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shapeless",
|
||||
"ingredients": [
|
||||
"gtamfmd:ruby_block"
|
||||
],
|
||||
"result": {
|
||||
"id": "gtamfmd:ruby",
|
||||
"count": 9
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"type": "minecraft:crafting_shapeless",
|
||||
"ingredients": [
|
||||
"minecraft:stick"
|
||||
],
|
||||
"result": {
|
||||
"id": "gtamfmd:stub",
|
||||
"count": 4
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
{ "type": "minecraft:ore",
|
||||
"config": {
|
||||
"discard_chance_on_air_exposure": 0.0,
|
||||
"size": 20,
|
||||
"targets": [
|
||||
{
|
||||
"state": { "Name": "gtamfmd:ruby_ore" },
|
||||
"target": {
|
||||
"predicate_type": "minecraft:tag_match",
|
||||
"tag": "minecraft:stone_ore_replaceables"
|
||||
}
|
||||
}, {
|
||||
"state": { "Name": "gtamfmd:ruby_deepslate_ore" },
|
||||
"target": {
|
||||
"predicate_type": "minecraft:tag_match",
|
||||
"tag": "minecraft:deepslate_ore_replaceables"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
{
|
||||
"feature": "gtamfmd:ruby_ore_cf",
|
||||
"placement": [
|
||||
{
|
||||
"type": "minecraft:count",
|
||||
"count": 16
|
||||
},
|
||||
{
|
||||
"type": "minecraft:in_square"
|
||||
},
|
||||
{
|
||||
"type": "minecraft:height_range",
|
||||
"height": {
|
||||
"type": "minecraft:trapezoid",
|
||||
"max_inclusive": {
|
||||
"absolute": 80
|
||||
},
|
||||
"min_inclusive": {
|
||||
"absolute": -80
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "minecraft:biome"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
"gtamfmd:ruby_block",
|
||||
"gtamfmd:ruby_ore",
|
||||
"gtamfmd:ruby_deepslate_ore"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"replace": false,
|
||||
"values": [
|
||||
"gtamfmd:ruby_block",
|
||||
"gtamfmd:ruby_ore",
|
||||
"gtamfmd:ruby_deepslate_ore"
|
||||
]
|
||||
}
|
||||
@@ -26,8 +26,8 @@
|
||||
"gtamfmd.mixins.json"
|
||||
],
|
||||
"depends": {
|
||||
"fabricloader": ">=0.16.14",
|
||||
"minecraft": "~1.21.8",
|
||||
"fabricloader": ">=0.18.4",
|
||||
"minecraft": "~1.21.11",
|
||||
"java": ">=21",
|
||||
"fabric-api": "*"
|
||||
},
|
||||
|
||||