This is what happens when you're studying electronics and you get bored.
Note to readers. If you are unsure what a logic gate OR "The Incredible Machine 3" is, you're going to become very confused. If you aren't already.
So, everyone remember TIM, right? The game where you build Rube Goldberg-type machines out of different components... Well, it all started when I wanted to make a machine that would work in a loop and always end up at the same state. I decided it would be nice to have something to count the number of loops, so I started thinking up ways to count. There are many different ways to do it, but I wanted to see if I could make a binary counter. But how? Levers and ropes might work, but would be ungainly and the game seems to dislike having more than a couple of them attached together. I eventually hit on the idea of using lasers (the red ones, specifically), mirrors, and laser switches. AAANYWAYS, before I go on all night, let's just say that I didn't manage to build a counter (it would have been very hard, not only due to the number of parts needed, but because of the limitations imposed by the game). However, I did put together a few logic components that I will share with you now.
We'll start off with the easy ones: an AND gate has to be on only when both input lasers are on. So one of the input lasers is switched to green, and then both are put through a laser collimator - only if the output of that is yellow will the output switch be turned on:
An OR gate is made even easier by the laser collimator:
Out of the three basic logic gates, NOT is actually the most difficult to build. It is similar to the design of an AND gate, except that the second input laser is always green, and the switch after the collimator is green. This means that when a red laser is fired into it, it shuts off the switch:
An XOR gate came next, for use in an adder (any reasonable sized adder would have far too many components for the game to run, unfortunately). This one's a bit more complicated, so I'll let you figure out how it works:
And then an attempt at a feedback loop: a simply S-R latch (flip-flop). Unfortunately, TIM3 wasn't meant for logic design, and does not take kindly to feedback loops. However, in theory this would be fully functional:
Of course, to make any sort of feedback circuit useful, you need a clock. And since i was not about to use the old three-inverter method (lest the computer explode), I opted for something a bit more... simple. This is what I came up with - it's about the slowest clock speed I could manage without making something more complex. There is a noticeable gate delay in all of these, so slow is the way to go. Even then, it won't run the flip-flop properly. Either it's still too fast, or the flip-flop just doesn't work due to game limitations. Anyways, here is the humble clock:
So there you have it. The Incredible Machine 3 is Turing-complete. If it didn't crash for having too many things on the screen, you could build anything you wanted from these logic gates. Feel free to comment on how much of a nerd I am.