Rail switch for minecart station
I've built a minecart station and have everything built but I can't seem to find a way to have a splitter so passenger carts go one way and storage carts go another way every time. I'm trying to create a system where pez dispensers have specific minecarts.
Solution 1:
I have built a small redstone contraption that will determine if a mincart has an item in it or not, and sort it accordingly. Here you can see an overview of the machine:
Now step-by-step I will show you each part of the machine, and explain what it does. Please note I will be using redstone terminology.
Segment 1:
This section's job is to determine if the minecart going over it has an item in it or not. When any minecart goes over a detector rail, it will activate any redstone connected to it. What this detector rail does is deactivates the redstone torch next to the top hopper so that said hopper can accept an item from the minecart (if the minecart contains an item.) After that, the item stays in the hopper for just enough time to activate Segment 2, then passes to the bottom chest, where (if you would like) you can collect it. If there is no item, the machine is ignored, and the minecart will follow the normal path. This will be where players go.
Segment 2:
Segment 2's Job is to change the rail position if Segment 1 detects items present. A comparator will read if an item is in a hopper or not, so if an item passes into the top hopper, the comparator will turn on, deactivating the redstone torch seen to the left, making the curved rail in Segment 3 change positions. If no item is detected, the curved rail will keep the same position.
Segment 3:
Segment 3's job is to decide which path the minecart will go down depending on the info decided in Segments 1 + 2. The way the rail starts as (When the redstone torch is on [The right in this case]) will be where players go, and the other rail [The left in this case] will be where minecarts with items go.
Notes for building:
- Although this was built on PC, all aspects remain the same in xbox-360 mode
- Everything to the right of the right detector rail (in the overview) can be changed accordingly, and you do not have to use stone, but you must use a block redstone can pass through, AKA any solid block (if you need clarification on that, ask.)
- Except for that ^, copy build EXACTLY including tick of redstone comparators.