This commit is contained in:
nelle 2023-11-04 18:02:49 -06:00
parent 25e519a7be
commit 545bf33d68
7 changed files with 32 additions and 40 deletions

View file

@ -3,7 +3,7 @@ org.gradle.jvmargs = -Xmx1G
org.gradle.parallel = true
# Mod Properties
version = 3.0.7
version = 1.0.0-1.18
maven_group = xyz.limepot
archives_base_name = roses_mod

View file

@ -1,10 +1,10 @@
[versions]
# The latest versions are available at https://lambdaurora.dev/tools/import_quilt.html
minecraft = "1.20.1"
quilt_mappings = "1.20.1+build.1"
quilt_loader = "0.19.1"
minecraft = "1.18.2"
quilt_mappings = "1.18.2+build.26"
quilt_loader = "0.17.0"
quilted_fabric_api = "7.0.3+0.83.1-1.20.1"
quilted_fabric_api = "1.0.0-beta.28+0.67.0-1.18.2"
[libraries]
minecraft = { module = "com.mojang:minecraft", version.ref = "minecraft" }
@ -12,11 +12,10 @@ quilt_mappings = { module = "org.quiltmc:quilt-mappings", version.ref = "quilt_m
quilt_loader = { module = "org.quiltmc:quilt-loader", version.ref = "quilt_loader" }
quilted_fabric_api = { module = "org.quiltmc.quilted-fabric-api:quilted-fabric-api", version.ref = "quilted_fabric_api" }
quilted_fabric_api_deprecated = { module = "org.quiltmc.quilted-fabric-api:quilted-fabric-api-deprecated", version.ref = "quilted_fabric_api" }
# If you have multiple similar dependencies, you can declare a dependency bundle and reference it on the build script with "libs.bundles.example".
[bundles]
quilted_fabric_api = ["quilted_fabric_api", "quilted_fabric_api_deprecated"]
# [bundles]
# example = ["example-a", "example-b", "example-c"]
[plugins]
quilt_loom = { id = "org.quiltmc.loom", version = "1.2.+" }
quilt_loom = { id = "org.quiltmc.loom", version = "1.4.1" }

View file

@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

View file

@ -1,18 +1,15 @@
package xyz.limepot.roses_mod;
import net.fabricmc.fabric.api.itemgroup.v1.ItemGroupEvents;
import net.fabricmc.fabric.api.loot.v2.LootTableEvents;
import net.minecraft.block.*;
import net.minecraft.entity.effect.StatusEffects;
import net.minecraft.item.BlockItem;
import net.minecraft.item.ItemGroups;
import net.minecraft.item.Items;
import net.minecraft.item.Item;
import net.minecraft.loot.LootPool;
import net.minecraft.loot.entry.ItemEntry;
import net.minecraft.loot.provider.number.ConstantLootNumberProvider;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;
import net.minecraft.util.registry.Registry;
import net.minecraft.world.gen.GenerationStep;
import org.quiltmc.loader.api.ModContainer;
import org.quiltmc.qsl.base.api.entrypoint.ModInitializer;
@ -47,31 +44,31 @@ public class RosesMod implements ModInitializer {
ModFlowerGeneration.generateFlowers();
//BIOME MOD
BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, ROSE_FLOWER_PLACED_KEY);
BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, CYAN_ROSE_FLOWER_PLACED_KEY);
BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, CYAN_ROSE_BUSH_PLACED_KEY);
//BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, ROSE_FLOWER_PLACED_KEY);
//BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, CYAN_ROSE_FLOWER_PLACED_KEY);
//BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.VEGETAL_DECORATION, CYAN_ROSE_BUSH_PLACED_KEY);
//REGISTER BLOCKS AND BLOCK ITEMS
//ROSE FLOWER
Registry.register(Registries.BLOCK, new Identifier(MOD_ID, "rose_flower"), ROSE_FLOWER);
Registry.register(Registries.ITEM, new Identifier(MOD_ID, "rose_flower"), new BlockItem(ROSE_FLOWER, new QuiltItemSettings()));
Registry.register(Registry.BLOCK, new Identifier(MOD_ID, "rose_flower"), ROSE_FLOWER);
Registry.register(Registry.ITEM, new Identifier(MOD_ID, "rose_flower"), new BlockItem(ROSE_FLOWER, new QuiltItemSettings()));
//POTTED ROSE FLOWER
Registry.register(Registries.BLOCK, new Identifier(MOD_ID, "potted_rose"), POTTED_ROSE);
Registry.register(Registry.BLOCK, new Identifier(MOD_ID, "potted_rose"), POTTED_ROSE);
//CYAN ROSE
Registry.register(Registries.BLOCK, new Identifier(MOD_ID, "cyan_rose"), CYAN_ROSE);
Registry.register(Registries.ITEM, new Identifier(MOD_ID, "cyan_rose"), new BlockItem(CYAN_ROSE, new QuiltItemSettings()));
//Registry.register(Registry.BLOCK, new Identifier(MOD_ID, "cyan_rose"), CYAN_ROSE);
Registry.register(Registry.ITEM, new Identifier(MOD_ID, "cyan_rose"), new BlockItem(CYAN_ROSE, new QuiltItemSettings()));
//POTTED CYAN ROSE
Registry.register(Registries.BLOCK, new Identifier(MOD_ID, "potted_cyan"), POTTED_CYAN);
Registry.register(Registry.BLOCK, new Identifier(MOD_ID, "potted_cyan"), POTTED_CYAN);
//CYAN ROSE BUSH
Registry.register(Registries.BLOCK, new Identifier(MOD_ID, "cyan_rose_bush"), CYAN_ROSE_BUSH);
Registry.register(Registries.ITEM, new Identifier(MOD_ID, "cyan_rose_bush"), new BlockItem(CYAN_ROSE_BUSH, new QuiltItemSettings()));
Registry.register(Registry.BLOCK, new Identifier(MOD_ID, "cyan_rose_bush"), CYAN_ROSE_BUSH);
Registry.register(Registry.ITEM, new Identifier(MOD_ID, "cyan_rose_bush"), new BlockItem(CYAN_ROSE_BUSH, new QuiltItemSettings()));
//CREATIVE TABS
ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.POPPY, ROSE_FLOWER));
ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.BLUE_ORCHID, CYAN_ROSE));
ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.ROSE_BUSH, CYAN_ROSE_BUSH));
//ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.POPPY, ROSE_FLOWER));
//ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.BLUE_ORCHID, CYAN_ROSE));
//ItemGroupEvents.modifyEntriesEvent(ItemGroups.NATURAL_BLOCKS).register(content -> content.addAfter(Items.ROSE_BUSH, CYAN_ROSE_BUSH));
//LOOT TABLES
@ -83,8 +80,6 @@ public class RosesMod implements ModInitializer {
}
});
//INIT
LOGGER.info("Let that prickly nostalgia in.");
}

