Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

TextLabel fade help? [Script Included]

Asked by
Vividex 162
10 years ago

I made an equalizer, this is the script I used to make the TextLabels/bars move up and down:

sp = script.Parent
NUM1 = sp.NUM1
NUM2 = sp.NUM2
NUM3 = sp.NUM3
NUM4 = sp.NUM4
NUM5 = sp.NUM5
NUM6 = sp.NUM6
NUM7 = sp.NUM7
while true do
    NUM1:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM2:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM3:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM4:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM5:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM6:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    NUM7:TweenSize(UDim2.new(0, 100,0,math.random(-400,0)),"Out","Linear",0.1,false)
    wait(0.05)
end

This is what I have to fade the bars:

sp = script.Parent
NUM1 = sp.NUM1
NUM2 = sp.NUM2
NUM3 = sp.NUM3
NUM4 = sp.NUM4
NUM5 = sp.NUM5
NUM6 = sp.NUM6
NUM7 = sp.NUM7
while true do
    NUM1.BackgroundTransparency = 0
    NUM2.BackgroundTransparency = 0
    NUM3.BackgroundTransparency = 0
    NUM4.BackgroundTransparency = 0
    NUM5.BackgroundTransparency = 0
    NUM6.BackgroundTransparency = 0
    NUM7.BackgroundTransparency = 0
    NUM1.BackgroundTransparency = .1
    NUM2.BackgroundTransparency = .1
    NUM3.BackgroundTransparency = .1
    NUM4.BackgroundTransparency = .1
    NUM5.BackgroundTransparency = .1
    NUM6.BackgroundTransparency = .1
    NUM7.BackgroundTransparency = .1
    NUM1.BackgroundTransparency = .2
    NUM2.BackgroundTransparency = .2
    NUM3.BackgroundTransparency = .2
    NUM4.BackgroundTransparency = .2
    NUM5.BackgroundTransparency = .2
    NUM6.BackgroundTransparency = .2
    NUM7.BackgroundTransparency = .2
    NUM1.BackgroundTransparency = .3
    NUM2.BackgroundTransparency = .3
    NUM3.BackgroundTransparency = .3
    NUM4.BackgroundTransparency = .3
    NUM5.BackgroundTransparency = .3
    NUM6.BackgroundTransparency = .3
    NUM7.BackgroundTransparency = .3
    NUM1.BackgroundTransparency = .4
    NUM2.BackgroundTransparency = .4
    NUM3.BackgroundTransparency = .4
    NUM4.BackgroundTransparency = .4
    NUM5.BackgroundTransparency = .4
    NUM6.BackgroundTransparency = .4
    NUM7.BackgroundTransparency = .4
    NUM1.BackgroundTransparency = .5
    NUM2.BackgroundTransparency = .5
    NUM3.BackgroundTransparency = .5
    NUM4.BackgroundTransparency = .5
    NUM5.BackgroundTransparency = .5
    NUM6.BackgroundTransparency = .5
    NUM7.BackgroundTransparency = .5
    NUM1.BackgroundTransparency = .6
    NUM2.BackgroundTransparency = .6
    NUM3.BackgroundTransparency = .6
    NUM4.BackgroundTransparency = .6
    NUM5.BackgroundTransparency = .6
    NUM6.BackgroundTransparency = .6
    NUM7.BackgroundTransparency = .6
    NUM1.BackgroundTransparency = .7
    NUM2.BackgroundTransparency = .7
    NUM3.BackgroundTransparency = .7
    NUM4.BackgroundTransparency = .7
    NUM5.BackgroundTransparency = .7
    NUM6.BackgroundTransparency = .7
    NUM7.BackgroundTransparency = .7
    wait(.1)
    NUM1.BackgroundTransparency = 0
    NUM2.BackgroundTransparency = 0
    NUM3.BackgroundTransparency = 0
    NUM4.BackgroundTransparency = 0
    NUM5.BackgroundTransparency = 0
    NUM6.BackgroundTransparency = 0
    NUM7.BackgroundTransparency = 0
end

It keeps the bars only on one transparency, and plus, is there an easier way to type this e.e

Answer this question