- v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
- Use this page to report any issues related to the migration.
User:Bidok
Animal Logic
This logic is based on NOT gate and uses kittens or any other animal that can trigger pressure plates. I do not suggest using female animals (breeding) or dwarfs (they can starve to death).
Pros:
- quite fast
- reliable (at least I do think so ^^)
- you dont need water or enegry to make it
- all you need is small tamed animal
Cons:
- well, it's working thanks to bug in pets pathfinder - they will still want to go thru pet-inpassable doors - So when (and if) pathfinder code will be patched it might stop working at all
- it will need more and more kittens to build larger systems, but well.. most of the time all you really need is NOT or maybe alternator ^^
What can I get with this?
The simplest answer - what you want. With this for example you could build system which will automaticaly turn on repeating spike traps in your entrance 10 seconds after some goblin will stomp on pressure plate. You could build control room with 4 levers connected to AND gates and when all levers will be On - boom! You fortress is flooded with magma or something.. You could have one lever - after pulling it will open 10 doors and shut 10 other doors.. It all depends on what you really need.
Legend
# - wall ^ - pressure plate set to trigger on kittens (output) X - wall grate, door or something like that (input) D - simple door: passable but NOT for pets . - channel, pit zone
NOT gate
top level
##### #. #####
In most (if not in all) cases top level looks like this. If not mentioned otherwise you should make top level like this.
bottom level
Result = true (input A = false) ##### #^XD #####
Result = false (input A = true) ##### #^ D #####
Kittens needed: 1
How does it work?
When you trigger lever connected to X it will disappear allowing pet to move to the next tile. Pet will walk off from pressure plate turning it off. Why I'm so sure that this will work this way? It's becouse pathfinder - pets will still try to get out from the room thru pet-inpassable doors. On another hand - if you trun lever Off - X will appear on the same tile where kitten is standing. Game will force this small animal to move on the closest free tile - which is the one with pressure plate. You got the idea.
NOR gate
Nor will result true only when two arguments are NOT met (lever A and lever B are set to Off state)
bottom level
Result = true (inputs: A=false, B=false) ##### #^XD ##X# #####
Result = false (inputs: A=true, B=false OR A=false, B=true OR A=true, B=true) ##### ##### ##### #^ D #^XD #^ D ##X# or ## # or ## # ##### ##### #####
Kittens needed: 1
OR gate
OR = NOT NOR
So all you need to do is to build NOR gate and connect pressue plate to X in NOT gate - then pressure plate in NOT gate will have OR output. Complicated? Nah..
Kittens needed: 1+1 = 2
AND gate
AND = (NOT A) NOR (NOT B)
This time all you need to do is to negate input A and input B.
Kittens needed: 1+1+1 = 3
NAND gate
NAND = NOT AND
Build NAND gate and negate output.
Kittens needed: 1+1+1+1 = 4
XOR gate
XOR = NOT ( ((A NOR B) NOR A) NOR ((A NOR B) NOR B) ) (not tested but it should work this way)
what you need:
- one "A NOR B" gate (lets name it nor_1)
- one "nor_1 NOR A" gate (nor_2)
- one "nor_1 NOR B" gate (nor_3)
- one "nor_2 NOR nor_3" gate (nor_4)
- one "not nor_4" gate (final result)
Kittens needed: 1+1+1+1+1 = 5 (yeah, I know, a lot for one gate..)
another way (probably better):
XOR = (A NOR B) NOR ((NOT A) NOR (NOT B))
you need:
- one "A NOR B" gate (nor_1)
- one "NOT A" gate (not_a)
- one "NOT B" gate (not_b)
- one "not_a NOR not_b" gate (nor_2)
- one "nor_1 NOR nor_2" gate (final result)
Kittens needed: 1+1+1+1+1 = 5
Memory
bottom level
###### #> HD ######
bottom level-1
###### #<X^## ######
H - hatch cover linked to PP/Lever - this is SET bit <, > - up and down stairs X - door/wall grate linked to PP/Lever - this is CLEAR bit ^ - pressure plate - output
Kittens needed: 1
Repeater
aka Alternator - can be found on bay12games.com forum [1]
Counter
Should work, not tested yet.
Counter will activate something only after it hit certain integer value (say, for example - you'll need to turn off and on some lever ten times to flood your entire fortress with magma). When connected to repeater this could work as a delay machine or clock or whatever. Integer value depends on how many z-levels you will make (of course with little modifications you could connect infinite counters ^^)
Kittens needed: 1
level 0
####### #>D HD ####### > - down stairs D - doors, left one = pet passable, right one = pet-inpassable H - hatch cover over channel - all hatch covers on all levels are connected to the same source/incramentator If you're planning to connect this counter to another one - simply make the left doors forbidden, remove wall tile near stairs and connect it to another counter-shaft ^^
level 0-n
######## #SDH XS# ######## S - up/down stairs D - doors, pet-inpassable H - hatch cover linked to incrementator X - door/wall grate/etc - all X's are connected to RESET
level 0-n-1
######## #SX HDS# ######## legend same as above
bottom level+1
######## #SX ^DS# ######## or ######## #SD^ XS# ######## depends on level above this one ^ - output pressure plate
bottom level
######## #< <# ######## < - up stairs