|
| 1 | +package cn.kycraft.kuayue.parts.carriages.c25; |
| 2 | + |
| 3 | +import cn.kycraft.kuayue.KuaYue; |
| 4 | +import cn.kycraft.kuayue.parts.KuaYueTrainPanelModule; |
| 5 | +import cn.kycraft.kuayue.parts.core.panel.*; |
| 6 | +import cn.kycraft.kuayue.parts.core.panel.custom_rendered.CustomRenderedDoorBlock; |
| 7 | +import cn.kycraft.kuayue.parts.core.panel.custom_rendered.CustomRenderedEndFaceBlock; |
| 8 | +import cn.kycraft.kuayue.parts.core.panel.registration.PanelReg; |
| 9 | +import cn.kycraft.kuayue.parts.core.panel.registration.SlabReg; |
| 10 | +import cn.kycraft.kuayue.parts.core.panel.window.TrainOpenableWindowBlock; |
| 11 | +import cn.kycraft.kuayue.parts.core.panel.window.TrainSmallWindowBlock; |
| 12 | +import cn.kycraft.kuayue.parts.core.panel.window.TrainUnOpenableWindowBlock; |
| 13 | +import io.micronaut.context.annotation.Context; |
| 14 | +import lib.kasuga.registration.RegistryGroup; |
| 15 | +import lib.kasuga.registration.minecraft.block.BlockRegConfigurations; |
| 16 | +import lib.kasuga.registration.minecraft.item.ItemRegConfigurations; |
| 17 | +import net.createmod.catnip.data.Couple; |
| 18 | +import net.minecraft.resources.ResourceLocation; |
| 19 | +import net.minecraft.world.item.DyeColor; |
| 20 | +import net.minecraft.world.level.block.RenderShape; |
| 21 | +import net.minecraft.world.phys.Vec3; |
| 22 | + |
| 23 | +import static cn.kycraft.kuayue.parts.KuaYueTrainPanelModule.TRAIN_PANEL_TAB; |
| 24 | + |
| 25 | +@Context() |
| 26 | +public class C25BPanel { |
| 27 | + |
| 28 | + public static final RegistryGroup GROUP_C25B = |
| 29 | + new RegistryGroup().configure( |
| 30 | + BlockRegConfigurations.adopt(block -> block |
| 31 | + .noOcclusion() |
| 32 | + .strength(1.5f, 3f) |
| 33 | + .mapColor(DyeColor.BLUE) |
| 34 | + ) |
| 35 | + ).configure( |
| 36 | + ItemRegConfigurations.adopt( |
| 37 | + item -> item.stacksTo(8) |
| 38 | + .tabTo(TRAIN_PANEL_TAB) |
| 39 | + ) |
| 40 | + ).setParent(KuaYueTrainPanelModule.REGISTRY_GROUP); |
| 41 | + |
| 42 | + public static final PanelReg<TrainPanelBlock> PANEL_BOTTOM_25B = |
| 43 | + new PanelReg<>("panel_bottom_25b", TrainPanelBlock::new) |
| 44 | + .setParent(GROUP_C25B); |
| 45 | + |
| 46 | + public static final PanelReg<TrainPanelBlock> PANEL_MIDDLE_25B = |
| 47 | + new PanelReg<>("panel_middle_25b", TrainPanelBlock::new) |
| 48 | + .setParent(GROUP_C25B); |
| 49 | + |
| 50 | + public static final PanelReg<TrainHingePanelBlock> PANEL_SYMBOL_MARSHALLED_25B = |
| 51 | + new PanelReg<>("panel_symbol_marshalled_25b", TrainHingePanelBlock::new) |
| 52 | + .setParent(GROUP_C25B); |
| 53 | + |
| 54 | + public static final PanelReg<TrainPanelBlock> PANEL_TOP_25B = |
| 55 | + new PanelReg<>("panel_top_25b", TrainPanelBlock::new) |
| 56 | + .setParent(GROUP_C25B); |
| 57 | + |
| 58 | + public static final PanelReg<TrainPanelBlock> PANEL_TOP_25B_2 = |
| 59 | + new PanelReg<>("panel_top_25b_2", TrainPanelBlock::new) |
| 60 | + .setParent(GROUP_C25B); |
| 61 | + |
| 62 | + public static final PanelReg<TrainSmallWindowBlock> WINDOW_OC_25B = |
| 63 | + new PanelReg<>("window_oc_25b", TrainSmallWindowBlock::new) |
| 64 | + .setParent(GROUP_C25B); |
| 65 | + |
| 66 | + public static final PanelReg<TrainSmallWindowBlock> WINDOW_OC_SMALL_25B = |
| 67 | + new PanelReg<>("window_oc_small_25b", TrainSmallWindowBlock::new) |
| 68 | + .setParent(GROUP_C25B); |
| 69 | + |
| 70 | + public static final PanelReg<TrainSmallWindowBlock> WINDOW_OC_TOILET_25B = |
| 71 | + new PanelReg<>("window_oc_toilet_25b", TrainSmallWindowBlock::new) |
| 72 | + .setParent(GROUP_C25B); |
| 73 | + |
| 74 | + public static final PanelReg<TrainOpenableWindowBlock> WINDOW_OC_WIDE_25B = |
| 75 | + new PanelReg<>("window_oc_wide_25b", p -> new TrainOpenableWindowBlock(p, 2)) |
| 76 | + .setParent(GROUP_C25B); |
| 77 | + |
| 78 | + public static final PanelReg<TrainUnOpenableWindowBlock> WINDOW_OC_WIDE_SEALED_25B = |
| 79 | + new PanelReg<>("window_oc_wide_sealed_25b", p -> new TrainUnOpenableWindowBlock(p, 2)) |
| 80 | + .setParent(GROUP_C25B); |
| 81 | + |
| 82 | + public static final PanelReg<CustomRenderedDoorBlock> DOOR_25B = |
| 83 | + new PanelReg<>("door_25b", p -> new CustomRenderedDoorBlock( |
| 84 | + p, |
| 85 | + Couple.create( |
| 86 | + ResourceLocation.fromNamespaceAndPath(KuaYue.MODID, "door/original_25b_door_bottom_hinge"), |
| 87 | + ResourceLocation.fromNamespaceAndPath(KuaYue.MODID, "door/original_25b_door_top_hinge") |
| 88 | + ), |
| 89 | + Couple.create( |
| 90 | + ResourceLocation.fromNamespaceAndPath(KuaYue.MODID, "door/original_25b_door_bottom"), |
| 91 | + ResourceLocation.fromNamespaceAndPath(KuaYue.MODID, "door/original_25b_door_top") |
| 92 | + ), |
| 93 | + new Vec3(0, 0, 0), |
| 94 | + new Vec3(0, 0, -.124), |
| 95 | + RenderShape.ENTITYBLOCK_ANIMATED, |
| 96 | + false |
| 97 | + )) |
| 98 | + .setParent(GROUP_C25B); |
| 99 | + |
| 100 | + public static final PanelReg<CustomRenderedEndFaceBlock> END_FACE_25B_1 = |
| 101 | + new PanelReg<>("end_face_25b_1", p -> new CustomRenderedEndFaceBlock( |
| 102 | + p, |
| 103 | + TrainPanelProperties.DoorType.ROTATE_SINGLE_SIDED, |
| 104 | + "carriage/carriage25b/end_face/end_face_door_original_25b", |
| 105 | + null, |
| 106 | + "carriage/carriage25b/end_face/end_face_original_25b_1" |
| 107 | + )) |
| 108 | + .setParent(GROUP_C25B); |
| 109 | + |
| 110 | + public static final PanelReg<CustomRenderedEndFaceBlock> END_FACE_25B_2 = |
| 111 | + new PanelReg<>("end_face_25b_2", p -> new CustomRenderedEndFaceBlock( |
| 112 | + p, |
| 113 | + TrainPanelProperties.DoorType.ROTATE_SINGLE_SIDED, |
| 114 | + "carriage/carriage25b/end_face/end_face_door_original_25b", |
| 115 | + null, |
| 116 | + "carriage/carriage25b/end_face/end_face_original_25b_2" |
| 117 | + )) |
| 118 | + .setParent(GROUP_C25B); |
| 119 | + |
| 120 | + public static final PanelReg<CustomRenderedEndFaceBlock> END_FACE_25B_3 = |
| 121 | + new PanelReg<>("end_face_25b_3", p -> new CustomRenderedEndFaceBlock( |
| 122 | + p, |
| 123 | + TrainPanelProperties.DoorType.ROTATE_SINGLE_SIDED, |
| 124 | + "carriage/carriage25b/end_face/end_face_door_original_25b", |
| 125 | + null, |
| 126 | + "carriage/carriage25b/end_face/end_face_original_25b_3" |
| 127 | + )) |
| 128 | + .setParent(GROUP_C25B); |
| 129 | + |
| 130 | + public static final SlabReg<SlabBlock> FLOOR_25B = |
| 131 | + new SlabReg<>("floor_25b", p -> new SlabBlock(p, false)) |
| 132 | + .mapColor(DyeColor.GREEN) |
| 133 | + .setParent(GROUP_C25B); |
| 134 | + |
| 135 | + public static final SlabReg<SlabBlock> TOILET_DD_25B = |
| 136 | + new SlabReg<>("toilet_dd_25b", p -> new SlabBlock(p, false)) |
| 137 | + .mapColor(DyeColor.GREEN) |
| 138 | + .setParent(GROUP_C25B); |
| 139 | + |
| 140 | + public static final SlabReg<LadderBlock> LADDER_25B = |
| 141 | + new SlabReg<>("ladder_25b", LadderBlock::new) |
| 142 | + .setParent(GROUP_C25B); |
| 143 | +} |
0 commit comments