From 6a381eb91be006a0dd43f77b9d89f834f0ef08ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=95=D0=B2=D0=B3=D0=B5=D0=BD=D0=B8=D0=B9?= <65257125+git-dopi@users.noreply.github.com> Date: Thu, 2 Jun 2022 13:09:18 +0300 Subject: [PATCH 1/2] Correction of remarks. --- src/main/resources/assets/bclib/lang/en_us.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/resources/assets/bclib/lang/en_us.json b/src/main/resources/assets/bclib/lang/en_us.json index 977e7f06..dacbab53 100644 --- a/src/main/resources/assets/bclib/lang/en_us.json +++ b/src/main/resources/assets/bclib/lang/en_us.json @@ -38,7 +38,7 @@ "title.bclib.syncfiles.modlist": "Mod Information", "message.bclib.syncfiles.modlist": "The following shows the state of your installed installed Mods.\n\nAll Mods that do not exist locally, or have a different version on the Server will be synchronized.", "title.bclib.modmissmatch": "Mod Version Conflict", - "message.bclib.modmissmatch": "Some Mods on this client do not match the version of Mods on the Server.\n\nMismatching Mods can result in odd game behavior or crashes. Please make sue that you use the same mods as the server.", + "message.bclib.modmissmatch": "Some Mods on this client do not match the version of Mods on the Server.\n\nMismatching Mods can result in odd game behavior or crashes. Please make sure that you use the same mods as the server.", "message.bclib.datafixer.progress.waitbackup": "Waiting for Backup to finish. This may take a while!", "message.bclib.datafixer.progress.reading": "Reading Data", @@ -57,4 +57,4 @@ "title.config.bclib.client.rendering.netherThickFog": "Nether Thick Fog", "tooltip.bclib.place_on": "Survives on: %s" -} \ No newline at end of file +} From 4fe6e57e053d33a2f99e8f705e0b9ad8f89ada95 Mon Sep 17 00:00:00 2001 From: Frank Date: Wed, 8 Jun 2022 10:19:37 +0200 Subject: [PATCH 2/2] Fixed Button Collision (quiqueck/BetterNether#2) --- .../java/ru/bclib/blocks/BaseButtonBlock.java | 32 +++++++++++-------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/src/main/java/ru/bclib/blocks/BaseButtonBlock.java b/src/main/java/ru/bclib/blocks/BaseButtonBlock.java index 8e20a66b..520123e9 100644 --- a/src/main/java/ru/bclib/blocks/BaseButtonBlock.java +++ b/src/main/java/ru/bclib/blocks/BaseButtonBlock.java @@ -1,7 +1,5 @@ package ru.bclib.blocks; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; import net.minecraft.client.renderer.block.model.BlockModel; import net.minecraft.client.resources.model.BlockModelRotation; import net.minecraft.client.resources.model.UnbakedModel; @@ -11,7 +9,10 @@ import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.ButtonBlock; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.AttachFace; -import org.jetbrains.annotations.Nullable; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + import ru.bclib.client.models.BasePatterns; import ru.bclib.client.models.ModelsHelper; import ru.bclib.client.models.PatternsHelper; @@ -20,15 +21,16 @@ import ru.bclib.interfaces.LootProvider; import java.util.Map; import java.util.Optional; +import org.jetbrains.annotations.Nullable; public abstract class BaseButtonBlock extends ButtonBlock implements BlockModelProvider, LootProvider { private final Block parent; - + protected BaseButtonBlock(Block parent, Properties properties, boolean sensitive) { - super(sensitive, properties); + super(sensitive, properties.noCollission()); this.parent = parent; } - + @Override @Environment(EnvType.CLIENT) public BlockModel getItemModel(ResourceLocation blockId) { @@ -36,21 +38,25 @@ public abstract class BaseButtonBlock extends ButtonBlock implements BlockModelP Optional pattern = PatternsHelper.createJson(BasePatterns.ITEM_BUTTON, parentId); return ModelsHelper.fromPattern(pattern); } - + @Override @Environment(EnvType.CLIENT) public @Nullable BlockModel getBlockModel(ResourceLocation resourceLocation, BlockState blockState) { ResourceLocation parentId = Registry.BLOCK.getKey(parent); - Optional pattern = blockState.getValue(POWERED) ? PatternsHelper.createJson( - BasePatterns.BLOCK_BUTTON_PRESSED, - parentId - ) : PatternsHelper.createJson(BasePatterns.BLOCK_BUTTON, parentId); + Optional pattern = blockState.getValue(POWERED) + ? PatternsHelper.createJson( + BasePatterns.BLOCK_BUTTON_PRESSED, + parentId + ) + : PatternsHelper.createJson(BasePatterns.BLOCK_BUTTON, parentId); return ModelsHelper.fromPattern(pattern); } - + @Override @Environment(EnvType.CLIENT) - public UnbakedModel getModelVariant(ResourceLocation stateId, BlockState blockState, Map modelCache) { + public UnbakedModel getModelVariant(ResourceLocation stateId, + BlockState blockState, + Map modelCache) { String powered = blockState.getValue(POWERED) ? "_powered" : ""; ResourceLocation modelId = new ResourceLocation(stateId.getNamespace(), "block/" + stateId.getPath() + powered); registerBlockModel(stateId, modelId, blockState, modelCache);