View file

@ -1,16 +1,14 @@
package xyz.limepot.roses_mod.world.gen;
import net.minecraft.registry.RegistryKey;
import net.minecraft.registry.RegistryKeys;
import net.minecraft.util.Identifier;
import net.minecraft.world.gen.feature.PlacedFeature;
import xyz.limepot.roses_mod.RosesMod;
public class ModFlowerGeneration {
public static final RegistryKey<PlacedFeature> ROSE_FLOWER_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","rose_flower"));
public static final RegistryKey<PlacedFeature> CYAN_ROSE_FLOWER_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","cyan_rose_flower"));
public static final RegistryKey<PlacedFeature> CYAN_ROSE_BUSH_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","cyan_rose_bush"));
//public static final RegistryKey<PlacedFeature> ROSE_FLOWER_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","rose_flower"));
//public static final RegistryKey<PlacedFeature> CYAN_ROSE_FLOWER_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","cyan_rose_flower"));
//public static final RegistryKey<PlacedFeature> CYAN_ROSE_BUSH_PLACED_KEY = RegistryKey.of(RegistryKeys.PLACED_FEATURE, new Identifier("roses_mod","cyan_rose_bush"));
public static void generateFlowers() {
RosesMod.LOGGER.debug("Registering Features...");

View file

@ -6,7 +6,7 @@
"entries": [
{
"type": "minecraft:item",
"name": "roses_mod:cyan_rose_flower"
"name": "roses_mod:cyan_rose"
}
]
}

View file

@ -26,15 +26,15 @@
"depends": [
{
"id": "quilt_loader",
"versions": ">=0.19.1"
"versions": ">=0.17.0"
},
{
"id": "quilted_fabric_api",
"versions": ">=7.0.3"
"versions": ">=1.0.0-beta.28+0.67.0-1.18.2"
},
{
"id": "minecraft",
"versions": ">=1.20-"
"versions": ">=1.18.2"
}
]
},