File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/main/java/com/sk89q/craftbook/mechanics/ic/gates/logic Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ public void trigger(ChipState chip) {
8080 int oldVal = curVal ;
8181 try {
8282 // If clock input triggered
83- if (chip .getInput (0 )) {
83+ if (chip .getInput (0 ) && chip . isTriggered ( 0 ) ) {
8484 if (curVal == 0 ) { // If we've gotten to 0, reset if infinite mode
8585 if (inf ) {
8686 curVal = resetVal ;
@@ -92,7 +92,7 @@ public void trigger(ChipState chip) {
9292 // Set output to high if we're at 0, otherwise low
9393 chip .setOutput (0 , curVal == 0 );
9494 // If reset input triggered, reset counter value
95- } else if (chip .getInput (1 )) {
95+ } else if (chip .getInput (1 ) && chip . isTriggered ( 1 ) ) {
9696 curVal = resetVal ;
9797 chip .setOutput (0 , false );
9898 }
You can’t perform that action at this time.
0 commit comments