reset idle timeout when serial data causes a light to be pressed

This commit is contained in:
admin 2022-01-04 20:38:47 -05:00
parent bc3894c2d4
commit f8064c4d0b
2 changed files with 4 additions and 0 deletions

3
NS.py
View File

@ -151,6 +151,9 @@ class NS(Game, Animation):
def apply_serial(self):
for ii, light in enumerate(self.platform.lights):
light.pressed = bool(self.serial_data & (2 ** ii))
# reset idle timer is a light is detected as pressed in serial data
if light.pressed:
self.idle_elapsed = 0
def reset(self, leave_wipe_running=False):
self.score_hidden = False

View File

@ -19,3 +19,4 @@
237842
171298
198296
152352