Skip to content

Commit

Permalink
1.20.1
Browse files Browse the repository at this point in the history
4.1.1

Fix potential language issue with Turkish OS users.
Fix 2 recipe errors
  • Loading branch information
xanthian committed Nov 23, 2023
1 parent afb1bf6 commit 1f46949
Show file tree
Hide file tree
Showing 27 changed files with 52 additions and 109 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ loader_version=0.14.24
fabric_version=0.90.7+1.20.1

# Mod Properties
mod_version = 4.1
mod_version = 4.1.1
maven_group = xanthian
archives_base_name = vsas

Expand Down
11 changes: 2 additions & 9 deletions src/main/java/net/xanthian/vsas/blocks/ActivatorRails.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import net.fabricmc.fabric.api.item.v1.FabricItemSettings;
import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;
Expand All @@ -29,15 +28,9 @@ public class ActivatorRails {
public static final Block WARPED_ACTIVATOR_RAIL = registerRailBlock("rails/warped_activator_rail", new VariantActivatorRailBlock());

private static Block registerRailBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_ACTIVATOR_RAILS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
12 changes: 2 additions & 10 deletions src/main/java/net/xanthian/vsas/blocks/Campfires.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,12 @@
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.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;

import net.xanthian.vsas.Initialise;
import net.xanthian.vsas.blocks.blocktypes.VariantCampfireBlock;

Expand All @@ -33,15 +30,10 @@ public class Campfires {
public static final Block WARPED_CAMPFIRE = registerCampfireBlock("campfires/warped_campfire", new VariantCampfireBlock(1, FabricBlockSettings.copyOf(Blocks.CAMPFIRE)));

private static Block registerCampfireBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_CAMPFIRES.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
10 changes: 2 additions & 8 deletions src/main/java/net/xanthian/vsas/blocks/DetectorRails.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import net.fabricmc.fabric.api.item.v1.FabricItemSettings;
import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;
Expand All @@ -29,15 +28,10 @@ public class DetectorRails {
public static final Block WARPED_DETECTOR_RAIL = registerRailBlock("rails/warped_detector_rail", new VariantDetectorRailBlock());

private static Block registerRailBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_DETECTOR_RAILS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
14 changes: 2 additions & 12 deletions src/main/java/net/xanthian/vsas/blocks/Grindstones.java
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
package net.xanthian.vsas.blocks;

import com.google.common.collect.Maps;

import net.fabricmc.fabric.api.item.v1.FabricItemSettings;

import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;

import net.xanthian.vsas.Initialise;
import net.xanthian.vsas.blocks.blocktypes.VariantGrindstoneBlock;

Expand All @@ -32,15 +28,9 @@ public class Grindstones {
public static final Block WARPED_GRINDSTONE = registerGrindstoneBlock("grindstones/warped_grindstone", new VariantGrindstoneBlock());

private static Block registerGrindstoneBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_GRINDSTONES.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
15 changes: 3 additions & 12 deletions src/main/java/net/xanthian/vsas/blocks/Ladders.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,11 @@

import com.google.common.collect.Maps;
import net.fabricmc.fabric.api.item.v1.FabricItemSettings;

import net.minecraft.block.*;
import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;

import net.xanthian.vsas.Initialise;
import net.xanthian.vsas.blocks.blocktypes.VariantLadderBlock;

Expand All @@ -31,15 +28,9 @@ public class Ladders {
public static final Block WARPED_LADDER = registerLadderBlock("ladders/warped_ladder", new VariantLadderBlock());

private static Block registerLadderBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_LADDERS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
15 changes: 3 additions & 12 deletions src/main/java/net/xanthian/vsas/blocks/Levers.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,11 @@

import com.google.common.collect.Maps;
import net.fabricmc.fabric.api.item.v1.FabricItemSettings;

import net.minecraft.block.*;
import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;

import net.xanthian.vsas.Initialise;
import net.xanthian.vsas.blocks.blocktypes.VariantLeverBlock;

Expand All @@ -31,15 +28,9 @@ public class Levers {
public static final Block WARPED_LEVER = registerLeverBlock("levers/warped_lever", new VariantLeverBlock());

private static Block registerLeverBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_LEVERS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
11 changes: 2 additions & 9 deletions src/main/java/net/xanthian/vsas/blocks/PoweredRails.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import net.fabricmc.fabric.api.item.v1.FabricItemSettings;
import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;
Expand All @@ -29,15 +28,9 @@ public class PoweredRails {
public static final Block WARPED_POWERED_RAIL = registerRailBlock("rails/warped_powered_rail", new VariantPoweredRailBlock());

private static Block registerRailBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_POWERED_RAILS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
14 changes: 2 additions & 12 deletions src/main/java/net/xanthian/vsas/blocks/Rails.java
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
package net.xanthian.vsas.blocks;

import com.google.common.collect.Maps;

import net.fabricmc.fabric.api.item.v1.FabricItemSettings;

import net.minecraft.block.Block;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;

import net.xanthian.vsas.Initialise;
import net.xanthian.vsas.blocks.blocktypes.VariantRailBlock;

Expand All @@ -32,15 +28,9 @@ public class Rails {
public static final Block WARPED_RAIL = registerRailBlock("rails/warped_rail", new VariantRailBlock());

private static Block registerRailBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_RAILS.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public static void registerRedstoneTorchBlocks() {
}

private static void initTorchBlock(String torchName, Block torch, String wallTorchName, Block wallTorch) {
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName);
MOD_REDSTONE_TORCHES.put(identifier, torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, torchName), torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, wallTorchName), wallTorch);
Expand Down
11 changes: 2 additions & 9 deletions src/main/java/net/xanthian/vsas/blocks/SoulCampfires.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import net.minecraft.block.Block;
import net.minecraft.block.Blocks;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.registry.Registries;
import net.minecraft.registry.Registry;
import net.minecraft.util.Identifier;
Expand All @@ -31,15 +30,9 @@ public class SoulCampfires {
public static final Block WARPED_SOUL_CAMPFIRE = registerSoulCampfireBlock("campfires/warped_soul_campfire", new VariantCampfireBlock(2, FabricBlockSettings.copyOf(Blocks.SOUL_CAMPFIRE)));

private static Block registerSoulCampfireBlock(String name, Block block) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
registerBlockItem(name, block);
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), new BlockItem(block, new FabricItemSettings()));
MOD_SOUL_CAMPFIRES.put(identifier, block);
return Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, name), block);
}

private static Item registerBlockItem(String name, Block block) {
Item item = Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name),
new BlockItem(block, new FabricItemSettings()));
return item;
}
}
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/blocks/SoulTorches.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public static void registerSoulTorchBlocks() {
}

