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
 

Math forula for the center of the screen?

Previous Thread :: Next Thread 
2JJ1 is not online. 2JJ1
Joined: 15 Mar 2012
Total Posts: 1571
04 Aug 2015 10:30 AM
I'm not too good with coming up with a formula in math.
Can someone think of one to get a frame into the center of the screen?

x = script.Parent.Position.X.Scale
y = script.Parent.Position.Y.Scale

centerX = --Formula here
centerY = --Formula here
Report Abuse
Darkenus is not online. Darkenus
Joined: 17 Jul 2014
Total Posts: 1997
04 Aug 2015 10:32 AM
((.5,(half of the size in x)),(.5,(half the size in y))
Report Abuse
rayk999 is not online. rayk999
Joined: 18 Feb 2011
Total Posts: 4705
04 Aug 2015 10:33 AM
If you sized the gui with Offset:

{.5,-xOffset/2} {.5, -yOffset/2}

if you sized the gui with Scale:

{(1-xScale)/2,0} {(1-yScale)/2,0}
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