generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Issue with tweening a frame.

Previous Thread :: Next Thread 
Luxurize is not online. Luxurize
Joined: 31 Mar 2015
Total Posts: 1289
05 Sep 2015 03:39 PM
F2:TweenPosition(UDim2.new(0.05, 0, 0.1, 0), "Out", "Quad", 2, false)
F2:TweenPosition(UDim2.new(0.05, 0, 1, 0), "Out", "Quad", 2, false)

It will move the first time, but the second tween won't work.


“Insane isn't always black or white. We're all pathological, in our own ways.”
Report Abuse
membra is not online. membra
Joined: 14 Oct 2008
Total Posts: 6313
05 Sep 2015 03:44 PM
Try setting 'override' to true, this allows the GUI to attempt a new tween without having to stop the previous one.
Report Abuse
ToasterCoder is not online. ToasterCoder
Joined: 28 Aug 2015
Total Posts: 137
05 Sep 2015 03:44 PM
call the second one "In" instead of "Out"
Report Abuse
Luxurize is not online. Luxurize
Joined: 31 Mar 2015
Total Posts: 1289
05 Sep 2015 03:59 PM
@Toasted
it being an in/out isn't the issue.


“Insane isn't always black or white. We're all pathological, in our own ways.”
Report Abuse
ForeverDev is not online. ForeverDev
Joined: 04 Oct 2008
Total Posts: 13300
05 Sep 2015 04:01 PM
F2:TweenPosition(UDim2.new(0.05, 0, 0.1, 0), "Out", "Quad", 2, false, function()
F2:TweenPosition(UDim2.new(0.05, 0, 1, 0), "Out", "Quad", 2, false)
end)
Report Abuse
Luxurize is not online. Luxurize
Joined: 31 Mar 2015
Total Posts: 1289
05 Sep 2015 04:07 PM
@Forever
Thanks, that fixed it.


“Insane isn't always black or white. We're all pathological, in our own ways.”
Report Abuse
ForeverDev is not online. ForeverDev
Joined: 04 Oct 2008
Total Posts: 13300
05 Sep 2015 04:09 PM
The reason you had that issue is because the script doesn't wait for TweenPosition to finish before it continues. The last argument of TweenPosition is a function that is automatically called when the tweening is complete....

When F2 finishes tweening, it will execute the callback function and tween it again
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image