forked from P3NG00/OhHowTheCraftingHasTabled
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
6.3.5 Initial release, parity with 6.3.5 for 1.20.1
- Loading branch information
Showing
32 changed files
with
1,801 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
remappedSrc/net/xanthian/variantcraftingtables/DataGenerator.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package net.xanthian.variantcraftingtables; | ||
|
||
import net.fabricmc.fabric.api.datagen.v1.DataGeneratorEntrypoint; | ||
import net.fabricmc.fabric.api.datagen.v1.FabricDataGenerator; | ||
import net.xanthian.variantcraftingtables.datagen.*; | ||
|
||
public class DataGenerator implements DataGeneratorEntrypoint { | ||
@Override | ||
public void onInitializeDataGenerator(FabricDataGenerator fabricDataGenerator) { | ||
FabricDataGenerator.Pack pack = fabricDataGenerator.createPack(); | ||
|
||
pack.addProvider(BlockTagGenerator::new); | ||
pack.addProvider(ItemTagGenerator::new); | ||
pack.addProvider(LangFileGenerator::new); | ||
pack.addProvider(LootTableGenerator::new); | ||
pack.addProvider(RecipeGenerator::new); | ||
pack.addProvider(ModelGenerator::new); | ||
} | ||
} |
68 changes: 68 additions & 0 deletions
68
remappedSrc/net/xanthian/variantcraftingtables/Initialise.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
package net.xanthian.variantcraftingtables; | ||
|
||
import net.fabricmc.api.ModInitializer; | ||
import net.fabricmc.loader.api.FabricLoader; | ||
import net.xanthian.variantcraftingtables.block.Vanilla; | ||
import net.xanthian.variantcraftingtables.block.compatability.*; | ||
import net.xanthian.variantcraftingtables.util.ModCreativeTab; | ||
import net.xanthian.variantcraftingtables.util.ModRegistries; | ||
|
||
public class Initialise implements ModInitializer { | ||
|
||
public static final String MOD_ID = "variantcraftingtables"; | ||
|
||
public static void ifModLoaded(String modId, Runnable runnable) { | ||
if (FabricLoader.getInstance().isModLoaded(modId)) { | ||
runnable.run(); | ||
} | ||
} | ||
|
||
@Override | ||
public void onInitialize() { | ||
|
||
Vanilla.registerTables(); | ||
|
||
ifModLoaded("ad_astra", AdAstra::registerTables); | ||
|
||
ifModLoaded("beachparty", BeachParty::registerTables); | ||
|
||
ifModLoaded("betterarcheology", BetterArcheology::registerTables); | ||
|
||
ifModLoaded("bewitchment", Bewitchment::registerTables); | ||
|
||
ifModLoaded("biomemakeover", BiomeMakeover::registerTables); | ||
|
||
ifModLoaded("blockus", Blockus::registerTables); | ||
|
||
ifModLoaded("botania", Botania::registerTables); | ||
|
||
ifModLoaded("cinderscapes", Cinderscapes::registerTables); | ||
|
||
ifModLoaded("deeperdarker", DeeperAndDarker::registerTables); | ||
|
||
ifModLoaded("desolation", Desolation::registerTables); | ||
|
||
ifModLoaded("eldritch_end", EldritchEnd::registerTables); | ||
|
||
ifModLoaded("minecells", MineCells::registerTables); | ||
|
||
ifModLoaded("natures_spirit", NaturesSpirit::registerTables); | ||
|
||
ifModLoaded("promenade", Promenade::registerTables); | ||
|
||
ifModLoaded("regions_unexplored", RegionsUnexplored::registerTables); | ||
|
||
ifModLoaded("snifferplus", SnifferPlus::registerTables); | ||
|
||
ifModLoaded("techreborn", TechReborn::registerTables); | ||
|
||
ifModLoaded("vinery", Vinery::registerTables); | ||
|
||
ModRegistries.registerFuelandFlammable(); | ||
ModCreativeTab.registerItemGroup(); | ||
|
||
// Datagen Block - disable for client run | ||
//Botania.registerTables(); | ||
//SnifferPlus.registerTables(); | ||
} | ||
} |
54 changes: 54 additions & 0 deletions
54
remappedSrc/net/xanthian/variantcraftingtables/block/Vanilla.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
package net.xanthian.variantcraftingtables.block; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.block.MapColor; | ||
import net.minecraft.block.enums.Instrument; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.sound.BlockSoundGroup; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class Vanilla { | ||
|
||
public static final CraftingTableBlock ACACIA_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock BAMBOO_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock BIRCH_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock CHERRY_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock CRIMSON_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.create().mapColor(MapColor.DARK_CRIMSON).instrument(Instrument.BASS).strength(2.5F).sounds(BlockSoundGroup.WOOD)); | ||
public static final CraftingTableBlock DARK_OAK_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock JUNGLE_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock MANGROVE_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
// Vanilla Crafting Table is made from Oak | ||
public static final CraftingTableBlock SPRUCE_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE)); | ||
public static final CraftingTableBlock WARPED_CRAFTING_TABLE = new CraftingTableBlock(FabricBlockSettings.create().mapColor(MapColor.DARK_AQUA).instrument(Instrument.BASS).strength(2.5F).sounds(BlockSoundGroup.WOOD)); | ||
public static Map<Identifier, Block> VANILLA_CRAFTING_TABLES = Maps.newHashMap(); | ||
|
||
public static void registerTables() { | ||
registerCraftingTableBlock("acacia_crafting_table", ACACIA_CRAFTING_TABLE); | ||
registerCraftingTableBlock("bamboo_crafting_table", BAMBOO_CRAFTING_TABLE); | ||
registerCraftingTableBlock("birch_crafting_table", BIRCH_CRAFTING_TABLE); | ||
registerCraftingTableBlock("cherry_crafting_table", CHERRY_CRAFTING_TABLE); | ||
registerCraftingTableBlock("dark_oak_crafting_table", DARK_OAK_CRAFTING_TABLE); | ||
registerCraftingTableBlock("jungle_crafting_table", JUNGLE_CRAFTING_TABLE); | ||
registerCraftingTableBlock("mangrove_crafting_table", MANGROVE_CRAFTING_TABLE); | ||
registerCraftingTableBlock("spruce_crafting_table", SPRUCE_CRAFTING_TABLE); | ||
registerCraftingTableBlock("crimson_crafting_table", CRIMSON_CRAFTING_TABLE); | ||
registerCraftingTableBlock("warped_crafting_table", WARPED_CRAFTING_TABLE); | ||
} | ||
|
||
private static void registerCraftingTableBlock(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
VANILLA_CRAFTING_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
} | ||
} |
42 changes: 42 additions & 0 deletions
42
remappedSrc/net/xanthian/variantcraftingtables/block/compatability/AdAstra.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
package net.xanthian.variantcraftingtables.block.compatability; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class AdAstra { | ||
|
||
public static Map<Identifier, Block> AA_TABLES = Maps.newHashMap(); | ||
|
||
public static Block AA_AERONOS_CRAFTING_TABLE; | ||
public static Block AA_GLACIAN_CRAFTING_TABLE; | ||
public static Block AA_STROPHAR_CRAFTING_TABLE; | ||
|
||
public static void registerTables() { | ||
AA_AERONOS_CRAFTING_TABLE = registerCraftingTable("aa_aeronos_crafting_table"); | ||
AA_GLACIAN_CRAFTING_TABLE = registerCraftingTable("aa_glacian_crafting_table"); | ||
AA_STROPHAR_CRAFTING_TABLE = registerCraftingTable("aa_strophar_crafting_table"); | ||
} | ||
|
||
private static Block register(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
AA_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
return block; | ||
} | ||
|
||
private static Block registerCraftingTable(String name) { | ||
return register(name, new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE))); | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
remappedSrc/net/xanthian/variantcraftingtables/block/compatability/BeachParty.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package net.xanthian.variantcraftingtables.block.compatability; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class BeachParty { | ||
|
||
public static Map<Identifier, Block> LDBP_TABLES = Maps.newHashMap(); | ||
|
||
public static Block LDBP_PALM_CRAFTING_TABLE; | ||
|
||
public static void registerTables() { | ||
LDBP_PALM_CRAFTING_TABLE = registerCraftingTable("ldbp_palm_crafting_table"); | ||
} | ||
|
||
private static Block register(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
LDBP_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
return block; | ||
} | ||
|
||
private static Block registerCraftingTable(String name) { | ||
return register(name, new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE))); | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
remappedSrc/net/xanthian/variantcraftingtables/block/compatability/BetterArcheology.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package net.xanthian.variantcraftingtables.block.compatability; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class BetterArcheology { | ||
|
||
public static Map<Identifier, Block> BA_TABLES = Maps.newHashMap(); | ||
|
||
public static Block BA_ROTTEN_CRAFTING_TABLE; | ||
|
||
public static void registerTables() { | ||
BA_ROTTEN_CRAFTING_TABLE = registerCraftingTable("ba_rotten_crafting_table"); | ||
} | ||
|
||
private static Block register(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
BA_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
return block; | ||
} | ||
|
||
private static Block registerCraftingTable(String name) { | ||
return register(name, new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE))); | ||
} | ||
} |
44 changes: 44 additions & 0 deletions
44
remappedSrc/net/xanthian/variantcraftingtables/block/compatability/Bewitchment.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
package net.xanthian.variantcraftingtables.block.compatability; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class Bewitchment { | ||
|
||
public static Map<Identifier, Block> BW_TABLES = Maps.newHashMap(); | ||
|
||
public static Block BW_CYPRESS_CRAFTING_TABLE; | ||
public static Block BW_DRAGONS_BLOOD_CRAFTING_TABLE; | ||
public static Block BW_ELDER_CRAFTING_TABLE; | ||
public static Block BW_JUNIPER_CRAFTING_TABLE; | ||
|
||
public static void registerTables() { | ||
BW_CYPRESS_CRAFTING_TABLE = registerCraftingTable("bw_cypress_crafting_table"); | ||
BW_DRAGONS_BLOOD_CRAFTING_TABLE = registerCraftingTable("bw_dragons_blood_crafting_table"); | ||
BW_ELDER_CRAFTING_TABLE = registerCraftingTable("bw_elder_crafting_table"); | ||
BW_JUNIPER_CRAFTING_TABLE = registerCraftingTable("bw_juniper_crafting_table"); | ||
} | ||
|
||
private static Block register(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
BW_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
return block; | ||
} | ||
|
||
private static Block registerCraftingTable(String name) { | ||
return register(name, new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE))); | ||
} | ||
} |
44 changes: 44 additions & 0 deletions
44
remappedSrc/net/xanthian/variantcraftingtables/block/compatability/BiomeMakeover.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
package net.xanthian.variantcraftingtables.block.compatability; | ||
|
||
import com.google.common.collect.Maps; | ||
import net.fabricmc.fabric.api.item.v1.FabricItemSettings; | ||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; | ||
import net.minecraft.block.Block; | ||
import net.minecraft.block.Blocks; | ||
import net.minecraft.block.CraftingTableBlock; | ||
import net.minecraft.item.BlockItem; | ||
import net.minecraft.registry.Registries; | ||
import net.minecraft.registry.Registry; | ||
import net.minecraft.util.Identifier; | ||
import net.xanthian.variantcraftingtables.Initialise; | ||
|
||
import java.util.Map; | ||
|
||
public class BiomeMakeover { | ||
|
||
public static Map<Identifier, Block> BM_TABLES = Maps.newHashMap(); | ||
|
||
public static Block BM_ANCIENT_OAK_CRAFTING_TABLE; | ||
public static Block BM_BLIGHTED_BALSA_CRAFTING_TABLE; | ||
public static Block BM_SWAMP_CYPRESS_CRAFTING_TABLE; | ||
public static Block BM_WILLOW_CRAFTING_TABLE; | ||
|
||
public static void registerTables() { | ||
BM_ANCIENT_OAK_CRAFTING_TABLE = registerCraftingTable("bm_ancient_oak_crafting_table"); | ||
BM_BLIGHTED_BALSA_CRAFTING_TABLE = registerCraftingTable("bm_blighted_balsa_crafting_table"); | ||
BM_SWAMP_CYPRESS_CRAFTING_TABLE = registerCraftingTable("bm_swamp_cypress_crafting_table"); | ||
BM_WILLOW_CRAFTING_TABLE = registerCraftingTable("bm_willow_crafting_table"); | ||
} | ||
|
||
public static Block register(String name, Block block) { | ||
Identifier identifier = new Identifier(Initialise.MOD_ID, name); | ||
Registry.register(Registries.BLOCK, identifier, block); | ||
BM_TABLES.put(identifier, block); | ||
Registry.register(Registries.ITEM, identifier, new BlockItem(block, new FabricItemSettings())); | ||
return block; | ||
} | ||
|
||
public static Block registerCraftingTable(String name) { | ||
return register(name, new CraftingTableBlock(FabricBlockSettings.copy(Blocks.CRAFTING_TABLE))); | ||
} | ||
} |
Oops, something went wrong.