You could probably fix it by changing all occurences of
Code:
xxx:SetTexture(1,1,1,1)
or
Code:
xxx:SetTexture(bg_r,bg_g,bg_b,f.bg_alpha or d.bg_alpha)
too
Code:
xxx:SetVertexColor(1,1,1,1)
or
Code:
xxx:SetVertexColor(bg_r,bg_g,bg_b,f.bg_alpha or d.bg_alpha)