So I'm trying to use the new PlaybackLoudness feature on a game. The problem is, is the transparency of the part ("Light") is changing to 0.1. It only seems to change to whatever I set it to using ((Sound/1000) + 0.1) and I'm not sure how to do this. I'm very unfamiliar with this and can't figure it out. Can someone help? Thanks!
Script:
local Sound = game.Workspace.Music.PlaybackLoudness
local Part = script.Parent
local x = ((Sound/1000) + 0.1)
while true do
wait(0.001)
Part.Transparency = x
end

1 comment
You always set it to the same value. You should put --------x = (Sound/1000) + 0.1------------ inside the while loop, also, you'll have to use localscripts. -> video showing https://www.youtube.com/watch?v=-kqaPjNt1e8