if part.Transparency <= .45 then --Code stuff end
Is the part a model? Because models don't have transparency. Try referencing the variable as a a Part.
You are changing the transparency of a model not, a part which isn't possible. Create a variable for the parts inside the model and then change their properties.
local parts = script.Parent:GetChildren() -- Get's the children inside the model if parts.Transparency <= .45 then --Code stuff end
I realized I had my code in an area where part was in fact a model so I moved it to the correct position in my code and that fixed the problem.