From 4e9d78c86ad71cded5800c9c1822353b4ad70c2b Mon Sep 17 00:00:00 2001 From: Ollo Date: Fri, 15 Jan 2021 19:06:49 +0100 Subject: [PATCH] Dim background to same level as foreground --- mqtt.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mqtt.lua b/mqtt.lua index 2504766..8b6ce5c 100644 --- a/mqtt.lua +++ b/mqtt.lua @@ -17,7 +17,7 @@ function handleSingleCommand(client, topic, data) else red, green, blue = string.match(data, "(%d+),(%d+),(%d+)") end - colorBg=string.char(green, red, blue) + colorBg=string.char(green* briPercent / 100, red * briPercent / 100, blue * briPercent / 100) print("Updated BG: " .. tostring(red) .. "," .. tostring(green) .. "," .. tostring(blue) ) if (displayTime~= nil) then displayTime()