Is it possible to "reverse" a part transparency value?

I’m working on an audio visualizer, so far everything is working. Though whenever the loudness goes high the part transparency gets more transparent, is it possible to achieve the opposite effect? This is my code;

local sound = workspace.Sound
local part = workspace.Part
local light = part.SurfaceLight

while true do
	game["Run Service"].RenderStepped:Wait()
	light.Brightness = sound.PlaybackLoudness / 100 * 2
	part.Transparency = sound.PlaybackLoudness / 1000
	print(sound.PlaybackLoudness / 100)
end

Thanks.

4 Likes
-- Starts from 1, and goes towards 0
part.Transparency = 1 - (sound.PlaybackLoudness / 1000)
9 Likes