forked from LeenkxTeam/LNXSDK
Update Files
This commit is contained in:
20
leenkx/Sources/leenkx/logicnode/InverseNode.hx
Normal file
20
leenkx/Sources/leenkx/logicnode/InverseNode.hx
Normal file
@ -0,0 +1,20 @@
|
||||
package leenkx.logicnode;
|
||||
|
||||
class InverseNode extends LogicNode {
|
||||
|
||||
var c = false;
|
||||
|
||||
public function new(tree: LogicTree) {
|
||||
super(tree);
|
||||
tree.notifyOnUpdate(update);
|
||||
}
|
||||
|
||||
override function run(from: Int) {
|
||||
c = true;
|
||||
}
|
||||
|
||||
function update() {
|
||||
if (!c) runOutput(0);
|
||||
c = false;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user