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
0. read https://gist.github.com/ChampionAsh5357/cf818acc53ffea6f4387fe28c2977d56 | |
1. download https://files.minecraftforge.net/net/minecraftforge/forge/index_1.20.1.html | |
2. copy gradle files&folders | |
3. update settings.gradle plugin | |
plugins { | |
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.5.0' | |
} | |
4. update meta-inf normal changes along with | |
version="${mod_version}" #mandatory | |
5. pack mcmeta (optional) "pack_format": 15 |
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
private void setup(final FMLCommonSetupEvent event) { | |
event.enqueueWork(() -> { | |
CauldronInteraction WASH_PEEL = (state, level, pos, player, hand, stack) -> { | |
if (stack.is(Items.POTATO)) { | |
//replace all the item, be generous. we could instead stack.shrink and drop just one | |
player.setItemInHand(hand, new ItemStack(PotatoModRegistry.PEELED.get(), stack.getCount())); | |
LayeredCauldronBlock.lowerFillLevel(state, level, pos); | |
return InteractionResult.sidedSuccess(level.isClientSide); | |
} | |
return InteractionResult.PASS; |
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
{ | |
"multipart": [ | |
{ "apply": { "model": "tinylightbulbs:block/part_base" }}, | |
{ "when": { "color": "black" }, | |
"apply": { "model": "tinylightbulbs:block/bulb_black", "uvlock": true } | |
}, | |
{ "when": { "color": "blue" }, | |
"apply": { "model": "tinylightbulbs:block/bulb_blue", "uvlock": true } | |
}, | |
{ "when": { "color": "brown" }, |
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
clone new copy of source code, dont use a 1.18 workspace. | |
IE make new root folder C:\code\mc119 | |
git clone [email protected]:Lothrazar/ForgeTemplate.git | |
Download forge mdk zip. we will need the following files. | |
https://files.minecraftforge.net/net/minecraftforge/forge/index_1.19.html | |
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
// PUBLIC DOMAIN | |
public static void extractFluidFromBlock(Level level, BlockPos posTarget, IFluidHandler tank) { | |
//fills always gonna be one bucket but we dont know what type yet | |
//test if its a source block, or a waterlogged block | |
BlockState targetState = level.getBlockState(posTarget); | |
FluidState fluidState = level.getFluidState(posTarget); | |
if (targetState.hasProperty(BlockStateProperties.WATERLOGGED) && targetState.getValue(BlockStateProperties.WATERLOGGED) == true) { | |
//for waterlogged it is hardcoded to water | |
int simFill = tank.fill(new FluidStack(new FluidStack(Fluids.WATER, FluidAttributes.BUCKET_VOLUME), FluidAttributes.BUCKET_VOLUME), FluidAction.SIMULATE); | |
if (simFill == FluidAttributes.BUCKET_VOLUME |
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
matchBlocks=stone_bricks mossy_stone_bricks cracked_stone_bricks oak_planks spruce_planks acacia_planks birch_planks dark_oak_planks jungle_planks warped_planks crimson_planks polished_blackstone_bricks cracked_polished_blackstone_bricks purpur_block cobblestone end_stone polished_diorite polished_granite polished_andesite diorite granite andesite stone bricks nether_bricks sandstone cut_sandstone smooth_sandstone white_concrete orange_concrete magenta_concrete light_blue_concrete yellow_concrete lime_concrete pink_concrete gray_concrete light_gray_concrete cyan_concrete purple_concrete blue_concrete brown_concrete green_concrete red_concrete black_concrete terracotta white_terracotta orange_terracotta magenta_terracotta light_blue_terracotta yellow_terracotta lime_terracotta pink_terracotta gray_terracotta light_gray_terracotta cyan_terracotta purple_terracotta blue_terracotta brown_terracotta green_terracotta red_terracotta black_terracotta | |
connectBlocks=end_stone_bricks | |
method=overlay | |
tiles=0-16 | |
connect= |
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
`[21:25:01] [Client thread/INFO] [net.minecraft.client.gui.GuiNewChat]: [CHAT] LZMP加入了游戏 | |
[21:25:01] [Server thread/INFO] [Waila]: Player EntityPlayerMP['LZMP'/219, l='新的世界', x=-242.50, y=81.00, z=232.50] connected. Sending ping | |
[21:25:01] [Server thread/INFO] [EnderCore]: Sending server configs to client for com.enderio.core.common.config.ConfigHandler | |
[21:25:01] [Server thread/INFO] [Actually Additions]: Sending Player Data to player LZMP with UUID eb1efc42-b162-3072-8659-93b0eb622cf9. | |
[21:25:09] [Netty Server IO #4/ERROR] [FML]: NetworkDispatcher exception | |
io.netty.handler.codec.DecoderException: java.io.IOException: Packet 0/27 (CPacketCreativeInventoryAction) was larger than I expected, found 1 bytes extra whilst reading packet 27 | |
at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:442) ~[netty-all-4.1.9.Final.jar:4.1.9.Final] | |
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:248) ~[netty-all-4.1.9.Final.jar:4.1.9.Final] | |
at io.netty.ch |
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
#General settings | |
[growthcontrols] | |
#List of biomes for sapling | |
"minecraft:birch_sapling" = ["minecraft:birch_forest", "minecraft:forest", "minecraft:birch_forest_hills", "minecraft:tall_birch_forest", "minecraft:tall_birch_hills"] | |
#List of biomes for sapling | |
"minecraft:jungle_sapling" = ["minecraft:jungle_edge", "minecraft:jungle", "minecraft:jungle_hills", "minecraft:modified_jungle", "minecraft:bamboo_jungle", "minecraft:bamboo_jungle_hills", "minecraft:modified_jungle_edge", "minecraft:modified_jungle"] | |
#List of biomes for sapling | |
"minecraft:oak_sapling" = ["minecraft:forest", "minecraft:dark_forest", "minecraft:wooded_mountains", "minecraft:wooded_hills", "minecraft:swamp", "minecraft:swamp_hills", "minecraft:flower_forest"] | |
#List of biomes for sapling |
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
#General settings | |
[elementaryores] | |
[elementaryores.end] | |
[elementaryores.end.ender] | |
#Min and max y levels for spawn | |
#Range: 0 ~ 256 | |
high = 127 |
NewerOlder