-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Converted TrackUndercutter's set to a tag
- Loading branch information
Showing
11 changed files
with
70 additions
and
56 deletions.
There are no files selected for viewing
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
6 changes: 6 additions & 0 deletions
6
src/generated/resources/data/railcraft/tags/blocks/track_undercutter_invalid_ballast.json
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"values": [ | ||
"#forge:sand", | ||
"#minecraft:sand" | ||
] | ||
} |
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
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
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
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
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
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
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
11 changes: 9 additions & 2 deletions
11
src/main/java/mods/railcraft/world/inventory/slot/BlockFilterSlot.java
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,20 @@ | ||
package mods.railcraft.world.inventory.slot; | ||
|
||
import java.util.function.Predicate; | ||
import net.minecraft.world.Container; | ||
import net.minecraft.world.item.BlockItem; | ||
import net.minecraft.world.item.ItemStack; | ||
|
||
public class BlockFilterSlot extends ItemFilterSlot { | ||
|
||
public BlockFilterSlot(Container container, int slotIndex, int posX, int posY) { | ||
super(itemStack -> itemStack.getItem() instanceof BlockItem, container, slotIndex, posX, posY); | ||
public BlockFilterSlot(Predicate<ItemStack> filter, Container container, | ||
int slotIndex, int posX, int posY) { | ||
super(filter, container, slotIndex, posX, posY); | ||
this.setPhantom(); | ||
this.setStackLimit(1); | ||
} | ||
|
||
public BlockFilterSlot(Container container, int slotIndex, int posX, int posY) { | ||
this(itemStack -> itemStack.getItem() instanceof BlockItem, container, slotIndex, posX, posY); | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
src/main/java/mods/railcraft/world/inventory/slot/BlockFilterSlotLinked.java
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package mods.railcraft.world.inventory.slot; | ||
|
||
import net.minecraft.world.Container; | ||
|
||
public class BlockFilterSlotLinked extends BlockFilterSlot { | ||
|
||
public BlockFilterSlotLinked(BlockFilterSlot slot, Container container, | ||
int slotIndex, int posX, int posY) { | ||
super(slot::mayPlace, container, slotIndex, posX, posY); | ||
} | ||
} |