Shell's (multipart) Redstone tutorial

Discussion in 'Player Guides, Tips and Tricks' started by ShelLuser, Jun 4, 2017.

  1. Hi gang!

    (brief) Introduction

    Redstone is the main thing which got me hooked on playing Minecraft. 3 years ago (beginning of March 2014) my girlfriend decided to show me Minecraft because she thought it could be fun playing together. At first I was a bit skeptic; I downloaded a demo version yet didn't understand what I was supposed to be doing. That was no fun ;)

    So I "complained" to my girlfriend who then put me into creative mode, showed me how I could get blocks out of the inventory and in specific pointed me to the redstone tab. My very first "build" was a lever which turned on a lamp. I didn't know what I was doing, but I did almost immediately recognize the sheer potential this stuff had. It wasn't much later when I build a NAND gate (after I discovered the redstone torch) and the rest is history as they say.

    Redstone tab in the Creative inventory

    About this guide

    I like writing guides from time to time, and I like redstone. So this guide was bound to happen. I've had this planned for quite a while already but ended up losing focus. I tried building an area which would "look good" on both the Empire as well as in single player Creative and always ended up unsatisfied.

    But the thing is: you're not reading this to look at some cool buildings (I hope ;)), the whole idea is to learn something about redstone! So enough with trying to make things look better than they are. No fancy looking builds, but straight to the point redstone examples. Examples which I'll put up for download as well later on.

    This guide will be a multi-part guide (helps me sort things out, and gives you something new to look out for), and this is the introduction & index post.

    What you're going to learn

    We're going to cover everything there is to know about redstone. We'll start very simple at a beginners level and we'll slowly, but steadily, work our way up to the more advanced stuff. But one (small) step at a time.

    This guide will cover these major topics (and a whole lot more):
    • What is redstone exactly and what does it do?
    • The Minecraft laws of physics (or would that be redstone?) ;)
      • block updates, pulses, insulators, charged blocks....
    • Redstone limitations (and how to overcome them).
    • Redstone blocks explained such as the repeater, comparator and observer.
    • Redstone towers; why you'd want to make one, and how to do it.
    • Why redstoners love wool so much.
    I hope that by reading this guide you'll gain a bit more understanding about redstone, and that the whole thing won't be as mysterious (or difficult) anymore for some of you.

    What I'm using to make this guide

    If you want to tag along and do the things I do yourself while also making sure things look and behave the same then this is what you'll need:

    Minecraft 1.12

    This is not a major requirement but it is what I'll be using for this guide. The main reasons I chose this version is so that I can easily show you crafting recipes when needed, the ability to quickly switch my hotbars is a very useful one (I'm literally building the shown examples while writing this guide) and when Aya isn't around to help me I can call in the help of Polly Parrot :D

    Lithos:Core

    If you notice that my screenshots look different than vanilla you'd be right: I've been using the Lithos:Core resource pack for months now and I never felt like stopping. To me Lithos is like playing with a better looking vanilla Minecraft, and I really like that. I'm especially impressed with the redstone parts. If interested you can grab the latest version here (CurseForge). It even has a version which supports 1.12 already :cool:

    A custom flat world

    The best way to work on this is to build a (flat) creative world. This allows you to fully focus on the redstone. Of course there's nothing stopping you from using a regular world, that can also be plenty of fun! But when working on redstone I prefer flat & boring ;)

    Here's how to set it up:
    • Click "Create new world" and set the mode to creative, then click on "More world options...".
    • Make sure that cheats are enabled (should be on by default, creative mode triggered this).
    • Select 'Superflat' as the world type, then click "Customize".
      • Now click on the "Presets" button and select 'Redstone ready', then click "Use Preset".
      • You should now see 3 layers: bedrock (bottom), stone (3) and sandstone (top).
      • Click "Done".
    • This is optional, but I suggest to turn off structure generation. Suddenly seeing a village turn up can become a bit annoying. So: click on "Generate Structures" to turn it to off.
    • Set a good name, then click "Create New World".
    Some tips to make your life easier:

    Hostile mobs can spawn when its dark. Although they won't attack you in creative it can still become annoying. Consider turning them off with: /difficulty 0 (peaceful).

    Building while it's dark can be bothersome. You can stop time by using: /gamerule doDaylightCycle false. Keep in mind that tab completion is a thing, so after you typed '/game' (without the quotes) try pressing the tab key (probably need to press it twice). Then when you typed 'doday' try pressing tab again. You also don't type 'false', you simply type 'f' followed by, you guessed it, tab.

    You'll start on a random coordinate and because everything looks the same it might get difficult to find your main location again if you wander off too far. 2 things can help. First the most obvious: teleport to 0, 0 and start building there (use /tp 0 ~ 0).

    Second: /spawnpoint. This will set your spawnpoint to the location you're in. Meaning that if you die then you'll end up on that location again. Dying is easy, just use: /kill. This may create a new problem: you'd lose all your items. Easily fixed by using this command first: /gamerule keepInventory true.

    Now... onto the guide!
    MAIN INDEX
    (will be updated with every new chapter)
  2. Part I - Introduction

    What is redstone?

    When people talk about redstone they often refer to the whole collection of blocks involved or the mechanism being used; comments about people who "do redstone" for example. However, redstone is basically a material which you can find below the ground, it can be mined with an iron (or better) pickaxe and it can do some pretty interesting things... Basically you can consider 'redstone' to be Minecrafts counterpart of the electricity which we have in real life.

    Redstone ore blocks, notice the particles?

    When you walk over a redstone ore block you'll immediately notice that it behaves a lot different than any other ores. It'll emit some light and you'll even see particles coming out. That's definitely not your standard ore block behavior.

    Just like coal and lapis you can mine redstone ore blocks and that will drop the main component itself; redstone, up to 5 pieces (more when your pickaxe has the Fortune enchantment). Because the name 'redstone' is often used to describe the whole collection of blocks (or the mechanics involved) many redstone builders refer to the main redstone block as redstone dust. Partly because of the above, but also because it actually somewhat behaves this way: you can place it down on the ground and pick it up again (break it) even without using any tools.


    When placed on the ground redstone dust will show as a small round(ish) speck (seen on the left). If you place more dust right next to it then both parts will automatically connect to each other, as shown on the right. This ability allows us to make so called redstone circuits; where the redstone dust is used to connect the individual redstone components together.

    The 3 parts of a redstone circuit

    So what about a redstone circuit? A redstone circuit always consist of these three parts:
    • A redstone power source.
    • A redstone conduit (or "transporter").
    • A redstone receiver.
    A door with a button (or pressure plate) is actually a small redstone circuit...

    When you work with redstone you're actually using a virtual power which can be used to make certain blocks 'do' something. But no matter what you build you'll always be using these three main components.

    When you look at the picture above then the button is the power source. As soon as you press it the button will generate a redstone signal. The sandstone block to which the button is attached acts as a so called conduit; it receives the signal from the button and then passes that onto other blocks around it, but only as long as those blocks are actually capable to pick up such a signal.

    Which is where the door comes into play; this is a so called redstone receiver. It can pick up a redstone signal, and when it does it'll act on it. In this case the door will open when it receives a redstone signal, and closes again when the signal disappears (or stops).

    Redstone power sources


    Here is an overview of the redstone power sources currently available in the game. Each of these blocks will generate a redstone signal, either when activated or all the time. Pressure plates turn on when stepped upon and will almost immediately turn off when you step off. A button generates a signal for a little longer when compared to a pressure plate. The redstone torch and redstone block always generate a redstone signal, and a lever is a toggleable source: you can turn that on or off.

    And in case you don't recognize it: attached to the sandstone block is a so called tripwire hook. When you place 2 of those opposed to each other you can then connect them with string; the very moment someone (or something; like a mob) touches that string then the tripwire hook will generate a signal.

    Redstone receivers


    Receivers are blocks which 'do' something when they receive a redstone signal, you probably already recognize some examples. Doors and fence gates will open and close, as well as the trapdoors. A dropper and dispenser (the gray blocks) will "spit out" any item they contain where a dropper simply drops a block and a dispenser often uses a block. Example: a dropper would simply 'spit out' a water bucket so that you can pick that up while a dispenser would use the bucket to place a water source block (but more about that in a later part!). And finally a light will turn on and a piston will extend.

    Now there's one block here which might seem out of place: the redstone torch. I also showed that in the previous category, making it both a power source as well as a receiver. That's because a redstone torch will react to a redstone signal by turning itself off. This may seem a bit useless to you now but trust me when I say that this ability is invaluable when making more complex redstone circuits.

    Our first redstone circuit!


    Here I placed a daylight sensor on the ground, placed 15 redstone dust and every 5 blocks I put a redstone lamp into the ground, the result can be seen above. A daylight sensor generates redstone power when it receives daylight. The more light it gets (basically: the higher the sun sits in the sky) the more power it'll generate, up to 15 in total.

    When time progresses and the sun is almost setting you'll see how the signal also starts to wane:

    A beautiful setting sun, and none of the lights are lit anymore

    Of course this also makes this circuit a little bit useless: when it's day then the lights are on, and during the night everything is off. What genius came up with that idea, eh? ;) Fortunately the sensor has 2 modes: day and night. If you right click on it then it'll switch to night. Now it'll only generate redstone power when the sun has set and the moon is up in the sky.

    A redstone signal: no less than 0, and no more than 15

    When working with redstone then there are a few "laws of physics" which you need to know about, and this is the first one: a redstone signal can have a strength up to 15 maximum, no more. No matter what you're working with: you'll never get a higher signal strength than 15.

    So how can we visualize a signals strength? Well, I already showed you guys an example above with the daylight sensor: the higher the sun sat in the sky, the more power was generated. Or, in other words: the stronger the redstone signal became. When the signal was stronger more lamps were lit, and when the signal got very weak (up to 3 or 4) then none of the lamps were powered anymore.

    Unfortunately there isn't a "why" here, no reason which explains this behavior. Just remember: 15 is the maximum strength of any redstone signal.


    Here you can see that the lever on the left side is generating a redstone signal: the lamp is on and you can also see a bright red color on the redstone dust; this indicates that the dust is currently powered. However... the redstone lamp on the right didn't turn on, as you can see the signal never reaches it.

    That's because of the 15 signal strength limit: the maximum signal strength is 15, but my circuit consists of 18 redstone dust. So my signal can never reach the lamp like this because of the 15 limit.

    Fortunately there are ways to solve that problem, but I'm going to explain more about that in the next part.

    Summing up part I
    • Redstone is block which can be found as an ore block below ground and mined with an iron pickaxe or better.
    • You can recognize a redstone ore block by its red specks and its behavior: it'll emit light and particles if you step on it (or hit it).
    • Redstone (the block) is also often referred to as redstone dust, because it looks a bit that way.
    • When placed on the ground redstone dust will automatically connect to other redstone dust blocks.
    • You can use redstone dust to connect redstone components together, so basically creating a redstone circuit.
    • A redstone circuit always consists of 3 parts:
      • A redstone power source.
      • A redstone conduit (or 'transporter').
      • A redstone receiver.
    • A redstone signal can vary in strength, but it can never be stronger than 15.
    Finally....

    If you got any questions about this part then don't hesitate to ask!

    Now is your chance to learn more about redstone :)

    However, one rule: don't ask about things which haven't been explained yet, I don't want to make things too complicated. So if I haven't talked about what you wanted to know then you'll have to be a little more patient until I do.
  3. So let's continue ;)

    Part IIa - Basic redstone components

    In the previous part I showed how a redstone circuit consists of three major components: a power source, a conduit (or 'transporter') and a receiver. We also learned that the maximum value of a redstone signal is 15. Which can create a bit of a problem when your signal needs to cross an area which is longer than 15 blocks because a redstone signal decays (gets weaker) the further it needs to travel out.

    Another issue is that a signal by itself doesn't really 'do' much. Things would be pretty boring if all we could do is turn things on or off. That's why we also have access to some redstone control blocks. Do note: this is not the official description, this is how I tend to call them. There are three control blocks in total:
    • Redstone repeater
      • A repeater 'repeats'. It can take a redstone signal and boost it back to full strength (15). However, a repeater can also delay a signal and even retain a redstone state.
    • Redstone comparator
      • A comparator does as its name implies: it can compare two (or three) incoming redstone signals. In its secondary mode the comparator becomes a subtracter, somewhat doing the opposite of a repeater: it can actually make a redstone signal weaker.
    • Redstone observer
      • This is a bit of a strange one: the observer 'observes' the space in front of it and when something changes then it will send out a short (full strength) redstone pulse. It may seem a bit useless at first, but later on in this tutorial you'll soon discover that this block can be pretty much invaluable at times.
    This may sound simple enough, but there's quite a bit to explain about each control block.

    Redstone repeater


    You can make a redstone repeater using 3 (plain) stone blocks at the bottom of a crafting grid, then placing 2 redstone torches on each side in the middle with a redstone (dust) in the center. The interesting part is that this means that you can make repeaters almost as soon as you discovered redstone. Which is fitting because they're very versatile.

    By default a repeater boosts a signal back to 15. In the last example of the previous chapter I showed you how the signal from the second lever couldn't reach the lamp at the end because the amount of redstone dust was longer than 15 blocks. Well, that problem can be easily solved by adding a repeater:

    The signal strength is back to 15 after the repeater.

    So if you need to transport a redstone signal to an area outside the 15 block range then all you need is a repeat(er).

    Signal delay

    When you use a redstone repeater it doesn't only boost the signal, but it also delays it a little bit. By default a repeater delays a signal for 1 so called redstone tick. I'll explain more about ticks and timing in a later part, but for now just remember that one redstone tick is approximately 0,1 seconds (1/10th of a second). On top of that you can increase the delay by right clicking. One tick per click, up to a maximum delay of 4 ticks (so 4/10th of a second).


    Here I have a very simple circuit: you press the button, the button stays on for approx. 2 seconds and therefor the lamp stays on for that same time. As soon as the button turns off then the lamp will also go out.

    But you can change that if you want:


    Here I added a repeater and set it to a 4 tick delay (right clicked on it three times). Now you'll see something slightly different: as soon as I click the button the lamp turns on, but the repeater delays the second signal. So first the lamp is turned on by the left redstone dust, and a slight moment later it gets a second signal from the repeater (the right line of redstone dust).

    Then we see something quite interesting happening: when the button turns off the repeater stays on for a little moment. That's because of the delay: it doesn't only delay the moment a signal turns on, it does the exact same thing when a signal turns off.

    And that results in what you see above: the button has already turned off but the repeater is still on and therefor also the lamp.

    Not for long though, this only lasts for 4 redstone ticks (4/10th of a second). Of course you can easily delay this even further if you want, just add a second repeater.

    Sure, keeping a lamp turned on for a little longer may seem a bit useless, but have you ever had issues with getting through an iron door? This used to be a popular joke with PopularMMO's during their infamous 'Crafting Dead' series (one which I actually enjoyed but which unfortunately stopped, it got replaced by other sillyness which I don't like ;)).

    Easily fixed:

    Not the best door designs, but we'll fix that in a later part :)

    Here you can see that the button has long turned off (also shown by the lamp) but the door is still fully open. That's because we delayed the signal for a whole 8 ticks (almost 1 second), giving you approx. 3 seconds to get through. Of course now you'll have to walk through some redstone dust, but that's a small price to pay, right? No? Looks horrible? You're right of course ;)

    This is simply an example to show you how it works. We'll get into hiding redstone components and how to move signals around in a later part of this tutorial.

    State locking

    And then we come to the third function of the repeater, one which even some redstone diehards totally forget about. As shown above a repeater can delay a signal. But as shown with the door and the lamp it doesn't only delay the moment a lamp turns on, it also delays the moment when it turns off again. You can easily test this for yourself by placing a repeater between a button and a redstone lamp and then setting it to a 4 tick delay. The lamp will turn on a little bit later than the moment the button turns on, but it will also turn off a little bit later as well.

    What this means is that a repeater doesn't only delay a redstone signal. It actually delays the state of the signal. In other words: the moment when the signal turns on or turns off again.

    And it can do even more than that:


    Quiz time: The lever is turned off, and so the lamp is also off. What would happens if I turn the lever on?

    You may have guessed it already: if I turn the lever off then the lamp will stay off:


    So how did that happen?

    As you may notice the repeater in the foreground looks different. Instead of a pin we now get to see a bedrock bar. That is an indicator to show us that this repeater has been "state locked". In other words: it won't change its current output (state) for a long as it is locked. In my example the current state is off; you can send whatever signal you want into this repeater but it won't turn on again.

    But this just as easily works the other way around as well; when you lock a repeater while it is turned on then it will no longer automatically turn off anymore:

    Here I locked the repeater after I had turned on the switch.

    As with the observer this may seem very trivial at first, but trust me: once you learned how to apply this technique it can become invaluable in your redstone circuits.

    Remember that delay I made in the beginning where the lamp would stay on just a little longer than a button? I basically used a parallel signal, so: I added a second signal and sent that to the lamp as well. But what if you can't? What if there's only room for 1 signal?

    Well...


    In survival mode it would become quite tedious if I had to remove all that obsidian. So I designed something else: instead of sending a delayed second signal to the lamp(s) so they remain on I now made the circuit retain the current signal for a little longer by state locking the main repeater. Instead of keeping the lamp on I now lock the repeater for a little while. And because the repeater is still on while I lock it, it will remain on until the lock gets released.

    Redstone comparator


    A comparator is clearly more advanced than a repeater, in order to craft a comparator you'll be needing nether quartz. As with the repeater you place three (plain) stone blocks at the bottom, a nether quartz in the middle and then surround the quartz with three redstone torches.

    As its name implies a comparator compares signals. And it's pretty trivial too: a comparator blocks an incoming signal but only when the signal on either of its side input(s) is higher in strength than the main signal:


    The main signal (the redstone torch on the right) has a strength of 14. That's because I used 2 redstone dust, and as we saw in the previous part a redstone signal decays (gets weaker) with every block it needs to pass.

    The signal in the side-input (the background) has a strength of 15. Put simple: the torch in the background is placed closer to the comparator than the torch on the right. As a result the comparator remains off. Because 15 is higher than 14.

    End of part IIa
  4. Part IIb (I did it again ;))

    Subtraction

    When you right click on a comparator you'll turn on the pin at its front, and that indicates that it is now in subtraction mode. Now it will subtract the signal on its side input(s) from the main signal.

    15 - 11 = ?

    So what is happening here?

    I placed a redstone torch in the background (right side), and that generates a signal strength of 15. I added a comparator, but because there are no side-inputs being used the full signal is being sent out. With every placed redstone dust the signal strength decays, up to 15 blocks total. So right behind the comparator the signal strength is 15, then becomes 14, 13, 12 and so on.

    Basically the signal has a strength of 11 at the first lamp, then 11 - 5 = 6 with the second lamp and then finally 6 -5 = 1 at the last, this is also where the signal stops.

    In the middle I placed a comparator in subtraction mode, placed a torch behind it (signal strength is 15) and then added the first signal to the side input. The sign says a strength of 12, but because we used an extra redstone dust to connect the comparator it became weaker with 1. So the strength of the side input of the comparator in the middle is 11.

    And you can see the result for yourself. Main input is 15, side input is 11. 15 - 11 = 4.


    Here's another example. The main input is 14. The dust right next to the torch has a strength of 15, then it travels one block out so decays to 14. Then it travels to the side, now its 13. Goes one block to the left so it can connect to the comparators side-input and now it has decayed to 12.

    14 - 12 = ? ;)

    Observer


    Now, this block will probably seem very strange at first, maybe even useless. But its purpose will become much more obvious in later parts of the tutorial when I'll explain more about redstone states. You can craft an observer using two layers of cobblestone on the top and bottom rows of a crafting grid. Then place one redstone dust in the middle, and another next to it. Finally you need to place a nether quartz on the other side in the middle.

    As its name implies an observer block observes what is happening directly in front of it.


    Here I placed a redstone dust in front of the observer. The dust is not powered and doesn't do anything special. But the observer noticed the change in front of it (placing of the redstone dust 'block') and as a result it sent out a quick signal with a strength of 15. You can see this in the background: the lamps besides the redstone dust are lit.

    What it basically does is generate a so called redstone pulse: the signal turns on, and then quickly turns off again. But the pulse is very quick:


    Remember the redstone torch? When it receives a redstone signal then it actually turns off. However... here you can see that the redstone lamp is on, but so is the redstone torch. Even though you can clearly see the redstone signal.

    That has everything to do with timing. Those 'redstone ticks' I mentioned earlier.

    BUT... we'll save that for the next part.

    Summing up part II
    • There are three redstone 'control blocks': the redstone repeater, comparator and the observer.
    • A repeater boosts a signals strength back to 15.
      • It can also delay a signal up to 4 ticks (4/10th of a second), with each right click on the repeater you raise the delay (2 ticks, 3 ticks and the maximum of 4 ticks).
      • And it can also lock a signal by using another repeater in the side-input.
    • A comparator compares signals; by default it will only pass an incoming signal as long as the side-input(s) don't have a higher signal strength.
      • By right clicking you set the comparator into subtraction mode: now it will subtract the side-input signal from that of the main signal.
    • An observer 'observes' whats happening in front of it, and as soon as something changes (like the placing of a block) it will send out a quick redstone pulse with a strength of 15.
    Finally....

    If you got any questions about this part then don't hesitate to ask!

    Now is your chance to learn more about redstone :)

    However, one rule: don't ask about things which haven't been explained yet, I don't want to make things too complicated. So if I haven't talked about what you wanted to know then you'll have to be a little more patient until I do.