BruceAB12
|
  |
| Joined: 19 Jan 2012 |
| Total Posts: 3238 |
|
|
| 17 Aug 2013 06:57 PM |
function animate() while true do wait(.1) local sp = script.Parent local spp = sp.Parent local a = spp.GameFrame.top.b local b = sp.dna.Value if b < 100 then repeat wait(.1) a:TweenSize(UDim2.new(0, b, 0, 20),1) until b >= 100 end if b >= 100 then repeat wait(.1) a:TweenSize(UDim2.new(0, 100, 0, 20),1) until b < 100 end end end animate()
The tweensize does not work. No output. |
|
|
| Report Abuse |
|
|
BruceAB12
|
  |
| Joined: 19 Jan 2012 |
| Total Posts: 3238 |
|
| |
|
ZachBloxx
|
  |
| Joined: 26 Jun 2013 |
| Total Posts: 2833 |
|
|
| 17 Aug 2013 07:01 PM |
| a:TweenSize(UDim2.new(0, b, 0, 20),"Out","Quad",1,true) |
|
|
| Report Abuse |
|
|
BruceAB12
|
  |
| Joined: 19 Jan 2012 |
| Total Posts: 3238 |
|
| |
|
lordrambo
|
  |
| Joined: 16 Jun 2009 |
| Total Posts: 20628 |
|
|
| 17 Aug 2013 07:05 PM |
floattime = 3
if b < 100 then a:TweenSize(UDim2.new(0, b, 0, 20),"Out","Linear",floattime) repeat wait(0.03) until b>100 end
You also cannot make a value/property into a variable, you have to make the object into a variable and then put .Value on to it. |
|
|
| Report Abuse |
|
|
lordrambo
|
  |
| Joined: 16 Jun 2009 |
| Total Posts: 20628 |
|
|
| 17 Aug 2013 07:12 PM |
Never mind, you don't have an issue with your variable. Well, you do, but not what I said.
Your variable (b) isn't going to change when that value changes, it will stay the same number as it was at the top of the script. To fix this, do what I suggested earlier. |
|
|
| Report Abuse |
|
|