diff --git a/src/generated/resources/.cache/cache b/src/generated/resources/.cache/cache index c5fbecd9a..21ba221e9 100644 --- a/src/generated/resources/.cache/cache +++ b/src/generated/resources/.cache/cache @@ -337,7 +337,7 @@ e8b0a401c10d1ba67ed71ba31bd5f9bc28571b65 assets/create/blockstates/powered_toggl d06cd9a1101b18d306a786320aab12018b1325d6 assets/create/blockstates/purple_sail.json 92957119abd5fbcca36a113b2a80255fd70fc303 assets/create/blockstates/purple_seat.json 61035f8afe75ff7bbd291da5d8690bcbebe679eb assets/create/blockstates/purple_valve_handle.json -d2e6f19325be65457e94bea44fd52863c0f66be7 assets/create/blockstates/radial_chassis.json +ab2a1bf8f37f1c64d00538867f4c3a97195bd3c4 assets/create/blockstates/radial_chassis.json 45877c4d90a7185c2f304edbd67379d800920439 assets/create/blockstates/red_sail.json da1b08387af7afa0855ee8d040f620c01f20660a assets/create/blockstates/red_seat.json 722fc77bbf387af8a4016e42cbf9501d2b968881 assets/create/blockstates/red_valve_handle.json @@ -402,16 +402,16 @@ a3a11524cd3515fc01d905767b4b7ea782adaf03 assets/create/blockstates/yellow_seat.j 7f39521b211441f5c3e06d60c5978cebe16cacfb assets/create/blockstates/zinc_block.json b7181bcd8182b2f17088e5aa881f374c9c65470c assets/create/blockstates/zinc_ore.json 8bb8625cf3b710c114c1ca5e3bfb94d6ac9b1a76 assets/create/lang/en_ud.json -848a057a4b3e84c0f1ef9bbd01646b87e1903e5f assets/create/lang/en_us.json -e5647da894fcc56bb8c6a068c28db8a6881342f6 assets/create/lang/unfinished/de_de.json -2613c0b9b87bfd1e982e73890a8f2bd3f0e38be4 assets/create/lang/unfinished/fr_fr.json -8afc394564890f3949459026732de840c026120e assets/create/lang/unfinished/it_it.json -afebad8276bcd46942cae88499c85ae74bdd9e16 assets/create/lang/unfinished/ja_jp.json -2764bf19ed427a2f2f7c0d40e5742ef03a1b8ca9 assets/create/lang/unfinished/ko_kr.json -4a95a57c4df6fb9322cc9fcca6939cce34d7fc40 assets/create/lang/unfinished/nl_nl.json -bcc94f62217bf70e5c8a29cd0bbfb9b613f204bd assets/create/lang/unfinished/pt_br.json -75b93204c8913fb8c063f2f3131bab9b7cfb2182 assets/create/lang/unfinished/ru_ru.json -e01057fac180ae4721014cc1d47d3e2308dc9772 assets/create/lang/unfinished/zh_cn.json +f2c5943e663af081a1947125ef86e61a9d33ca77 assets/create/lang/en_us.json +3f254002ce0793f75c726b95dd01c68f6ba64a86 assets/create/lang/unfinished/de_de.json +eb0398e72c58e4a4e50b4aa88b04d97bf58b4e8e assets/create/lang/unfinished/fr_fr.json +132275ee905f0b61a92299e0c450db06db270e44 assets/create/lang/unfinished/it_it.json +1857e731de761c6cfc659e219a98cb8bffcdeee1 assets/create/lang/unfinished/ja_jp.json +928908a7b362edf15d0207654072e9a774e3be86 assets/create/lang/unfinished/ko_kr.json +e6145c339235bd522d2b40af9a93f1b2ab53caa5 assets/create/lang/unfinished/nl_nl.json +6b1089f1f38b9e1d03d5c073da86d77d5f88ac25 assets/create/lang/unfinished/pt_br.json +d998c4cb355fdfb5ae60a6ff90647fba6ae4903f assets/create/lang/unfinished/ru_ru.json +2227dbf1852cd5c921267f1a338411f24fded76d assets/create/lang/unfinished/zh_cn.json 487a511a01b2a4531fb672f917922312db78f958 assets/create/models/block/acacia_window.json b48060cba1a382f373a05bf0039054053eccf076 assets/create/models/block/acacia_window_pane_noside.json 3066db1bf03cffa1a9c7fbacf47ae586632f4eb3 assets/create/models/block/acacia_window_pane_noside_alt.json diff --git a/src/generated/resources/assets/create/lang/en_us.json b/src/generated/resources/assets/create/lang/en_us.json index d7a374810..a5c992c25 100644 --- a/src/generated/resources/assets/create/lang/en_us.json +++ b/src/generated/resources/assets/create/lang/en_us.json @@ -1509,9 +1509,7 @@ "block.create.mechanical_mixer.tooltip": "MECHANICAL MIXER", "block.create.mechanical_mixer.tooltip.summary": "A kinetic whisk for applying any shapeless crafting recipes to items beneath it. Requires constant _Rotational_ _Force_ and a _Basin_ placed below (with a gap in between).", "block.create.mechanical_mixer.tooltip.condition1": "When above Basin", - "block.create.mechanical_mixer.tooltip.behaviour1": "Starts to mix items in the basin whenever all necessary ingredients are present.", - "block.create.mechanical_mixer.tooltip.control1": "When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "Stalls the Mixer, perfect for crafting that recipe for the very first time!", + "block.create.mechanical_mixer.tooltip.behaviour1": "Starts to mix items in the basin whenever all necessary ingredients are present. To prevent unwanted recipes, use the filter slot on the basin or cut the rotational force until all desired ingredients have been added.", "block.create.mechanical_crafter.tooltip": "MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "A kinetic assembler for _automating_ any _shaped_ _crafting_ recipe. Place _multiple_ _in_ _a_ _grid_ corresponding to your recipe, and _arrange_ _their_ _belts_ to create a _flow_ that exits the grid on one of the crafters.", diff --git a/src/generated/resources/assets/create/lang/unfinished/de_de.json b/src/generated/resources/assets/create/lang/unfinished/de_de.json index 3a2fb936d..d44f475c5 100644 --- a/src/generated/resources/assets/create/lang/unfinished/de_de.json +++ b/src/generated/resources/assets/create/lang/unfinished/de_de.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 1215", + "_": "Missing Localizations: 1213", "_": "->------------------------] Game Elements [------------------------<-", @@ -1510,9 +1510,7 @@ "block.create.mechanical_mixer.tooltip": "UNLOCALIZED: MECHANICAL MIXER", "block.create.mechanical_mixer.tooltip.summary": "UNLOCALIZED: A kinetic whisk for applying any shapeless crafting recipes to items beneath it. Requires constant _Rotational_ _Force_ and a _Basin_ placed below (with a gap in between).", "block.create.mechanical_mixer.tooltip.condition1": "UNLOCALIZED: When above Basin", - "block.create.mechanical_mixer.tooltip.behaviour1": "UNLOCALIZED: Starts to mix items in the basin whenever all necessary ingredients are present.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", + "block.create.mechanical_mixer.tooltip.behaviour1": "UNLOCALIZED: Starts to mix items in the basin whenever all necessary ingredients are present. To prevent unwanted recipes, use the filter slot on the basin or cut the rotational force until all desired ingredients have been added.", "block.create.mechanical_crafter.tooltip": "UNLOCALIZED: MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "UNLOCALIZED: A kinetic assembler for _automating_ any _shaped_ _crafting_ recipe. Place _multiple_ _in_ _a_ _grid_ corresponding to your recipe, and _arrange_ _their_ _belts_ to create a _flow_ that exits the grid on one of the crafters.", diff --git a/src/generated/resources/assets/create/lang/unfinished/fr_fr.json b/src/generated/resources/assets/create/lang/unfinished/fr_fr.json index d8fcfabff..c5d9a8b3f 100644 --- a/src/generated/resources/assets/create/lang/unfinished/fr_fr.json +++ b/src/generated/resources/assets/create/lang/unfinished/fr_fr.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 866", + "_": "Missing Localizations: 864", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "Un fouet cinétique pour appliquer toutes les recettes d'artisanat informes aux objets en dessous. Nécessite une _force_ _de_ _rotation_ constant et un _bassin_ placé en dessous (avec un espace entre les deux).", "block.create.mechanical_mixer.tooltip.condition1": "Lorsqu'au-dessus d'un bassin", "block.create.mechanical_mixer.tooltip.behaviour1": "Commence à mélanger les objets dans le bassin lorsque tous les ingrédients nécessaires sont présents.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "ÉTABLI MÉCANIQUE", "block.create.mechanical_crafter.tooltip.summary": "Un assembleur cinétique pour _automatiser_ n'importe quelle recette _en_ _forme_. Placez-en _plusieurs_ _dans_ _une_ _grille_ correspondant à votre recette, et _arrangez_ _leurs_ _tapis_ _roulant_ pour créer un _flux_ qui sort de la grille sur l'un des établis.", diff --git a/src/generated/resources/assets/create/lang/unfinished/it_it.json b/src/generated/resources/assets/create/lang/unfinished/it_it.json index 926b5cb34..6f3579de9 100644 --- a/src/generated/resources/assets/create/lang/unfinished/it_it.json +++ b/src/generated/resources/assets/create/lang/unfinished/it_it.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 850", + "_": "Missing Localizations: 848", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "Una frusta cinetica per applicare qualsiasi ricetta di creazione informe agli oggetti sottostanti. Richiede una _Forza_ _di_ _Rotazione_ costante e una _Bacinella_ posizionata sotto (con uno spazio in mezzo).", "block.create.mechanical_mixer.tooltip.condition1": "Quando sopra a una Bacinella", "block.create.mechanical_mixer.tooltip.behaviour1": "Inizia a mescolare gli oggetti nella bacinella ogni volta che sono presenti tutti gli ingredienti necessari.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "COSTRUTTORE MECCANICO", "block.create.mechanical_crafter.tooltip.summary": "Un assemblatore cinetico per _automatizzare_ qualsiasi ricetta di _creazione_ _modellata_. Posiziona i _multipli_ _in_ _una_ _griglia_ corrispondente alla tua ricetta, e _disponi_ _i_ _loro_ _nastri_ per creare un _flusso_ che esce dalla griglia su uno degli costruttori.", diff --git a/src/generated/resources/assets/create/lang/unfinished/ja_jp.json b/src/generated/resources/assets/create/lang/unfinished/ja_jp.json index 079fe1eb8..3d206e302 100644 --- a/src/generated/resources/assets/create/lang/unfinished/ja_jp.json +++ b/src/generated/resources/assets/create/lang/unfinished/ja_jp.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 849", + "_": "Missing Localizations: 847", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "その下のアイテムに形状のない製作レシピを適用するための動力ミキサー。 一定の_回転力_と下に配置された_鉢_が必要です(間にギャップがあります)。", "block.create.mechanical_mixer.tooltip.condition1": "鉢の上にあるとき", "block.create.mechanical_mixer.tooltip.behaviour1": "必要なすべての成分が存在するときはいつでも、鉢のアイテムの混合を開始します。", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "メカニカルクラフト", "block.create.mechanical_crafter.tooltip.summary": "_あらゆる形状の製作レシピ_を自動化するための動的アセンブラー。 _レシピに対応するグリッドに複数を配置_し、_フェアベルトを配置して_、いずれかのクラフターのグリッドから出る_流れ_を作成します。", diff --git a/src/generated/resources/assets/create/lang/unfinished/ko_kr.json b/src/generated/resources/assets/create/lang/unfinished/ko_kr.json index 3cdc53b85..5ccdba4cd 100644 --- a/src/generated/resources/assets/create/lang/unfinished/ko_kr.json +++ b/src/generated/resources/assets/create/lang/unfinished/ko_kr.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 850", + "_": "Missing Localizations: 848", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "아래있는 아이템을 조합할 혼합기입니다. _지속적인_ _회전력_과 한 칸 아래에 _대야_가 필요합니다.", "block.create.mechanical_mixer.tooltip.condition1": "대야 위에 있을 때", "block.create.mechanical_mixer.tooltip.behaviour1": "모든 필요한 아이템이 준비될 때마다 대야 안의 아이템을 섞기 시작합니다.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "모든 조합법을 _자동화_할 장치입니다. 조합법대로 여러개를 _격자_로 설치하고, 화살표를 돌려 _한_ _곳으로_ _모이게_ 설정해야합니다.", diff --git a/src/generated/resources/assets/create/lang/unfinished/nl_nl.json b/src/generated/resources/assets/create/lang/unfinished/nl_nl.json index 7fd208bee..1392f3030 100644 --- a/src/generated/resources/assets/create/lang/unfinished/nl_nl.json +++ b/src/generated/resources/assets/create/lang/unfinished/nl_nl.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 1156", + "_": "Missing Localizations: 1154", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "Een kinetische garde voor het toepassen van vormloze recepten op objecten eronder. Vereist constante _Rotatiekracht_ en een _Bekken_ hieronder geplaatst (met een tussenruimte).", "block.create.mechanical_mixer.tooltip.condition1": "Wanneer boven een Bekken", "block.create.mechanical_mixer.tooltip.behaviour1": "Begint objecten in het bekken te mengen wanneer alle benodigde ingrediënten aanwezig zijn.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "UNLOCALIZED: MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "UNLOCALIZED: A kinetic assembler for _automating_ any _shaped_ _crafting_ recipe. Place _multiple_ _in_ _a_ _grid_ corresponding to your recipe, and _arrange_ _their_ _belts_ to create a _flow_ that exits the grid on one of the crafters.", diff --git a/src/generated/resources/assets/create/lang/unfinished/pt_br.json b/src/generated/resources/assets/create/lang/unfinished/pt_br.json index 6f8b8d787..2614e4184 100644 --- a/src/generated/resources/assets/create/lang/unfinished/pt_br.json +++ b/src/generated/resources/assets/create/lang/unfinished/pt_br.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 1222", + "_": "Missing Localizations: 1220", "_": "->------------------------] Game Elements [------------------------<-", @@ -1510,9 +1510,7 @@ "block.create.mechanical_mixer.tooltip": "UNLOCALIZED: MECHANICAL MIXER", "block.create.mechanical_mixer.tooltip.summary": "UNLOCALIZED: A kinetic whisk for applying any shapeless crafting recipes to items beneath it. Requires constant _Rotational_ _Force_ and a _Basin_ placed below (with a gap in between).", "block.create.mechanical_mixer.tooltip.condition1": "UNLOCALIZED: When above Basin", - "block.create.mechanical_mixer.tooltip.behaviour1": "UNLOCALIZED: Starts to mix items in the basin whenever all necessary ingredients are present.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", + "block.create.mechanical_mixer.tooltip.behaviour1": "UNLOCALIZED: Starts to mix items in the basin whenever all necessary ingredients are present. To prevent unwanted recipes, use the filter slot on the basin or cut the rotational force until all desired ingredients have been added.", "block.create.mechanical_crafter.tooltip": "UNLOCALIZED: MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "UNLOCALIZED: A kinetic assembler for _automating_ any _shaped_ _crafting_ recipe. Place _multiple_ _in_ _a_ _grid_ corresponding to your recipe, and _arrange_ _their_ _belts_ to create a _flow_ that exits the grid on one of the crafters.", diff --git a/src/generated/resources/assets/create/lang/unfinished/ru_ru.json b/src/generated/resources/assets/create/lang/unfinished/ru_ru.json index bc8d3f70c..83aaef86a 100644 --- a/src/generated/resources/assets/create/lang/unfinished/ru_ru.json +++ b/src/generated/resources/assets/create/lang/unfinished/ru_ru.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 525", + "_": "Missing Localizations: 523", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "Кинетический венчик, используемый для смешивания предметов, находящихся под ним. Требуется _постоянная_ _вращательная_ _сила_ и _чаша_, расположенная внизу (с промежутком между ними).", "block.create.mechanical_mixer.tooltip.condition1": "Когда над чашей", "block.create.mechanical_mixer.tooltip.behaviour1": "Начинает смешивать предметы в бассейне, когда присутствуют все необходимые ингредиенты.", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "_Кинетический_ _сборщик_ для автоматизации любого рецепта крафта. _Поместите_ _ингредиенты_ в сетку, _соответственно_ _нужному_ _рецепту_, и расположите их так, чтобы _создать_ _поток_, который _кончается_ на одном из крафтеров.", diff --git a/src/generated/resources/assets/create/lang/unfinished/zh_cn.json b/src/generated/resources/assets/create/lang/unfinished/zh_cn.json index e84ec96a2..0839dfbfc 100644 --- a/src/generated/resources/assets/create/lang/unfinished/zh_cn.json +++ b/src/generated/resources/assets/create/lang/unfinished/zh_cn.json @@ -1,5 +1,5 @@ { - "_": "Missing Localizations: 533", + "_": "Missing Localizations: 531", "_": "->------------------------] Game Elements [------------------------<-", @@ -1511,8 +1511,6 @@ "block.create.mechanical_mixer.tooltip.summary": "一种能够动态进行搅拌的机器,需要恒定且够快的速度,并且下方需要放置_工作盆_(中间需要一格高)", "block.create.mechanical_mixer.tooltip.condition1": "当位于工作盆上方", "block.create.mechanical_mixer.tooltip.behaviour1": "只要_工作盆_中有必要的物品,就会将物品进行搅拌", - "block.create.mechanical_mixer.tooltip.control1": "UNLOCALIZED: When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "UNLOCALIZED: Stalls the Mixer, perfect for crafting that recipe for the very first time!", "block.create.mechanical_crafter.tooltip": "MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "一种依靠_动能_的_自动_合成台。根据想要合成物品的_合成表_来摆放_相应数量_的机械制造机,并且用扳手调整物品在制造机里的_传动方向_以让他们合在一起后被输出", diff --git a/src/main/java/com/simibubi/create/AllTags.java b/src/main/java/com/simibubi/create/AllTags.java index f4ac0a4a4..86e431bac 100644 --- a/src/main/java/com/simibubi/create/AllTags.java +++ b/src/main/java/com/simibubi/create/AllTags.java @@ -113,6 +113,30 @@ public class AllTags { .addTag(tag)); } } + + public static enum AllFluidTags { + NO_INFINITE_DRAINING + + ; + public Tag tag; + + private AllFluidTags() { + this(MOD, ""); + } + + private AllFluidTags(NameSpace namespace) { + this(namespace, ""); + } + + private AllFluidTags(NameSpace namespace, String path) { + tag = new FluidTags.Wrapper( + new ResourceLocation(namespace.id, (path.isEmpty() ? "" : path + "/") + Lang.asId(name()))); + } + + public boolean matches(Fluid fluid) { + return fluid != null && fluid.isIn(tag); + } + } public static enum AllBlockTags { WINDMILL_SAILS, FAN_HEATERS, WINDOWABLE, NON_MOVABLE, BRITTLE, SEATS, SAILS, VALVE_HANDLES, FAN_TRANSPARENT, SAFE_NBT, SLIMY_LOGS(TIC), BEACON_BASE_BLOCKS(MC) diff --git a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/BlockMovementTraits.java b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/BlockMovementTraits.java index ed0710605..27019f020 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/BlockMovementTraits.java +++ b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/BlockMovementTraits.java @@ -33,6 +33,7 @@ import net.minecraft.block.CarpetBlock; import net.minecraft.block.DoorBlock; import net.minecraft.block.FenceGateBlock; import net.minecraft.block.FlowerPotBlock; +import net.minecraft.block.GrindstoneBlock; import net.minecraft.block.HorizontalBlock; import net.minecraft.block.HorizontalFaceBlock; import net.minecraft.block.LadderBlock; @@ -99,6 +100,8 @@ public class BlockMovementTraits { if (AllBlocks.BELT.has(blockState)) return true; + if (blockState.getBlock() instanceof GrindstoneBlock) + return true; return blockState.getPushReaction() != PushReaction.BLOCK; } @@ -117,7 +120,7 @@ public class BlockMovementTraits { return true; if (block instanceof AbstractPressurePlateBlock) return true; - if (block instanceof HorizontalFaceBlock) + if (block instanceof HorizontalFaceBlock && !(block instanceof GrindstoneBlock)) return true; if (block instanceof CartAssemblerBlock) return false; diff --git a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/train/CouplingRenderer.java b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/train/CouplingRenderer.java index 19c3cc17b..6b8078be2 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/train/CouplingRenderer.java +++ b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/train/CouplingRenderer.java @@ -46,6 +46,10 @@ public class CouplingRenderer { public static void renderCoupling(MatrixStack ms, IRenderTypeBuffer buffer, Couple carts) { ClientWorld world = Minecraft.getInstance().world; + + if (carts.getFirst() == null || carts.getSecond() == null) + return; + Couple lightValues = carts.map(c -> WorldRenderer.getLightmapCoordinates(world, new BlockPos(c.getBoundingBox() .getCenter()))); diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidNetwork.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidNetwork.java index a0e0ac8cc..364b7cf29 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidNetwork.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/FluidNetwork.java @@ -191,6 +191,12 @@ public class FluidNetwork { transfer = handler.drain(toExtract, action); } + if (transfer.isEmpty()) { + FluidStack genericExtract = handler.drain(flowSpeed, action); + if (!genericExtract.isEmpty() && genericExtract.isFluidEqual(fluid)) + transfer = genericExtract; + } + if (transfer.isEmpty()) return; diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidDrainingBehaviour.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidDrainingBehaviour.java index b198e7067..a8607fe61 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidDrainingBehaviour.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidDrainingBehaviour.java @@ -253,14 +253,14 @@ public class FluidDrainingBehaviour extends FluidManipulationBehaviour { } private void continueSearch() { - search(fluid, frontier, visited, (e, d) -> { + fluid = search(fluid, frontier, visited, (e, d) -> { queue.enqueue(new BlockPosEntry(e, d)); validationSet.add(e); }, false); World world = getWorld(); int maxBlocks = maxBlocks(); - if (visited.size() > maxBlocks && maxBlocks != -1) { + if (visited.size() > maxBlocks && canDrainInfinitely(fluid)) { infinite = true; // Find first block with valid fluid while (true) { @@ -291,7 +291,7 @@ public class FluidDrainingBehaviour extends FluidManipulationBehaviour { search(fluid, validationFrontier, validationVisited, (e, d) -> newValidationSet.add(e), false); int maxBlocks = maxBlocks(); - if (validationVisited.size() > maxBlocks && maxBlocks != -1) { + if (validationVisited.size() > maxBlocks && canDrainInfinitely(fluid)) { if (!infinite) reset(); validationFrontier.clear(); diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidFillingBehaviour.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidFillingBehaviour.java index 0f10e53b3..2880e0980 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidFillingBehaviour.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidFillingBehaviour.java @@ -7,6 +7,7 @@ import java.util.Objects; import java.util.Set; import com.simibubi.create.foundation.advancement.AllTriggers; +import com.simibubi.create.foundation.fluid.FluidHelper; import com.simibubi.create.foundation.tileEntity.SmartTileEntity; import com.simibubi.create.foundation.tileEntity.behaviour.BehaviourType; import com.simibubi.create.foundation.utility.Iterate; @@ -178,7 +179,8 @@ public class FluidFillingBehaviour extends FluidManipulationBehaviour { updatePostWaterlogging(blockState.with(BlockStateProperties.WATERLOGGED, true)), 2 | 16); } else { replaceBlock(world, currentPos, blockState); - world.setBlockState(currentPos, fluid.getDefaultState() + world.setBlockState(currentPos, FluidHelper.convertToStill(fluid) + .getDefaultState() .getBlockState(), 2 | 16); } @@ -223,8 +225,8 @@ public class FluidFillingBehaviour extends FluidManipulationBehaviour { queue.enqueue(new BlockPosEntry(offsetPos, entry.distance + 1)); } } - - if (!simulate && success) + + if (!simulate && success) AllTriggers.triggerForNearbyPlayers(AllTriggers.HOSE_PULLEY, world, tileEntity.getPos(), 8); return success; } diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidManipulationBehaviour.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidManipulationBehaviour.java index afd8ab625..09be45515 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidManipulationBehaviour.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/FluidManipulationBehaviour.java @@ -6,6 +6,7 @@ import java.util.List; import java.util.Set; import java.util.function.BiConsumer; +import com.simibubi.create.AllTags.AllFluidTags; import com.simibubi.create.foundation.config.AllConfigs; import com.simibubi.create.foundation.fluid.FluidHelper; import com.simibubi.create.foundation.networking.AllPackets; @@ -128,16 +129,16 @@ public abstract class FluidManipulationBehaviour extends TileEntityBehaviour { .squareDistanceTo(centerOfRoot)); } - protected void search(Fluid fluid, List frontier, Set visited, + protected Fluid search(Fluid fluid, List frontier, Set visited, BiConsumer add, boolean searchDownward) { World world = getWorld(); int maxBlocks = maxBlocks(); - int maxRange = maxRange(); + int maxRange = canDrainInfinitely(fluid) ? maxRange() : maxRange() / 2; int maxRangeSq = maxRange * maxRange; int i; for (i = 0; i < searchedPerTick && !frontier.isEmpty() - && (visited.size() <= maxBlocks || maxBlocks == -1); i++) { + && (visited.size() <= maxBlocks || !canDrainInfinitely(fluid)); i++) { BlockPosEntry entry = frontier.remove(0); BlockPos currentPos = entry.pos; if (visited.contains(currentPos)) @@ -177,6 +178,8 @@ public abstract class FluidManipulationBehaviour extends TileEntityBehaviour { frontier.add(new BlockPosEntry(offsetPos, entry.distance + 1)); } } + + return fluid; } protected void playEffect(World world, BlockPos pos, Fluid fluid, boolean fillSound) { @@ -195,6 +198,10 @@ public abstract class FluidManipulationBehaviour extends TileEntityBehaviour { if (world instanceof ServerWorld) AllPackets.sendToNear(world, splooshPos, 10, new FluidSplashPacket(splooshPos, new FluidStack(fluid, 1))); } + + protected boolean canDrainInfinitely(Fluid fluid) { + return maxBlocks() != -1 && !AllFluidTags.NO_INFINITE_DRAINING.matches(fluid); + } @Override public void write(CompoundNBT nbt, boolean clientPacket) { diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/ItemDrainRenderer.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/ItemDrainRenderer.java index 6211b2510..8b7ac12f4 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/ItemDrainRenderer.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/actors/ItemDrainRenderer.java @@ -146,7 +146,7 @@ public class ItemDrainRenderer extends SmartTileEntityRenderer p_206840_1_) { - super.fillStateContainer(p_206840_1_.add(ALT)); + super.fillStateContainer(p_206840_1_.add(ALT, BlockStateProperties.WATERLOGGED)); } @Override @@ -41,12 +52,26 @@ public class GlassFluidPipeBlock extends AxisPipeBlock { public ActionResultType onWrenched(BlockState state, ItemUseContext context) { if (tryRemoveBracket(context)) return ActionResultType.SUCCESS; - BlockState newState = state; + BlockState newState; World world = context.getWorld(); BlockPos pos = context.getPos(); - newState = toRegularPipe(world, pos, state); + newState = toRegularPipe(world, pos, state).with(BlockStateProperties.WATERLOGGED, state.get(BlockStateProperties.WATERLOGGED)); world.setBlockState(pos, newState, 3); return ActionResultType.SUCCESS; } + @Override + public BlockState getStateForPlacement(BlockItemUseContext context) { + IFluidState ifluidstate = context.getWorld() + .getFluidState(context.getPos()); + BlockState state = super.getStateForPlacement(context); + return state == null ? null : state.with(BlockStateProperties.WATERLOGGED, + ifluidstate.getFluid() == Fluids.WATER); + } + + @Override + public IFluidState getFluidState(BlockState state) { + return state.get(BlockStateProperties.WATERLOGGED) ? Fluids.WATER.getStillFluidState(false) + : Fluids.EMPTY.getDefaultState(); + } } diff --git a/src/main/java/com/simibubi/create/content/contraptions/fluids/pipes/StraightPipeTileEntity.java b/src/main/java/com/simibubi/create/content/contraptions/fluids/pipes/StraightPipeTileEntity.java index 3ebea8848..f846fc6a9 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/fluids/pipes/StraightPipeTileEntity.java +++ b/src/main/java/com/simibubi/create/content/contraptions/fluids/pipes/StraightPipeTileEntity.java @@ -32,10 +32,10 @@ public class StraightPipeTileEntity extends SmartTileEntity { public StraightPipeFluidTransportBehaviour(SmartTileEntity te) { super(te); } - + @Override public boolean canHaveFlowToward(BlockState state, Direction direction) { - return state.get(AxisPipeBlock.AXIS) == direction.getAxis(); + return state.has(AxisPipeBlock.AXIS) && state.get(AxisPipeBlock.AXIS) == direction.getAxis(); } @Override diff --git a/src/main/resources/assets/create/lang/default/tooltips.json b/src/main/resources/assets/create/lang/default/tooltips.json index 513f02d52..0cf4630f9 100644 --- a/src/main/resources/assets/create/lang/default/tooltips.json +++ b/src/main/resources/assets/create/lang/default/tooltips.json @@ -379,9 +379,7 @@ "block.create.mechanical_mixer.tooltip": "MECHANICAL MIXER", "block.create.mechanical_mixer.tooltip.summary": "A kinetic whisk for applying any shapeless crafting recipes to items beneath it. Requires constant _Rotational_ _Force_ and a _Basin_ placed below (with a gap in between).", "block.create.mechanical_mixer.tooltip.condition1": "When above Basin", - "block.create.mechanical_mixer.tooltip.behaviour1": "Starts to mix items in the basin whenever all necessary ingredients are present.", - "block.create.mechanical_mixer.tooltip.control1": "When powered by redstone", - "block.create.mechanical_mixer.tooltip.action1": "Stalls the Mixer, perfect for crafting that recipe for the very first time!", + "block.create.mechanical_mixer.tooltip.behaviour1": "Starts to mix items in the basin whenever all necessary ingredients are present. To prevent unwanted recipes, use the filter slot on the basin or cut the rotational force until all desired ingredients have been added.", "block.create.mechanical_crafter.tooltip": "MECHANICAL CRAFTER", "block.create.mechanical_crafter.tooltip.summary": "A kinetic assembler for _automating_ any _shaped_ _crafting_ recipe. Place _multiple_ _in_ _a_ _grid_ corresponding to your recipe, and _arrange_ _their_ _belts_ to create a _flow_ that exits the grid on one of the crafters.",