Skip to content

Commit

Permalink
Fix pipe help tooltip to include sneak key
Browse files Browse the repository at this point in the history
  • Loading branch information
Swedz committed Sep 23, 2024
1 parent 6f09848 commit bc63ac0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1649,7 +1649,7 @@
"text.modern_industrialization.PipeConnectionTooltipExtractOnly": "Extract only",
"text.modern_industrialization.PipeConnectionTooltipInsertOnly": "Insert only",
"text.modern_industrialization.PipeConnectionTooltipInsertOrExtract": "Insert or Extract",
"text.modern_industrialization.PipeHelp1": "Can be instantly retrieved by pressing %s with any Wrench.",
"text.modern_industrialization.PipeHelp1": "Can be instantly retrieved by pressing %s + %s with any Wrench.",
"text.modern_industrialization.PipeHelp2": "Use %s + %s to connect directly the pipe to the target block.",
"text.modern_industrialization.PriorityExtract": "Extract priority: %d",
"text.modern_industrialization.PriorityInsert": "Insert priority: %d",
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/aztech/modern_industrialization/MIText.java
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ public enum MIText {
PipeConnectionTooltipExtractOnly("Extract only"),
PipeConnectionTooltipInsertOnly("Insert only"),
PipeConnectionTooltipInsertOrExtract("Insert or Extract"),
PipeHelp1("Can be instantly retrieved by pressing %s with any Wrench."),
PipeHelp1("Can be instantly retrieved by pressing %s + %s with any Wrench."),
PipeHelp2("Use %s + %s to connect directly the pipe to the target block."),
PriorityExtract("Extract priority: %d"),
PriorityInsert("Insert priority: %d"),
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/aztech/modern_industrialization/MITooltips.java
Original file line number Diff line number Diff line change
Expand Up @@ -413,10 +413,10 @@ public Component parse(Double ratio) {
: Optional.of(new Line(MIText.MachineCasingVoltage).arg(Component.translatable(tier.shortEnglishKey())).build());
});

public static final TooltipAttachment TRASH_CAN_HELP = TooltipAttachment.ofMultilines(
public static final TooltipAttachment PIPE_HELP = TooltipAttachment.ofMultilines(
(itemStack, item) -> {
return (item instanceof PipeItem pipe && (pipe.isItemPipe() || pipe.isFluidPipe())) ? Optional.of(List.of(
line(MIText.PipeHelp1).arg("use", KEYBIND_PARSER).build(),
line(MIText.PipeHelp1).arg("sneak", KEYBIND_PARSER).arg("use", KEYBIND_PARSER).build(),
line(MIText.PipeHelp2).arg("sneak", KEYBIND_PARSER).arg("use", KEYBIND_PARSER).build())) : Optional.empty();
});

Expand Down

0 comments on commit bc63ac0

Please sign in to comment.