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 » Scripting Helpers
Home Search
 

Re: I really don't know how to...

Previous Thread :: Next Thread 
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:36 PM
I don't know how you would use a script to move a Gui into a certian position, can you please help? I know this uses UDim2.new() but I still don't know how. I've tryed myself, but I just failed at it.
Report Abuse
1WOOF1 is not online. 1WOOF1
Joined: 03 May 2009
Total Posts: 20682
27 Sep 2011 12:40 PM
[ Content Deleted ]
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:41 PM
I know that, but I ment in a script that automatically moves a Gui, not just a single command to move it to the top left corner.
Report Abuse
1WOOF1 is not online. 1WOOF1
Joined: 03 May 2009
Total Posts: 20682
27 Sep 2011 12:42 PM
[ Content Deleted ]
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:43 PM
...................... I KNOW THAT. I MENT, MOVE IT SLOWLY IN A LOOP.
Report Abuse
1WOOF1 is not online. 1WOOF1
Joined: 03 May 2009
Total Posts: 20682
27 Sep 2011 12:44 PM
[ Content Deleted ]
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:45 PM
:TweenPosition()?? (I don't know a lot of Lua scripting, and i'm reading a book and I don't understand the Lua in it I was posting here so I could Clarify.
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 12:51 PM
http://wiki.roblox.com/index.php/TweenPosition_(Method)
Y U NO GOOGLE
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:51 PM
IDOGOOGLE. IDUNNAUNDASTANDFROMAWIKI!
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 12:56 PM
Y U NO SMARTS
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 12:57 PM
I IS SMARTS. I DUNNA UNDASTAND TEH WIKI!
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:02 PM
Thinking, would this work?:

Game.Players:PlayerAdded:connect(function()
script.Parent.Position:TweenPosition(UDim2.new(1.022, 0, -0.025, 0), "out", "Quad", 1)
wait(3)
script.Parent.Position:TweenPosition(UDim2.new(0, 0, -0.025, 0), "out", "Quad", 1)
end)
Report Abuse
AntiBoomz0r is online. AntiBoomz0r
Joined: 02 Oct 2009
Total Posts: 1345
27 Sep 2011 01:02 PM
@dig
Youre not even trying to, lazy b.. Wait, Im not gonna say anything...

Also, tweening is simple

You select a frame

Frame = script.Parent

then you use :TweenPosition, :TweenSize or :TweenSizeAndPosition on the frame

Frame:TweenPosition()

Then put the position you want it to go to, in teh ()s

Frame:TweenPosition(UDim2.new(0.5,0,0.5,0))

TADAH!
The frame will smoothly, automaticly move to that position in 1 second!


~YAYNIMATIONS, MA LITTUL BRONIES~

Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:04 PM
@AntiBoom, i'm trying, but the wiki dosen't explain properly. I mean, I don't get it.
Report Abuse
AntiBoomz0r is online. AntiBoomz0r
Joined: 02 Oct 2009
Total Posts: 1345
27 Sep 2011 01:08 PM
Its "Out", not "out"
And you use the tweening on a frame, not position

And you dont need all the arguments

if script.Parent is a FRAME...

script.Parent:TweenPosition(UDim2.new(0, 0, -0.025, 0), "Out", "Quad", 1)

does the same as

script.Parent:TweenPosition(UDim2.new(0, 0, -0.025, 0))

But if you want it to move faster, like in .5 seconds, you need to put the out and quad

script.Parent:TweenPosition(UDim2.new(0, 0, -0.025, 0), "Out", "Quad", .5)

*sadface*


But basicly tweening is


FRAME:TweenSize/Position/SizeAndPosition


And for arguments, for Size/Position

(EndSize/Position,"Out","Quad",time)

for SizeAndPosition

(EndSize,EndPosition,"Out","Quad",time)


Other stuff you dont need to know... At least yet 8D


I hope you could understand something outta my random mini-tutorial.
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 01:09 PM
It's Enum.EasingDirection["Out"].
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:10 PM
Thanks, NOW I get it :D
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:11 PM
so this would work now?:
Game.Players:PlayerAdded:connect(function()
script.Parent:TweenPosition(UDim2.new(1.022, 0, -0.025, 0))
wait(3)
script.Parent:TweenPosition(UDim2.new(0, 0, -0.025, 0))
end)
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 01:11 PM
Nope.
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:13 PM
why? D: I don't know about TweenPosition, and the wiki dosen't explain enough for me.
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 01:13 PM
Game.Players:PlayerAdded:connect(function()

Players:PlayerAdded

Guess the error.
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:14 PM
d'OH!
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:14 PM
I've sorted that out now, so will it work?
Report Abuse
Fl0x is not online. Fl0x
Joined: 06 Aug 2010
Total Posts: 5169
27 Sep 2011 01:15 PM
Try it out.
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Sep 2011 01:16 PM
No errors are popping up, so that must mean they work.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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