I fiddled with 'evaluation' concepts, but it got completely out of hand:
If only I could remember my lessons in simplifying logic to it's simplest form. We used to start with hundreds of inputs and end up getting the logic we wanted off of 8 NAND gates. NAND gates are the best!
Anyway here is my entry + attached mega project:
Lock:
Treasure Vault (full of artifacts) with nice engraved gold vein leading up to it
Treasure level:
Z+1
Summary of machine:
- 8 Levers but could use any number
- Must be pulled in correct order to open door.
- Once you have chosen your order you step onto the bridge and pull the MASTER lever. At this point the vault will open and you will be admitted OR you get melted instantly by delicious hot magma.
- Fully re settable, with a delay set on how quickly you can try again (I guess only relevant for fortress mode)
- Vault does not stay open for long. Only long enough to allow entry.
- Exit switch is currently controlled by lever in queens room, but could easily be moved into the vault itself.
How it works:
Diagram 1 shows the logic gate for each lever. You need one of these per lever you want in your lock.A - Gear powering closed loop. This is what you connect to the lever
B - Gear powering reset circuit, This is connected to D from OTHER circuits
C - This roller pushes the minecart back into a closed loop when it gets power from B
D - This pressure plate controls what order the levers should be pulled in. Detailed explanation below
E - This pressure plate connects to one of the mechanisms at K (Diagram 3). You need one of these for each lever.
F (diag 1) - When powered by A this roller keeps minecart going in a circuit and constantly triggering E, this keeps the gear assembly in K permanently set to OFF.
Diagram 2 shows the master switch control.F (diag 2) - This gear is turned on/off by the master switch (marked P). In both cases it causes the minecart at H to move over G, either because it's rolling back off a ramp or because it's being pushed forward by rollers.
G - This Pressure switch toggles the bars at J (diagram 3) which will start the unlocking mechanism running
Diagram 3 shows my unlocking mechanism.I - This gear assembly is permanently on to power the rollers for this circuit
J - These are the bars preventing the minecart from continuously going round.
K - These are the gears being kept off by the pressure plates E. When all levers are correctly pulled they will be ON and the roller L will be active.
L - This roller sends the minecart down the correct path, toggling M
N - This pressure plate is triggered if not all the gear assemblies at K were ON. It is connected to the bridge circled in white, marked S. This will drop magma into the corridor between the treasure room and my fortress.
M - This pressure plate is connected to Q and opens the treasure vault... long enough to run inside!
Diagram 4 shows the particulars of the treasure vault.O - This is the entrance switch which you must pull to get into the gem window lined corridor leading to the treasure room. It simply toggles the bridge P. Pulling this during system reset can cause a very small amount of magma to wash over your dwarf body bringing a warming glow. (Only possible in fortress mode, this is impossible in adventure mode I think)
P - This is the master lever which toggles Gear assembly F (Diag 2). It will either result in a minecart passing over N or M (diag 3) and opening the vault... or dumping magma on your head. It ALSO raises the bridge behind you sealing you from escape (and preventing magma leakage). Because of Diag 2 pulling this repeatedly in short succession will NOT save you as the mechanisms are attached to pressure plate G not to the lever itself.
Q - This adamantine bridge lowers to allow entrance. It also atom smashes the magma left over from failed attempts (along with O)
R- The levers for pulling
S - Magma bridge.
Logic explanation:Basically I have 8 Diag 1 machines. I assign them an order 1,2,3,4,5,6,7,8.
Machine 1 has it's D pressure switch connected to gear B on ALL other machines.
Machine 2 has it's D pressure switch connected to gear B on ALL machines with a greater order number
etc, etc.
The end result is that you cannot ever open the vault without pulling the switches in the correct order, as pulling a lower number switch after a higher number one will turn off ALL switches of a higher number than itself. Ideally your logic should look like this in the end (for a four lock)
1111
0111
0011
0001
Possible improvements:The levers are setup so that you are expected to pull each one once. You can pull each as many as you want but you will quickly end up finding it VERY difficult to get the vault open, even in fortress mode. It also ends up a bit ugly looking if you have a mix of pulled and unpulled levers THEN reset the trap... I don't see any way round this with my setup. Once the trap is reset the state of the levers does not matter, lock will function as expected.
I also need to make two adjustments for adventure mode:
1) Minecarts all need a starting position and an initial, turn the machine on switch (would simply pulse B for each minecart)
2) Exit switch needs to be in treasure vault so you can leave again. (Hooked up to a copy of diagram 2 so it closes behind you)
Reset explanation:The trap resets after a failed attempt, or if you pull the reset switch in the mechanism room.
Resetting does the following actions:
- All minecarts are put back into closed loops through toggling of B gears
- Vault bridge and bridge O are lowered and raised to atom smash magma, leaving a single 7/7 pool in the middle. This spreads out nicely covering the corridor for a period of time and preventing anyone running through while the bridges are down (I don't actually know if you could go that fast, but I didn't want to leave it to chance).
FINALLY now I've finished my design I can look at everyone else's design and see how I size up against the competition =D