Skip to content

Commit 795ca24

Browse files
committed
might kill myself about registries
1 parent 74d20bd commit 795ca24

File tree

2 files changed

+6
-14
lines changed

2 files changed

+6
-14
lines changed

common/src/main/java/net/hex_chalkcircles/registry/Hex_chalkcirclesBlockRegistry.java

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,38 +2,30 @@
22

33
import static net.hex_chalkcircles.Hex_chalkcircles.id;
44

5-
import dev.architectury.registry.CreativeTabRegistry;
65
import dev.architectury.registry.registries.DeferredRegister;
76
import dev.architectury.registry.registries.RegistrySupplier;
87
import net.hex_chalkcircles.Hex_chalkcircles;
98
import net.hex_chalkcircles.blocks.BlockDustRune;
10-
import net.hex_chalkcircles.item.*;
119
import net.minecraft.core.Registry;
12-
import net.minecraft.world.item.CreativeModeTab;
13-
import net.minecraft.world.item.Item;
14-
import net.minecraft.world.item.ItemStack;
1510
import net.minecraft.world.level.block.Block;
16-
import net.minecraft.world.level.block.entity.BlockEntity;
17-
import net.minecraft.world.level.block.entity.BlockEntityType;
11+
import net.minecraft.world.level.block.state.BlockBehaviour;
12+
import net.minecraft.world.level.material.Material;
1813

1914

2015
public class Hex_chalkcirclesBlockRegistry {
2116
// Register items through this
2217
public static final DeferredRegister<Block> BLOCKS = DeferredRegister.create(Hex_chalkcircles.MOD_ID, Registry.BLOCK_REGISTRY);
23-
public static final DeferredRegister<BlockEntityType<?>> BLOCKENTITIES = DeferredRegister.create(Hex_chalkcircles.MOD_ID, Registry.BLOCK_ENTITY_TYPE_REGISTRY);
18+
//public static final DeferredRegister<BlockEntityType<?>> BLOCKENTITIES = DeferredRegister.create(Hex_chalkcircles.MOD_ID, Registry.BLOCK_ENTITY_TYPE_REGISTRY);
2419

25-
private static final Item.Properties CHALKCIRCLES_64STACK = new Item.Properties().stacksTo(64);
26-
private static final Item.Properties CHALKCIRCLES_16STACK = new Item.Properties().stacksTo(16);
27-
private static final Item.Properties CHALKCIRCLES_UNSTACKABLE = new Item.Properties().stacksTo(1);
2820

2921

3022
public static void init() {
3123
BLOCKS.register();
32-
BLOCKENTITIES.register();
24+
//BLOCKENTITIES.register();
3325
}
3426

3527
// A new creative tab. Notice how it is one of the few things that are not deferred
3628

3729
// During the loading phase, refrain from accessing suppliers' items (e.g. EXAMPLE_ITEM.get()), they will not be available
38-
public static final RegistrySupplier<BlockDustRune> CHALK_RUNE = BLOCKS.register("chalk_square_block", () -> new BlockDustRune();
30+
public static final RegistrySupplier<Block> CHALK_RUNE = BLOCKS.register("chalk_square_block", () -> new BlockDustRune(null));
3931
}

common/src/main/java/net/hex_chalkcircles/registry/Hex_chalkcirclesItemRegistry.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,6 @@ public static void init() {
3030

3131
// During the loading phase, refrain from accessing suppliers' items (e.g. EXAMPLE_ITEM.get()), they will not be available
3232
public static final RegistrySupplier<Item> CHALKSTICK_ITEM = ITEMS.register("amethyst_chalk", () -> new ItemChalkStick(CHALKCIRCLES_16STACK));
33-
public static final RegistrySupplier<BlockItem> CHALKSQUARE_ITEM = ITEMS.register("chalk_square_item", () -> new BlockItem(Hex_chalkcirclesBlockRegistry.CHALK_RUNE.get(), CHALKCIRCLES_64STACK));
33+
public static final RegistrySupplier<BlockItem> CHALKSQUARE_BLOCK_ITEM = ITEMS.register("chalk_square_block", () -> new BlockItem(Hex_chalkcirclesBlockRegistry.CHALK_RUNE.get(), CHALKCIRCLES_64STACK));
3434

3535
}

0 commit comments

Comments
 (0)