From c4ffac2251c3b283f2ab1ce6fc552c42fdd78c47 Mon Sep 17 00:00:00 2001 From: Nathan Wagner Date: Mon, 5 Feb 2024 19:44:16 +0000 Subject: [PATCH] stoppping mario once message comes in --- animation.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/animation.go b/animation.go index 967a057..05b1036 100644 --- a/animation.go +++ b/animation.go @@ -91,7 +91,9 @@ func appendImage(img string, a *Animation) { func (a *Animation) Next() (image.Image, <-chan time.Time, error) { var incoming incomingMessage - a.animateMario() + if a.countDown != 5000 { + a.animateMario() + } if a.images["doorbell"] != nil { if a.countDown > 0 { a.ctx.DrawImageAnchored(a.images["doorbell"], 0, 0, 0, 0)