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: Rotate in script

Previous Thread :: Next Thread 
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 12:44 PM
How would you rotate a brick in script?
Report Abuse
IoIiderp is not online. IoIiderp
Joined: 05 Feb 2012
Total Posts: 8613
05 Mar 2015 12:46 PM
part.Rotation = Vector3.new(0,0,0)
Report Abuse
ChiefDelta is not online. ChiefDelta
Joined: 05 Nov 2010
Total Posts: 13071
05 Mar 2015 12:47 PM
part.CFrame = part.CFrame * CFrame.Angles(1, 1, 1)
Report Abuse
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 12:54 PM
I want to rotate so it faces down the way, is that possible?
Report Abuse
anaIyze is not online. anaIyze
Joined: 29 May 2014
Total Posts: 2048
05 Mar 2015 01:06 PM
lol wt way
Report Abuse
IoIiderp is not online. IoIiderp
Joined: 05 Feb 2012
Total Posts: 8613
05 Mar 2015 01:07 PM
umg analyze u haxor
Report Abuse
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 01:14 PM
I want to rotate it so it slightly faces to the ground
Report Abuse
anaIyze is not online. anaIyze
Joined: 29 May 2014
Total Posts: 2048
05 Mar 2015 01:15 PM
part.cframe=part.cframe*cframe.angles(0,0,math.rad(-30));
Report Abuse
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 01:18 PM
that does nothing
Report Abuse
anaIyze is not online. anaIyze
Joined: 29 May 2014
Total Posts: 2048
05 Mar 2015 01:19 PM
-_-
Report Abuse
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 01:23 PM
part.CFrame = part.CFrame * CFrame.Angles(0, 1.5, 0)

I've rotated it around 90 but I want to also rotate it so it faces the ground slightly
Report Abuse
anaIyze is not online. anaIyze
Joined: 29 May 2014
Total Posts: 2048
05 Mar 2015 01:25 PM
do you know how to use radians?
Report Abuse
DJSasuke1963 is not online. DJSasuke1963
Joined: 30 Nov 2012
Total Posts: 1136
05 Mar 2015 01:30 PM
Uhm I don't think so
Report Abuse
anaIyze is not online. anaIyze
Joined: 29 May 2014
Total Posts: 2048
05 Mar 2015 01:38 PM
math.rad = radians
don't feel like explaining - go here http://lua-users.org/wiki/MathLibraryTutorial
& my example works fine
Report Abuse
ChiefDelta is not online. ChiefDelta
Joined: 05 Nov 2010
Total Posts: 13071
05 Mar 2015 01:42 PM
math.rad() takes a certain number of degrees and turns them into radians, because most people don't memorize radian "translation", and prefer to work with degrees.

The arg you send to math.rad() (i.e. 30) is the number of degrees you want converted to radians.
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