Compare commits
4
Commits
main
..
e5e971da61
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e5e971da61 | ||
|
|
f104344b96 | ||
|
|
abf5f4db3f | ||
|
|
074a85343b |
@@ -1,5 +1,5 @@
|
|||||||
#
|
#
|
||||||
#Mon Jul 20 21:22:00 CEST 2026
|
#Mon Dec 22 18:46:51 CET 2025
|
||||||
eclipse.preferences.version=1
|
eclipse.preferences.version=1
|
||||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=25
|
org.eclipse.jdt.core.compiler.codegen.targetPlatform=25
|
||||||
|
|||||||
+23
-10
@@ -1,5 +1,5 @@
|
|||||||
plugins {
|
plugins {
|
||||||
id 'net.fabricmc.fabric-loom'
|
id 'net.fabricmc.fabric-loom' version "${loom_version}"
|
||||||
id 'maven-publish'
|
id 'maven-publish'
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -11,17 +11,22 @@ base {
|
|||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
maven {
|
// Add repositories to retrieve artifacts from in here.
|
||||||
name = 'Fabric'
|
// You should only use this when depending on other mods because
|
||||||
url = 'https://maven.fabricmc.net/'
|
// Loom adds the essential maven repositories to download Minecraft and libraries from automatically.
|
||||||
}
|
// See https://docs.gradle.org/current/userguide/declaring_repositories.html
|
||||||
mavenCentral()
|
// for more information about repositories.
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
// To change the versions see the gradle.properties file
|
||||||
minecraft "com.mojang:minecraft:${project.minecraft_version}"
|
minecraft "com.mojang:minecraft:${project.minecraft_version}"
|
||||||
|
|
||||||
implementation "net.fabricmc:fabric-loader:${project.loader_version}"
|
implementation "net.fabricmc:fabric-loader:${project.loader_version}"
|
||||||
|
|
||||||
|
// Fabric API. This is technically optional, but you probably want it anyway.
|
||||||
implementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_api_version}"
|
implementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_api_version}"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
processResources {
|
processResources {
|
||||||
@@ -32,27 +37,29 @@ processResources {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fabricApi {
|
|
||||||
configureDataGeneration()
|
|
||||||
}
|
|
||||||
|
|
||||||
tasks.withType(JavaCompile).configureEach {
|
tasks.withType(JavaCompile).configureEach {
|
||||||
it.options.release = 25
|
it.options.release = 25
|
||||||
}
|
}
|
||||||
|
|
||||||
java {
|
java {
|
||||||
|
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
|
||||||
|
// if it is present.
|
||||||
|
// If you remove this line, sources will not be generated.
|
||||||
withSourcesJar()
|
withSourcesJar()
|
||||||
|
|
||||||
sourceCompatibility = JavaVersion.VERSION_25
|
sourceCompatibility = JavaVersion.VERSION_25
|
||||||
targetCompatibility = JavaVersion.VERSION_25
|
targetCompatibility = JavaVersion.VERSION_25
|
||||||
}
|
}
|
||||||
|
|
||||||
jar {
|
jar {
|
||||||
inputs.property "archivesName", project.base.archivesName
|
inputs.property "archivesName", project.base.archivesName
|
||||||
|
|
||||||
from("LICENSE") {
|
from("LICENSE") {
|
||||||
rename { "${it}_${inputs.properties.archivesName}"}
|
rename { "${it}_${inputs.properties.archivesName}"}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// configure the maven publication
|
||||||
publishing {
|
publishing {
|
||||||
publications {
|
publications {
|
||||||
create("mavenJava", MavenPublication) {
|
create("mavenJava", MavenPublication) {
|
||||||
@@ -60,6 +67,12 @@ publishing {
|
|||||||
from components.java
|
from components.java
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
|
||||||
repositories {
|
repositories {
|
||||||
|
// Add repositories to publish to here.
|
||||||
|
// Notice: This block does NOT have the same function as the block in the top level.
|
||||||
|
// The repositories here will be used for publishing your artifact, not for
|
||||||
|
// retrieving dependencies.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+5
-5
@@ -7,14 +7,14 @@ org.gradle.configuration-cache=false
|
|||||||
|
|
||||||
# Fabric Properties
|
# Fabric Properties
|
||||||
# check these on https://fabricmc.net/develop
|
# check these on https://fabricmc.net/develop
|
||||||
minecraft_version=26.3-snapshot-5
|
minecraft_version=26.1.2
|
||||||
loader_version=0.19.3
|
loader_version=0.19.2
|
||||||
loom_version=1.17-SNAPSHOT
|
loom_version=1.15-SNAPSHOT
|
||||||
|
|
||||||
# Mod Properties
|
# Mod Properties
|
||||||
mod_version=26.3.0-snapshot-4
|
mod_version=26.1.2.2
|
||||||
maven_group=de.jottyfan.minecraft
|
maven_group=de.jottyfan.minecraft
|
||||||
archives_base_name=quickly
|
archives_base_name=quickly
|
||||||
|
|
||||||
# Dependencies
|
# Dependencies
|
||||||
fabric_api_version=0.155.3+26.3
|
fabric_api_version=0.146.1+26.1.2
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-9.5.1-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-9.2.1-bin.zip
|
||||||
networkTimeout=10000
|
networkTimeout=10000
|
||||||
validateDistributionUrl=true
|
validateDistributionUrl=true
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
|
|||||||
@@ -7,7 +7,4 @@ pluginManagement {
|
|||||||
mavenCentral()
|
mavenCentral()
|
||||||
gradlePluginPortal()
|
gradlePluginPortal()
|
||||||
}
|
}
|
||||||
plugins {
|
|
||||||
id 'net.fabricmc.fabric-loom' version "${loom_version}"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
@@ -7,14 +7,15 @@ import org.apache.logging.log4j.Logger;
|
|||||||
|
|
||||||
import de.jottyfan.minecraft.block.QuicklyBlocks;
|
import de.jottyfan.minecraft.block.QuicklyBlocks;
|
||||||
import de.jottyfan.minecraft.blockentity.QuicklyBlockEntity;
|
import de.jottyfan.minecraft.blockentity.QuicklyBlockEntity;
|
||||||
|
import de.jottyfan.minecraft.composter.QuicklyComposter;
|
||||||
import de.jottyfan.minecraft.event.QuicklyEvents;
|
import de.jottyfan.minecraft.event.QuicklyEvents;
|
||||||
import de.jottyfan.minecraft.feature.QuicklyFeatures;
|
import de.jottyfan.minecraft.feature.QuicklyFeatures;
|
||||||
import de.jottyfan.minecraft.item.QuicklyItems;
|
import de.jottyfan.minecraft.item.QuicklyItems;
|
||||||
|
import de.jottyfan.minecraft.loot.QuicklyLootTables;
|
||||||
import de.jottyfan.minecraft.tab.QuicklyTab;
|
import de.jottyfan.minecraft.tab.QuicklyTab;
|
||||||
import net.fabricmc.api.ModInitializer;
|
import net.fabricmc.api.ModInitializer;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.Item;
|
||||||
import net.minecraft.world.level.block.Block;
|
import net.minecraft.world.level.block.Block;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author jotty
|
* @author jotty
|
||||||
@@ -29,11 +30,13 @@ public class Quickly implements ModInitializer {
|
|||||||
public void onInitialize() {
|
public void onInitialize() {
|
||||||
LOGGER.info("loading {}", MOD_ID);
|
LOGGER.info("loading {}", MOD_ID);
|
||||||
|
|
||||||
List<Item> items = QuicklyItems.registeredModItems();
|
List<Item> items = QuicklyItems.registerModItems();
|
||||||
List<Block> blocks = QuicklyBlocks.registeredModBlocks();
|
List<Block> blocks = QuicklyBlocks.registerModBlocks();
|
||||||
QuicklyBlockEntity.registerBlockEntities();
|
QuicklyBlockEntity.registerBlockEntities();
|
||||||
QuicklyFeatures.registerFeatures();
|
QuicklyFeatures.registerFeatures();
|
||||||
|
QuicklyComposter.registerComposterItems();
|
||||||
QuicklyTab.registerItemGroup(items, blocks);
|
QuicklyTab.registerItemGroup(items, blocks);
|
||||||
|
QuicklyLootTables.registerChanges();
|
||||||
QuicklyEvents.registerBlockBreak();
|
QuicklyEvents.registerBlockBreak();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -30,7 +30,6 @@ import net.minecraft.world.level.block.FallingBlock;
|
|||||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntityTicker;
|
import net.minecraft.world.level.block.entity.BlockEntityTicker;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntityType;
|
import net.minecraft.world.level.block.entity.BlockEntityType;
|
||||||
import net.minecraft.world.level.block.state.BlockBehaviour;
|
|
||||||
import net.minecraft.world.level.block.state.BlockState;
|
import net.minecraft.world.level.block.state.BlockState;
|
||||||
import net.minecraft.world.level.block.state.StateDefinition.Builder;
|
import net.minecraft.world.level.block.state.StateDefinition.Builder;
|
||||||
import net.minecraft.world.level.block.state.properties.BlockStateProperties;
|
import net.minecraft.world.level.block.state.properties.BlockStateProperties;
|
||||||
@@ -45,9 +44,7 @@ import net.minecraft.world.phys.BlockHitResult;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class BlockDrill extends FallingBlock implements EntityBlock {
|
public class BlockDrill extends FallingBlock implements EntityBlock {
|
||||||
public static final MapCodec<BlockDrill> CODEC = MapCodec.unit(() -> new BlockDrill(
|
public static final MapCodec<BlockDrill> CODEC = simpleCodec(BlockDrill::new);
|
||||||
BlockBehaviour.Properties.of()
|
|
||||||
));
|
|
||||||
|
|
||||||
private static final Integer MAX_FUEL = 255;
|
private static final Integer MAX_FUEL = 255;
|
||||||
public static final IntegerProperty FUEL = IntegerProperty.create("fuel", 0, MAX_FUEL);
|
public static final IntegerProperty FUEL = IntegerProperty.create("fuel", 0, MAX_FUEL);
|
||||||
@@ -134,6 +131,11 @@ public class BlockDrill extends FallingBlock implements EntityBlock {
|
|||||||
return InteractionResult.SUCCESS;
|
return InteractionResult.SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected MapCodec<? extends FallingBlock> codec() {
|
||||||
|
return CODEC;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getDustColor(BlockState blockState, BlockGetter level, BlockPos pos) {
|
public int getDustColor(BlockState blockState, BlockGetter level, BlockPos pos) {
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ import net.minecraft.world.level.block.EntityBlock;
|
|||||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntityTicker;
|
import net.minecraft.world.level.block.entity.BlockEntityTicker;
|
||||||
import net.minecraft.world.level.block.entity.BlockEntityType;
|
import net.minecraft.world.level.block.entity.BlockEntityType;
|
||||||
import net.minecraft.world.level.block.state.BlockBehaviour;
|
|
||||||
import net.minecraft.world.level.block.state.BlockState;
|
import net.minecraft.world.level.block.state.BlockState;
|
||||||
import net.minecraft.world.level.block.state.StateDefinition;
|
import net.minecraft.world.level.block.state.StateDefinition;
|
||||||
import net.minecraft.world.level.block.state.properties.EnumProperty;
|
import net.minecraft.world.level.block.state.properties.EnumProperty;
|
||||||
@@ -30,9 +29,7 @@ import net.minecraft.world.level.storage.loot.LootParams.Builder;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class BlockStacker extends Block implements EntityBlock {
|
public class BlockStacker extends Block implements EntityBlock {
|
||||||
public static final MapCodec<BlockDrill> CODEC = MapCodec.unit(() -> new BlockDrill(
|
public static final MapCodec<BlockStacker> CODEC = simpleCodec(BlockStacker::new);
|
||||||
BlockBehaviour.Properties.of()
|
|
||||||
));
|
|
||||||
|
|
||||||
public static final EnumProperty<Direction> SOURCE = EnumProperty.create("source", Direction.class, Direction.NORTH,
|
public static final EnumProperty<Direction> SOURCE = EnumProperty.create("source", Direction.class, Direction.NORTH,
|
||||||
Direction.EAST, Direction.SOUTH, Direction.WEST, Direction.UP, Direction.DOWN);
|
Direction.EAST, Direction.SOUTH, Direction.WEST, Direction.UP, Direction.DOWN);
|
||||||
@@ -73,7 +70,7 @@ public class BlockStacker extends Block implements EntityBlock {
|
|||||||
return new BlockStackerEntity(pos, blockState);
|
return new BlockStackerEntity(pos, blockState);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected MapCodec<? extends Block> codec() {
|
public static MapCodec<BlockStacker> getCodec() {
|
||||||
return CODEC;
|
return CODEC;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ public class QuicklyBlocks {
|
|||||||
return BuiltInRegistries.BLOCK.getValue(identifier);
|
return BuiltInRegistries.BLOCK.getValue(identifier);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final List<Block> registeredModBlocks() {
|
public static final List<Block> registerModBlocks() {
|
||||||
Quickly.LOGGER.debug("register blocks");
|
Quickly.LOGGER.debug("register blocks");
|
||||||
List<Block> set = new ArrayList<>();
|
List<Block> set = new ArrayList<>();
|
||||||
set.add(KELPBUNDLE);
|
set.add(KELPBUNDLE);
|
||||||
|
|||||||
@@ -3,17 +3,11 @@ package de.jottyfan.minecraft.blockentity;
|
|||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import org.jspecify.annotations.Nullable;
|
|
||||||
|
|
||||||
import com.mojang.serialization.Codec;
|
import com.mojang.serialization.Codec;
|
||||||
|
|
||||||
import de.jottyfan.minecraft.Quickly;
|
import de.jottyfan.minecraft.Quickly;
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.core.Direction;
|
import net.minecraft.core.Direction;
|
||||||
import net.minecraft.core.HolderLookup.Provider;
|
|
||||||
import net.minecraft.nbt.CompoundTag;
|
|
||||||
import net.minecraft.network.protocol.Packet;
|
|
||||||
import net.minecraft.network.protocol.game.ClientGamePacketListener;
|
|
||||||
import net.minecraft.world.Container;
|
import net.minecraft.world.Container;
|
||||||
import net.minecraft.world.entity.Entity;
|
import net.minecraft.world.entity.Entity;
|
||||||
import net.minecraft.world.entity.item.ItemEntity;
|
import net.minecraft.world.entity.item.ItemEntity;
|
||||||
@@ -35,7 +29,7 @@ import net.minecraft.world.phys.AABB;
|
|||||||
public class ItemHoarderBlockEntity extends BlockEntity implements Container {
|
public class ItemHoarderBlockEntity extends BlockEntity implements Container {
|
||||||
|
|
||||||
public static final Codec<Map<String, ItemStack>> ITEM_STACK_MAP_CODEC =
|
public static final Codec<Map<String, ItemStack>> ITEM_STACK_MAP_CODEC =
|
||||||
Codec.unboundedMap(Codec.STRING, ItemStack.OPTIONAL_CODEC);
|
Codec.unboundedMap(Codec.STRING, ItemStack.CODEC);
|
||||||
|
|
||||||
private Map<String, ItemStack> stacks = new HashMap<>();
|
private Map<String, ItemStack> stacks = new HashMap<>();
|
||||||
private static final Integer suckradius = 4;
|
private static final Integer suckradius = 4;
|
||||||
@@ -46,7 +40,7 @@ public class ItemHoarderBlockEntity extends BlockEntity implements Container {
|
|||||||
|
|
||||||
public final static boolean setStackToSlots(ItemStack stack, Map<String, ItemStack> stacks) {
|
public final static boolean setStackToSlots(ItemStack stack, Map<String, ItemStack> stacks) {
|
||||||
if (stack.isEmpty()) {
|
if (stack.isEmpty()) {
|
||||||
Quickly.LOGGER.error("FATAL!!! tried to set empty stack. Check your code!");
|
Quickly.LOGGER.info("FATAL!!! tried to set empty stack. Check your code!");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
String key = stack.getItemName().getString();
|
String key = stack.getItemName().getString();
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package de.jottyfan.minecraft.composter;
|
||||||
|
|
||||||
|
import de.jottyfan.minecraft.item.QuicklyItems;
|
||||||
|
import net.fabricmc.fabric.api.registry.CompostableRegistry;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author jotty
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
public class QuicklyComposter {
|
||||||
|
|
||||||
|
public static final void registerComposterItems() {
|
||||||
|
CompostableRegistry.INSTANCE.add(QuicklyItems.COTTONSEED, 0.5f);
|
||||||
|
CompostableRegistry.INSTANCE.add(QuicklyItems.COTTON, 0.75f);
|
||||||
|
CompostableRegistry.INSTANCE.add(QuicklyItems.CANOLASEED, 0.5f);
|
||||||
|
CompostableRegistry.INSTANCE.add(QuicklyItems.CANOLA, 0.75f);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -7,6 +7,7 @@ import net.minecraft.core.registries.Registries;
|
|||||||
import net.minecraft.resources.Identifier;
|
import net.minecraft.resources.Identifier;
|
||||||
import net.minecraft.resources.ResourceKey;
|
import net.minecraft.resources.ResourceKey;
|
||||||
import net.minecraft.world.level.levelgen.GenerationStep;
|
import net.minecraft.world.level.levelgen.GenerationStep;
|
||||||
|
import net.minecraft.world.level.levelgen.feature.ConfiguredFeature;
|
||||||
import net.minecraft.world.level.levelgen.placement.PlacedFeature;
|
import net.minecraft.world.level.levelgen.placement.PlacedFeature;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -15,15 +16,15 @@ import net.minecraft.world.level.levelgen.placement.PlacedFeature;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class QuicklyFeatures {
|
public class QuicklyFeatures {
|
||||||
public static final ResourceKey<?> CF_ORETURQUOISE = genCf("oreturquoise");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORETURQUOISE = genCf("oreturquoise");
|
||||||
public static final ResourceKey<?> CF_ORESULFOR = genCf("oresulfor");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORESULFOR = genCf("oresulfor");
|
||||||
public static final ResourceKey<?> CF_OREDEEPSLATESULFUR = genCf("oredepslatesulfor");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_OREDEEPSLATESULFUR = genCf("oredepslatesulfor");
|
||||||
public static final ResourceKey<?> CF_ORESALPETER = genCf("oresalpeter");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORESALPETER = genCf("oresalpeter");
|
||||||
public static final ResourceKey<?> CF_ORENETHERSULFOR = genCf("orenethersulfor");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORENETHERSULFOR = genCf("orenethersulfor");
|
||||||
public static final ResourceKey<?> CF_DIRTSALPETER = genCf("dirtsalpeter");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_DIRTSALPETER = genCf("dirtsalpeter");
|
||||||
public static final ResourceKey<?> CF_SANDSALPETER = genCf("sandsalpeter");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_SANDSALPETER = genCf("sandsalpeter");
|
||||||
public static final ResourceKey<?> CF_ORESANDSALPETER = genCf("oresandsalpeter");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORESANDSALPETER = genCf("oresandsalpeter");
|
||||||
public static final ResourceKey<?> CF_ORESPEEDPOWDER = genCf("orespeedpowder");
|
public static final ResourceKey<ConfiguredFeature<?, ?>> CF_ORESPEEDPOWDER = genCf("orespeedpowder");
|
||||||
|
|
||||||
public static final ResourceKey<PlacedFeature> PF_ORETURQUOISE = genPf("oreturquoise");
|
public static final ResourceKey<PlacedFeature> PF_ORETURQUOISE = genPf("oreturquoise");
|
||||||
public static final ResourceKey<PlacedFeature> PF_ORESULFOR = genPf("oresulfor");
|
public static final ResourceKey<PlacedFeature> PF_ORESULFOR = genPf("oresulfor");
|
||||||
@@ -35,8 +36,8 @@ public class QuicklyFeatures {
|
|||||||
public static final ResourceKey<PlacedFeature> PF_ORESANDSALPETER = genPf("oresandsalpeter");
|
public static final ResourceKey<PlacedFeature> PF_ORESANDSALPETER = genPf("oresandsalpeter");
|
||||||
public static final ResourceKey<PlacedFeature> PF_ORESPEEDPOWDER = genPf("orespeedpowder");
|
public static final ResourceKey<PlacedFeature> PF_ORESPEEDPOWDER = genPf("orespeedpowder");
|
||||||
|
|
||||||
private static final ResourceKey<?> genCf(String name) {
|
private static final ResourceKey<ConfiguredFeature<?, ?>> genCf(String name) {
|
||||||
return ResourceKey.create(Registries.FEATURE, Identifier.fromNamespaceAndPath(Quickly.MOD_ID, name));
|
return ResourceKey.create(Registries.CONFIGURED_FEATURE, Identifier.fromNamespaceAndPath(Quickly.MOD_ID, name));
|
||||||
}
|
}
|
||||||
|
|
||||||
private static final ResourceKey<PlacedFeature> genPf(String name) {
|
private static final ResourceKey<PlacedFeature> genPf(String name) {
|
||||||
|
|||||||
@@ -5,8 +5,10 @@ import java.util.List;
|
|||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
|
|
||||||
import net.minecraft.tags.BlockTags;
|
import net.minecraft.tags.BlockTags;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.tags.ItemTags;
|
||||||
|
import net.minecraft.world.item.AxeItem;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
|
import net.minecraft.world.item.ToolMaterial;
|
||||||
import net.minecraft.world.level.ItemLike;
|
import net.minecraft.world.level.ItemLike;
|
||||||
import net.minecraft.world.level.block.Block;
|
import net.minecraft.world.level.block.Block;
|
||||||
import net.minecraft.world.level.block.LeavesBlock;
|
import net.minecraft.world.level.block.LeavesBlock;
|
||||||
@@ -17,12 +19,12 @@ import net.minecraft.world.level.block.state.BlockState;
|
|||||||
* @author jotty
|
* @author jotty
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class QAxe extends Item implements ToolRangeable {
|
public class QAxe extends AxeItem implements ToolRangeable {
|
||||||
|
|
||||||
private final HarvestRange range;
|
private final HarvestRange range;
|
||||||
|
|
||||||
public QAxe(QIP properties) {
|
public QAxe(QIP properties) {
|
||||||
super(properties);
|
super(new ToolMaterial(BlockTags.INCORRECT_FOR_DIAMOND_TOOL, properties.getDurability(), 7f, 1f, 15, ItemTags.DIAMOND_TOOL_MATERIALS), 7f, 3.1f, properties);
|
||||||
this.range = properties.getHarvestRange();
|
this.range = properties.getHarvestRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -7,9 +7,11 @@ import com.google.common.collect.Lists;
|
|||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.core.Direction;
|
import net.minecraft.core.Direction;
|
||||||
import net.minecraft.server.level.ServerLevel;
|
import net.minecraft.server.level.ServerLevel;
|
||||||
|
import net.minecraft.tags.BlockTags;
|
||||||
|
import net.minecraft.tags.ItemTags;
|
||||||
import net.minecraft.world.Containers;
|
import net.minecraft.world.Containers;
|
||||||
import net.minecraft.world.InteractionResult;
|
import net.minecraft.world.InteractionResult;
|
||||||
import net.minecraft.world.item.Item;
|
import net.minecraft.world.item.HoeItem;
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
import net.minecraft.world.item.ToolMaterial;
|
import net.minecraft.world.item.ToolMaterial;
|
||||||
import net.minecraft.world.item.context.UseOnContext;
|
import net.minecraft.world.item.context.UseOnContext;
|
||||||
@@ -21,18 +23,18 @@ import net.minecraft.world.level.block.state.BlockState;
|
|||||||
import net.minecraft.world.level.storage.loot.LootParams;
|
import net.minecraft.world.level.storage.loot.LootParams;
|
||||||
import net.minecraft.world.level.storage.loot.parameters.LootContextParams;
|
import net.minecraft.world.level.storage.loot.parameters.LootContextParams;
|
||||||
import net.minecraft.world.phys.BlockHitResult;
|
import net.minecraft.world.phys.BlockHitResult;
|
||||||
import net.minecraft.world.phys.Vec3;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author jotty
|
* @author jotty
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class QHoe extends Item implements ToolRangeable {
|
public class QHoe extends HoeItem implements ToolRangeable {
|
||||||
public QIP properties;
|
public QIP properties;
|
||||||
|
|
||||||
public QHoe(QIP properties) {
|
public QHoe(QIP properties) {
|
||||||
super(properties.hoe(ToolMaterial.DIAMOND, 0.0f, -3.0f));
|
super(new ToolMaterial(BlockTags.INCORRECT_FOR_DIAMOND_TOOL, properties.getDurability(), 7f, 1f, 15,
|
||||||
|
ItemTags.DIAMOND_TOOL_MATERIALS), 7f, 3.1f, properties);
|
||||||
this.properties = properties;
|
this.properties = properties;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -48,7 +50,7 @@ public class QHoe extends Item implements ToolRangeable {
|
|||||||
for (int z = -range.getzRange(); z <= range.getzRange(); z++) {
|
for (int z = -range.getzRange(); z <= range.getzRange(); z++) {
|
||||||
if (!isCrop) {
|
if (!isCrop) {
|
||||||
removePossibleGrass(context.getLevel(), new BlockPos(x, y, z));
|
removePossibleGrass(context.getLevel(), new BlockPos(x, y, z));
|
||||||
BlockHitResult bhr = new BlockHitResult(Vec3.atCenterOf(context.getClickedPos()), Direction.UP,
|
BlockHitResult bhr = new BlockHitResult(context.getClickedPos().getCenter(), Direction.UP,
|
||||||
context.getClickedPos().offset(x, y, z), false);
|
context.getClickedPos().offset(x, y, z), false);
|
||||||
UseOnContext ctx = new UseOnContext(context.getPlayer(), context.getHand(), bhr);
|
UseOnContext ctx = new UseOnContext(context.getPlayer(), context.getHand(), bhr);
|
||||||
super.useOn(ctx);
|
super.useOn(ctx);
|
||||||
@@ -79,7 +81,7 @@ public class QHoe extends Item implements ToolRangeable {
|
|||||||
if (block instanceof CropBlock cBlock) {
|
if (block instanceof CropBlock cBlock) {
|
||||||
if (cBlock.isMaxAge(blockState)) {
|
if (cBlock.isMaxAge(blockState)) {
|
||||||
LootParams.Builder builder = new LootParams.Builder((ServerLevel) level)
|
LootParams.Builder builder = new LootParams.Builder((ServerLevel) level)
|
||||||
.withParameter(LootContextParams.ORIGIN, Vec3.atCenterOf(pos))
|
.withParameter(LootContextParams.ORIGIN, pos.getCenter())
|
||||||
.withParameter(LootContextParams.BLOCK_STATE, blockState)
|
.withParameter(LootContextParams.BLOCK_STATE, blockState)
|
||||||
.withOptionalParameter(LootContextParams.BLOCK_ENTITY, level.getBlockEntity(pos))
|
.withOptionalParameter(LootContextParams.BLOCK_ENTITY, level.getBlockEntity(pos))
|
||||||
.withParameter(LootContextParams.TOOL, ItemStack.EMPTY);
|
.withParameter(LootContextParams.TOOL, ItemStack.EMPTY);
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
package de.jottyfan.minecraft.item;
|
package de.jottyfan.minecraft.item;
|
||||||
|
|
||||||
import net.minecraft.core.component.DataComponents;
|
import net.minecraft.core.component.DataComponents;
|
||||||
import net.minecraft.server.level.ServerLevel;
|
|
||||||
import net.minecraft.world.InteractionHand;
|
import net.minecraft.world.InteractionHand;
|
||||||
import net.minecraft.world.InteractionResult;
|
import net.minecraft.world.InteractionResult;
|
||||||
import net.minecraft.world.entity.LivingEntity;
|
import net.minecraft.world.entity.LivingEntity;
|
||||||
@@ -16,10 +15,6 @@ import net.minecraft.world.item.Item;
|
|||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
import net.minecraft.world.item.Items;
|
import net.minecraft.world.item.Items;
|
||||||
import net.minecraft.world.item.ShearsItem;
|
import net.minecraft.world.item.ShearsItem;
|
||||||
import net.minecraft.world.level.storage.loot.LootParams;
|
|
||||||
import net.minecraft.world.level.storage.loot.LootTable;
|
|
||||||
import net.minecraft.world.level.storage.loot.parameters.LootContextParamSets;
|
|
||||||
import net.minecraft.world.level.storage.loot.parameters.LootContextParams;
|
|
||||||
import net.minecraft.world.phys.Vec3;
|
import net.minecraft.world.phys.Vec3;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -45,24 +40,38 @@ public class QShears extends ShearsItem {
|
|||||||
sheep.setSheared(true);
|
sheep.setSheared(true);
|
||||||
sheep.playAmbientSound();
|
sheep.playAmbientSound();
|
||||||
DyeColor color = sheep.getColor();
|
DyeColor color = sheep.getColor();
|
||||||
Item item = switch (color) {
|
Item item = Items.WHITE_WOOL;
|
||||||
case BLACK -> Items.WOOL.black();
|
if (color.equals(DyeColor.BLACK)) {
|
||||||
case GRAY -> Items.WOOL.gray();
|
item = Items.BLACK_WOOL;
|
||||||
case LIGHT_GRAY -> Items.WOOL.lightGray();
|
} else if (color.equals(DyeColor.GRAY)) {
|
||||||
case BROWN -> Items.WOOL.brown();
|
item = Items.GRAY_WOOL;
|
||||||
case BLUE -> Items.WOOL.blue();
|
} else if (color.equals(DyeColor.LIGHT_GRAY)) {
|
||||||
case LIGHT_BLUE -> Items.WOOL.lightBlue();
|
item = Items.LIGHT_GRAY_WOOL;
|
||||||
case GREEN -> Items.WOOL.green();
|
} else if (color.equals(DyeColor.BROWN)) {
|
||||||
case LIME -> Items.WOOL.lime();
|
item = Items.BROWN_WOOL;
|
||||||
case CYAN -> Items.WOOL.cyan();
|
} else if (color.equals(DyeColor.BLUE)) {
|
||||||
case MAGENTA -> Items.WOOL.magenta();
|
item = Items.BLUE_WOOL;
|
||||||
case ORANGE -> Items.WOOL.orange();
|
} else if (color.equals(DyeColor.LIGHT_BLUE)) {
|
||||||
case PINK -> Items.WOOL.pink();
|
item = Items.LIGHT_BLUE_WOOL;
|
||||||
case PURPLE -> Items.WOOL.purple();
|
} else if (color.equals(DyeColor.GREEN)) {
|
||||||
case RED -> Items.WOOL.red();
|
item = Items.GREEN_WOOL;
|
||||||
case YELLOW -> Items.WOOL.yellow();
|
} else if (color.equals(DyeColor.LIME)) {
|
||||||
default -> Items.WOOL.white();
|
item = Items.LIME_WOOL;
|
||||||
};
|
} else if (color.equals(DyeColor.CYAN)) {
|
||||||
|
item = Items.CYAN_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.MAGENTA)) {
|
||||||
|
item = Items.MAGENTA_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.ORANGE)) {
|
||||||
|
item = Items.ORANGE_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.PINK)) {
|
||||||
|
item = Items.PINK_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.PURPLE)) {
|
||||||
|
item = Items.PURPLE_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.RED)) {
|
||||||
|
item = Items.RED_WOOL;
|
||||||
|
} else if (color.equals(DyeColor.YELLOW)) {
|
||||||
|
item = Items.YELLOW_WOOL;
|
||||||
|
}
|
||||||
user.level().addFreshEntity(new ItemEntity(user.level(), pos.x, pos.y, pos.z, new ItemStack(item, amount)));
|
user.level().addFreshEntity(new ItemEntity(user.level(), pos.x, pos.y, pos.z, new ItemStack(item, amount)));
|
||||||
return InteractionResult.SUCCESS;
|
return InteractionResult.SUCCESS;
|
||||||
}
|
}
|
||||||
@@ -84,20 +93,6 @@ public class QShears extends ShearsItem {
|
|||||||
user.level()
|
user.level()
|
||||||
.addFreshEntity(new ItemEntity(user.level(), pos.x, pos.y, pos.z, new ItemStack(Items.FEATHER, amount)));
|
.addFreshEntity(new ItemEntity(user.level(), pos.x, pos.y, pos.z, new ItemStack(Items.FEATHER, amount)));
|
||||||
return InteractionResult.SUCCESS;
|
return InteractionResult.SUCCESS;
|
||||||
} else if (user.level() instanceof ServerLevel serverLevel){
|
|
||||||
if (entity.getLootTable().isPresent()) {
|
|
||||||
LootTable lootTable = serverLevel.getServer().reloadableRegistries().getLootTable(entity.getLootTable().get());
|
|
||||||
LootParams lootParams = new LootParams.Builder(serverLevel)
|
|
||||||
.withParameter(LootContextParams.ORIGIN, entity.position())
|
|
||||||
.withParameter(LootContextParams.THIS_ENTITY, entity)
|
|
||||||
.withParameter(LootContextParams.DAMAGE_SOURCE, entity.damageSources().generic())
|
|
||||||
.create(LootContextParamSets.ENTITY);
|
|
||||||
lootTable.getRandomItems(lootParams).forEach(itemStack -> {
|
|
||||||
entity.spawnAtLocation(serverLevel, itemStack);
|
|
||||||
});
|
|
||||||
entity.hurtServer(serverLevel, entity.damageSources().generic(), 0.1f);
|
|
||||||
return InteractionResult.SUCCESS;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return InteractionResult.PASS;
|
return InteractionResult.PASS;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
package de.jottyfan.minecraft.item;
|
package de.jottyfan.minecraft.item;
|
||||||
|
|
||||||
import java.util.HashSet;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
@@ -8,9 +7,11 @@ import com.google.common.collect.Lists;
|
|||||||
|
|
||||||
import net.minecraft.core.BlockPos;
|
import net.minecraft.core.BlockPos;
|
||||||
import net.minecraft.core.Direction;
|
import net.minecraft.core.Direction;
|
||||||
|
import net.minecraft.tags.BlockTags;
|
||||||
|
import net.minecraft.tags.ItemTags;
|
||||||
import net.minecraft.world.InteractionResult;
|
import net.minecraft.world.InteractionResult;
|
||||||
import net.minecraft.world.item.Item;
|
|
||||||
import net.minecraft.world.item.ItemStack;
|
import net.minecraft.world.item.ItemStack;
|
||||||
|
import net.minecraft.world.item.ShovelItem;
|
||||||
import net.minecraft.world.item.ToolMaterial;
|
import net.minecraft.world.item.ToolMaterial;
|
||||||
import net.minecraft.world.item.context.UseOnContext;
|
import net.minecraft.world.item.context.UseOnContext;
|
||||||
import net.minecraft.world.level.Level;
|
import net.minecraft.world.level.Level;
|
||||||
@@ -18,11 +19,11 @@ import net.minecraft.world.level.block.Block;
|
|||||||
import net.minecraft.world.level.block.Blocks;
|
import net.minecraft.world.level.block.Blocks;
|
||||||
import net.minecraft.world.level.block.state.BlockState;
|
import net.minecraft.world.level.block.state.BlockState;
|
||||||
|
|
||||||
public class QShovel extends Item implements ToolRangeable {
|
public class QShovel extends ShovelItem implements ToolRangeable {
|
||||||
public HarvestRange range;
|
public HarvestRange range;
|
||||||
|
|
||||||
public QShovel(QIP properties) {
|
public QShovel(QIP properties) {
|
||||||
super(properties.shovel(ToolMaterial.DIAMOND, 1.5f, -3.0f));
|
super(new ToolMaterial(BlockTags.INCORRECT_FOR_DIAMOND_TOOL, properties.getDurability(), 7f, 1f, 15, ItemTags.DIAMOND_TOOL_MATERIALS), 7F, -3.1F, properties);
|
||||||
this.range = properties.getHarvestRange();
|
this.range = properties.getHarvestRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -51,11 +52,8 @@ public class QShovel extends Item implements ToolRangeable {
|
|||||||
public InteractionResult useOn(UseOnContext context) {
|
public InteractionResult useOn(UseOnContext context) {
|
||||||
InteractionResult result = super.useOn(context);
|
InteractionResult result = super.useOn(context);
|
||||||
if (InteractionResult.SUCCESS.equals(result)) {
|
if (InteractionResult.SUCCESS.equals(result)) {
|
||||||
Set<Block> flattenables = new HashSet<>();
|
|
||||||
flattenables.add(Blocks.DIRT);
|
|
||||||
flattenables.add(Blocks.GRASS_BLOCK);
|
|
||||||
for (BlockPos pos : range.getRangeAsBlockPosArray(context.getClickedPos(), true, new BlockPos(1, 1, 1))) {
|
for (BlockPos pos : range.getRangeAsBlockPosArray(context.getClickedPos(), true, new BlockPos(1, 1, 1))) {
|
||||||
createPath(context.getLevel(), pos, context.getClickedFace(), flattenables);
|
createPath(context.getLevel(), pos, context.getClickedFace(), FLATTENABLES.keySet());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
@@ -24,13 +24,13 @@ public class QuicklyItems {
|
|||||||
public static final Item STUB = registerItem(ID.STUB, Stub::new);
|
public static final Item STUB = registerItem(ID.STUB, Stub::new);
|
||||||
public static final Item RAWTURQUOISE = registerItem(ID.RAWTURQUOISE);
|
public static final Item RAWTURQUOISE = registerItem(ID.RAWTURQUOISE);
|
||||||
public static final Item TURQUOISEINGOT = registerItem(ID.TURQUOISEINGOT);
|
public static final Item TURQUOISEINGOT = registerItem(ID.TURQUOISEINGOT);
|
||||||
public static final Item COTTON = registerItem(ID.COTTON, ofCompostable(QIP.of(ID.COTTON)));
|
public static final Item COTTON = registerItem(ID.COTTON);
|
||||||
public static final Item COTTONPLANT = registerItem(ID.COTTONPLANT);
|
public static final Item COTTONPLANT = registerItem(ID.COTTONPLANT);
|
||||||
public static final Item COTTONSEED = registerItem(ID.COTTONSEED, ofCompostable(QIP.of(ID.BLOCKCOTTONPLANT)), Plant::new);
|
public static final Item COTTONSEED = registerItem(ID.COTTONSEED, QIP.of(ID.BLOCKCOTTONPLANT), Plant::new);
|
||||||
public static final Item PILLOW = registerItem(ID.PILLOW);
|
public static final Item PILLOW = registerItem(ID.PILLOW);
|
||||||
public static final Item CANOLA = registerItem(ID.CANOLA, ofCompostable(QIP.of(ID.CANOLA)));
|
public static final Item CANOLA = registerItem(ID.CANOLA);
|
||||||
public static final Item CANOLAPLANT = registerItem(ID.CANOLAPLANT);
|
public static final Item CANOLAPLANT = registerItem(ID.CANOLAPLANT);
|
||||||
public static final Item CANOLASEED = registerItem(ID.CANOLASEED, ofCompostable(QIP.of(ID.BLOCKCANOLAPLANT)), Plant::new);
|
public static final Item CANOLASEED = registerItem(ID.CANOLASEED, QIP.of(ID.BLOCKCANOLAPLANT), Plant::new);
|
||||||
public static final Item CANOLABOTTLE = registerItem(ID.CANOLABOTTLE);
|
public static final Item CANOLABOTTLE = registerItem(ID.CANOLABOTTLE);
|
||||||
public static final Item CANOLABOTTLESTACK = registerItem(ID.CANOLABOTTLESTACK);
|
public static final Item CANOLABOTTLESTACK = registerItem(ID.CANOLABOTTLESTACK);
|
||||||
public static final Item ROTTENFLESHSTRIPES = registerItem(ID.ROTTEN_FLESH_STRIPES);
|
public static final Item ROTTENFLESHSTRIPES = registerItem(ID.ROTTEN_FLESH_STRIPES);
|
||||||
@@ -79,10 +79,6 @@ public class QuicklyItems {
|
|||||||
public static final Item ARMOR_TURQUOISE_LEGGINGS = registerItem(ID.TURQUOISE_LEGGINGS, ArmorType.LEGGINGS);
|
public static final Item ARMOR_TURQUOISE_LEGGINGS = registerItem(ID.TURQUOISE_LEGGINGS, ArmorType.LEGGINGS);
|
||||||
public static final Item ARMOR_TURQUOISE_CHESTPLATE = registerItem(ID.TURQUOISE_CHESTPLATE, ArmorType.CHESTPLATE);
|
public static final Item ARMOR_TURQUOISE_CHESTPLATE = registerItem(ID.TURQUOISE_CHESTPLATE, ArmorType.CHESTPLATE);
|
||||||
|
|
||||||
private static final QIP ofCompostable(QIP qip) {
|
|
||||||
return (QIP) qip.compostable(ResourceKey.create(Registries.NUMBER_PROVIDER, Identifier.withDefaultNamespace("compostable/medium_high")));
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final Item registerItem(Identifier identifier, ArmorType armorType) {
|
private static final Item registerItem(Identifier identifier, ArmorType armorType) {
|
||||||
return QuicklyItems.registerItem(identifier,
|
return QuicklyItems.registerItem(identifier,
|
||||||
new QIP().stacksTo(1).humanoidArmor(ModArmorMaterials.TURQUOISE_ARMOR_MATERIAL, armorType));
|
new QIP().stacksTo(1).humanoidArmor(ModArmorMaterials.TURQUOISE_ARMOR_MATERIAL, armorType));
|
||||||
@@ -105,7 +101,7 @@ public class QuicklyItems {
|
|||||||
return Registry.register(BuiltInRegistries.ITEM, identifier, item);
|
return Registry.register(BuiltInRegistries.ITEM, identifier, item);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final List<Item> registeredModItems() {
|
public static final List<Item> registerModItems() {
|
||||||
Quickly.LOGGER.debug("adding Items");
|
Quickly.LOGGER.debug("adding Items");
|
||||||
List<Item> set = new ArrayList<>();
|
List<Item> set = new ArrayList<>();
|
||||||
set.add(STUB);
|
set.add(STUB);
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ public class Stub extends Item {
|
|||||||
if (SLASH_MAP.containsKey(clickedBlock)) {
|
if (SLASH_MAP.containsKey(clickedBlock)) {
|
||||||
if (!level.isClientSide()) {
|
if (!level.isClientSide()) {
|
||||||
level.setBlockAndUpdate(pos, Blocks.AIR.defaultBlockState());
|
level.setBlockAndUpdate(pos, Blocks.AIR.defaultBlockState());
|
||||||
level.playPlayerSound(SoundEvents.HOE_TILL.value(), SoundSource.BLOCKS, 1f, 1f);
|
level.playSound(null, pos, SoundEvents.HOE_TILL, SoundSource.BLOCKS);
|
||||||
for (int i = 0; i < 9; i++) {
|
for (int i = 0; i < 9; i++) {
|
||||||
ItemStack stack = new ItemStack(SLASH_MAP.get(clickedBlock));
|
ItemStack stack = new ItemStack(SLASH_MAP.get(clickedBlock));
|
||||||
float xScatter = new Random().nextFloat();
|
float xScatter = new Random().nextFloat();
|
||||||
|
|||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package de.jottyfan.minecraft.loot;
|
||||||
|
|
||||||
|
import de.jottyfan.minecraft.item.QuicklyItems;
|
||||||
|
import net.fabricmc.fabric.api.loot.v3.LootTableEvents;
|
||||||
|
import net.minecraft.resources.Identifier;
|
||||||
|
import net.minecraft.world.item.Item;
|
||||||
|
import net.minecraft.world.level.storage.loot.LootPool;
|
||||||
|
import net.minecraft.world.level.storage.loot.entries.LootItem;
|
||||||
|
import net.minecraft.world.level.storage.loot.predicates.LootItemRandomChanceCondition;
|
||||||
|
import net.minecraft.world.level.storage.loot.providers.number.ConstantValue;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author jotty
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
public class QuicklyLootTables {
|
||||||
|
|
||||||
|
public static final void registerChanges() {
|
||||||
|
LootTableEvents.MODIFY.register((key, tableBuilder, source, registries) -> {
|
||||||
|
if (source.isBuiltin()) {
|
||||||
|
Identifier shortGrass = Identifier.fromNamespaceAndPath("minecraft", "blocks/short_grass");
|
||||||
|
Identifier tallGrass = Identifier.fromNamespaceAndPath("minecraft", "blocks/tall_grass");
|
||||||
|
if (key.identifier().equals(shortGrass)) {
|
||||||
|
tableBuilder.withPool(harvestItemByChance(QuicklyItems.COTTONSEED, 0.05f));
|
||||||
|
} else if (key.identifier().equals(tallGrass)) {
|
||||||
|
tableBuilder.withPool(harvestItemByChance(QuicklyItems.CANOLASEED, 0.03f));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final LootPool.Builder harvestItemByChance(Item item, float chance) {
|
||||||
|
return LootPool.lootPool().setRolls(ConstantValue.exactly(1f))
|
||||||
|
.when(LootItemRandomChanceCondition.randomChance(chance)).add(LootItem.lootTableItem(item));
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:block",
|
|
||||||
"pools": [
|
|
||||||
{
|
|
||||||
"entries": [
|
|
||||||
{
|
|
||||||
"type": "minecraft:alternatives",
|
|
||||||
"children": [
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": "minecraft:tool/can_shear",
|
|
||||||
"name": "minecraft:short_grass"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": {
|
|
||||||
"type": "minecraft:random_chance",
|
|
||||||
"chance": 0.125
|
|
||||||
},
|
|
||||||
"modifier": [
|
|
||||||
{
|
|
||||||
"type": "minecraft:apply_bonus",
|
|
||||||
"enchantment": "minecraft:fortune",
|
|
||||||
"formula": "minecraft:uniform_bonus_count",
|
|
||||||
"parameters": {
|
|
||||||
"bonusMultiplier": 2
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:explosion_decay"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"name": "minecraft:wheat_seeds"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": {
|
|
||||||
"type": "minecraft:random_chance",
|
|
||||||
"chance": 0.125
|
|
||||||
},
|
|
||||||
"name": "quickly:cottonseed"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"rolls": 1.0
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:block",
|
|
||||||
"pools": [
|
|
||||||
{
|
|
||||||
"entries": [
|
|
||||||
{
|
|
||||||
"type": "minecraft:alternatives",
|
|
||||||
"children": [
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": "minecraft:tool/can_shear",
|
|
||||||
"name": "minecraft:tall_grass"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": {
|
|
||||||
"type": "minecraft:random_chance",
|
|
||||||
"chance": 0.125
|
|
||||||
},
|
|
||||||
"name": "quickly:canolaseed"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": {
|
|
||||||
"type": "minecraft:random_chance",
|
|
||||||
"chance": 0.125
|
|
||||||
},
|
|
||||||
"name": "minecraft:beetroot_seeds"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "minecraft:item",
|
|
||||||
"condition": {
|
|
||||||
"type": "minecraft:random_chance",
|
|
||||||
"chance": 0.125
|
|
||||||
},
|
|
||||||
"name": "quickly:salpeter"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"rolls": 1.0
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
"components": {
|
|
||||||
"minecraft:block_transformer": "minecraft:axe"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
"components": {
|
|
||||||
"minecraft:block_transformer": "minecraft:axe"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:block",
|
||||||
|
"pools": [
|
||||||
|
{
|
||||||
|
"rolls": 1,
|
||||||
|
"entries": [
|
||||||
|
{
|
||||||
|
"type": "minecraft:item",
|
||||||
|
"name": "quickly:canola",
|
||||||
|
"functions": [
|
||||||
|
{
|
||||||
|
"function": "minecraft:set_count",
|
||||||
|
"count": {
|
||||||
|
"min": 1,
|
||||||
|
"max": 2
|
||||||
|
},
|
||||||
|
"add": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"conditions": [
|
||||||
|
{
|
||||||
|
"condition": "minecraft:location_check",
|
||||||
|
"predicate": {
|
||||||
|
"block": {
|
||||||
|
"properties": {
|
||||||
|
"age": "7"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"rolls": 1,
|
||||||
|
"entries": [
|
||||||
|
{
|
||||||
|
"type": "minecraft:item",
|
||||||
|
"name": "quickly:canolaseed",
|
||||||
|
"functions": [
|
||||||
|
{
|
||||||
|
"function": "minecraft:apply_bonus",
|
||||||
|
"enchantment": "minecraft:fortune",
|
||||||
|
"formula": "minecraft:binomial_with_bonus_count",
|
||||||
|
"parameters": {
|
||||||
|
"extra": 2,
|
||||||
|
"probability": 0.5
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:block",
|
||||||
|
"pools": [
|
||||||
|
{
|
||||||
|
"rolls": 1,
|
||||||
|
"entries": [
|
||||||
|
{
|
||||||
|
"type": "minecraft:item",
|
||||||
|
"name": "quickly:cotton",
|
||||||
|
"functions": [
|
||||||
|
{
|
||||||
|
"function": "minecraft:set_count",
|
||||||
|
"count": {
|
||||||
|
"min": 1,
|
||||||
|
"max": 3
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"conditions": [
|
||||||
|
{
|
||||||
|
"condition": "minecraft:location_check",
|
||||||
|
"predicate": {
|
||||||
|
"block": {
|
||||||
|
"properties": {
|
||||||
|
"age": "7"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"rolls": 1,
|
||||||
|
"entries": [
|
||||||
|
{
|
||||||
|
"type": "minecraft:item",
|
||||||
|
"name": "quickly:cottonseed",
|
||||||
|
"functions": [
|
||||||
|
{
|
||||||
|
"function": "minecraft:apply_bonus",
|
||||||
|
"enchantment": "minecraft:fortune",
|
||||||
|
"formula": "minecraft:binomial_with_bonus_count",
|
||||||
|
"parameters": {
|
||||||
|
"extra": 2,
|
||||||
|
"probability": 0.5
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
" #",
|
" #",
|
||||||
"# "
|
"# "
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"ss",
|
"ss",
|
||||||
"s|",
|
"s|",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"ss",
|
"ss",
|
||||||
" |",
|
" |",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"sss",
|
"sss",
|
||||||
" | ",
|
" | ",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"s",
|
"s",
|
||||||
"|",
|
"|",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
" #",
|
" #",
|
||||||
"# "
|
"# "
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"ss",
|
"ss",
|
||||||
"s|",
|
"s|",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"ss",
|
"ss",
|
||||||
" |",
|
" |",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"sss",
|
"sss",
|
||||||
" | ",
|
" | ",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"type": "minecraft:crafting_shaped",
|
"type": "minecraft:crafting_shaped",
|
||||||
"category": "equipment",
|
"category": "tools",
|
||||||
"pattern": [
|
"pattern": [
|
||||||
"s",
|
"s",
|
||||||
"|",
|
"|",
|
||||||
|
|||||||
@@ -1,8 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:stonecutting",
|
|
||||||
"ingredient": "minecraft:sulfur_spike",
|
|
||||||
"result": {
|
|
||||||
"id": "quickly:sulfor",
|
|
||||||
"count": 2
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 4,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:dirtsalpeter"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:block_match",
|
||||||
|
"block": "minecraft:dirt"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 20,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oredeepslatesulfor"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:deepslate_ore_replaceables"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 20,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:orenethersulfor"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:block_match",
|
||||||
|
"block": "minecraft:netherrack"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 12,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oresalpeter"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:stone_ore_replaceables"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 6,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oresandsalpeter"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:block_match",
|
||||||
|
"block": "minecraft:sandstone"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 7,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:orespeedpowder"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:stone_ore_replaceables"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oredeepslatespeedpowder"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:deepslate_ore_replaceables"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 10,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oresulfor"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:stone_ore_replaceables"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 10,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oreturquoise"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:stone_ore_replaceables"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:oredeepslateturquoise"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:tag_match",
|
||||||
|
"tag": "minecraft:deepslate_ore_replaceables"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"type": "minecraft:ore",
|
||||||
|
"config": {
|
||||||
|
"discard_chance_on_air_exposure": 0.0,
|
||||||
|
"size": 8,
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"state": {
|
||||||
|
"Name": "quickly:sandsalpeter"
|
||||||
|
},
|
||||||
|
"target": {
|
||||||
|
"predicate_type": "minecraft:block_match",
|
||||||
|
"block": "minecraft:sand"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 4,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:dirtsalpeter"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:block_match",
|
|
||||||
"block": "minecraft:dirt"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 20,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oredeepslatesulfor"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:deepslate_ore_replaceables"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 20,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:orenethersulfor"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:block_match",
|
|
||||||
"block": "minecraft:netherrack"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 12,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oresalpeter"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:stone_ore_replaceables"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 6,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oresandsalpeter"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:block_match",
|
|
||||||
"block": "minecraft:sandstone"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 7,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:orespeedpowder"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:stone_ore_replaceables"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oredeepslatespeedpowder"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:deepslate_ore_replaceables"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 10,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oresulfor"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:stone_ore_replaceables"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 10,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oreturquoise"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:stone_ore_replaceables"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:oredeepslateturquoise"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:tag_match",
|
|
||||||
"tag": "minecraft:deepslate_ore_replaceables"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
{
|
|
||||||
"type": "minecraft:ore",
|
|
||||||
"discard_chance_on_air_exposure": 0.0,
|
|
||||||
"size": 8,
|
|
||||||
"targets": [
|
|
||||||
{
|
|
||||||
"state": {
|
|
||||||
"Name": "quickly:sandsalpeter"
|
|
||||||
},
|
|
||||||
"target": {
|
|
||||||
"predicate_type": "minecraft:block_match",
|
|
||||||
"block": "minecraft:sand"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -23,8 +23,8 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"depends": {
|
"depends": {
|
||||||
"fabricloader": ">=0.19.3",
|
"fabricloader": ">=0.19.2",
|
||||||
"minecraft": "~26.3-",
|
"minecraft": "~26.1.2-",
|
||||||
"java": ">=25",
|
"java": ">=25",
|
||||||
"fabric-api": "*"
|
"fabric-api": "*"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user