Icon | ![]() |
---|---|
Name of gadget | NOT gate |
Section | Logic & Processing |
Number of Tweak pages | 1 |
Author | LadylexUK, QuietlyWrong |
Last Updated | 22 Feb 2019 [Beta] |
Description
This simple gadget analyses a signal and produces a true signal if the input is false and a false signal if the input is true. For example if you connected a “counter full” output on a counter to the input of this gadget, the NOT gate would output a signal of 0 if the counter was full and a 1 if the counter was not full (which is the inversion of what the counter full signal would be), therefore you can use this gadget to invert the signal of another gadget.
A typical use is to combine a NOT gate with a controller sensor button to detect when the player ISN’T pressing a button, for example to play a sound effect every time the player lets go of something they’ve been dragging around with their imp. (Just make sure the sound effect doesn’t play at the very beginning of the scene before controller gets used! You could activate your special sound effect logic microchip the very first time the button gets pressed, for example.)
Example Tutorial (adapted from Media Molecule)
- Place a cube
- Tweak its properties to make it grabbable
- Snap a grab sensor to it
- Place a light
- Wire the grabbed output on the grab sensor to the power point of the light.
- Go to test mode.
- The light is off. Grab the cube and the light will go on.
- Go back to edit mode
- Remove the wire from the grab sensor.
- Place a NOT gate
- Wire the grabbed output on the grab sensor to the input of the NOT gate.
- Connect the output of the NOT gate to the power port of the light
- Go to test mode
- The light will be on. Grab the cube and the light will go off. By putting the NOT gate between the grab and the light we have inverted what would normally happen.
Tweak Menus
![]() |
|
- NOT Input
Wire a gadget output that you want to invert or check if it is true or false to the input socket.
The output will be 0 if the input is true, and 1 if the input is false. - Power
This is where you can turn the gadget on/off
QuietlyWrong Tips
There really isn’t much more to say about this essential piece of logic. However if you’re looking to invert a signal that is more complicated than simple “trues” and “falses” in succession, or if you want the inversion to happen gradually, you should look at the much more versatile signal manipulator gadget.
Comments and Feedback