private static void initTorchBlock(String torchName, Block torch, String wallTorchName, Block wallTorch) {
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName);
MOD_SOUL_TORCHES.put(identifier, torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, torchName), torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, wallTorchName), wallTorch);
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/blocks/Torches.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public static void registerTorchBlocks() {
}

private static void initTorchBlock(String torchName, Block torch, String wallTorchName, Block wallTorch) {
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, torchName);
MOD_TORCHES.put(identifier, torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, torchName), torch);
Registry.register(Registries.BLOCK, new Identifier(Initialise.MOD_ID, wallTorchName), wallTorch);
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Arrows.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class Arrows {
public static final ArrowItem WARPED_ARROW_ITEM = registerItem("arrows/warped_arrow", new WarpedArrowItem());

private static ArrowItem registerItem(String name, ArrowItem item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_ARROWS.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Axes.java
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public class Axes {
public static final Item WARPED_NETHERITE_AXE = registerItem("axes/warped_netherite_axe", new VariantAxeItem(ToolMaterials.NETHERITE,5F,-3F));

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_AXES.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Bows.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class Bows {
public static final Item WARPED_BOW = registerItem("bows/warped_bow", new VariantBowItem());

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_BOWS.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Brushes.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class Brushes {
public static final Item WARPED_BRUSH = registerItem("brushes/warped_brush", new VariantBrushItem());

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_BRUSHES.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Crossbows.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public class Crossbows {
public static final CrossbowItem WARPED_CROSSBOW = registerItem("crossbows/warped_crossbow", new VariantCrossbowItem());

private static CrossbowItem registerItem(String name, CrossbowItem item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_CROSSBOWS.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/FishingRods.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class FishingRods {
public static final Item WARPED_FISHING_ROD = registerItem("fishingrods/warped_fishing_rod", new VariantFishingRodItem());

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_FISHING_RODS.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/Hoes.java
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public class Hoes {
public static final Item WARPED_NETHERITE_HOE = registerItem("hoes/warped_netherite_hoe", new VariantHoeItem(ToolMaterials.NETHERITE,-4,0F));

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
MOD_HOES.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/xanthian/vsas/items/OnAStick.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class OnAStick {
public static final Item WARPED_WARPED_FUNGUS_ON_A_STICK = registerItem("onastick/warped_warped_fungus_on_a_stick", new VariantFungusOnAStickItem());

private static Item registerItem(String name, Item item) {
Identifier identifier = new Identifier(Initialise.MOD_ID, name.toLowerCase());
Identifier identifier = new Identifier(Initialise.MOD_ID, name);
ONASTICK.put(identifier, item);
return Registry.register(Registries.ITEM, new Identifier(Initialise.MOD_ID, name), item);
}
Expand Down
Loading

0 comments on commit 1f46949

Please sign in to comment.