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: Weld Rotation

Previous Thread :: Next Thread 
theroadrunner is not online. theroadrunner
Joined: 06 Oct 2010
Total Posts: 862
12 Oct 2013 09:40 PM
When rotating a weld using CFrame.Angles, you rotate a part relative to another part. My question is, is there any way to rotate the part normally with a weld? (not relative to another part)
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
12 Oct 2013 09:44 PM
yes, Sort of the thing i need help with, only simpler:

local vec = CFrame.new(Vector3.new(0,0,0), Vector3.new(0,0,1))--makes the CFrame look forward
local cf = vec:toObjectSpace(weld.Part0.CFrame)--creates the offset needed
cf is your end cframe value
Report Abuse
theroadrunner is not online. theroadrunner
Joined: 06 Oct 2010
Total Posts: 862
12 Oct 2013 09:47 PM
Alright, so, I do

local vec = CFrame.Angles(0,math.pi/2,0) --What I want to rotate it by in world space
local cf = vec:toObjectSpace(weld.Part0.CFrame)
weld.C0 = weld.C0 * cf

Right?
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
12 Oct 2013 09:50 PM
Don't ask me, i'm horrible at using CFrame methods. I had to get help on this subject before, so i just mostly copy and pasted from my old script.
Report Abuse
theroadrunner is not online. theroadrunner
Joined: 06 Oct 2010
Total Posts: 862
12 Oct 2013 09:52 PM
Well, where's the forum you got help on?
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
12 Oct 2013 09:55 PM
it was over a year ago, so about 600 posts of mine ago... I would suggest wiki, but it doesnt give much information about this.
Report Abuse
spynaz is online. spynaz
Joined: 17 Feb 2011
Total Posts: 1326
12 Oct 2013 09:57 PM
Then find it from one of your scripts.
Report Abuse
theroadrunner is not online. theroadrunner
Joined: 06 Oct 2010
Total Posts: 862
12 Oct 2013 09:58 PM
The wiki? On welds?

Bleh.
Report Abuse
JoshuaKempfert is not online. JoshuaKempfert
Joined: 16 Feb 2013
Total Posts: 2407
12 Oct 2013 10:16 PM
I need to learn Objectspace and WorldSpace qq
Report Abuse
theroadrunner is not online. theroadrunner
Joined: 06 Oct 2010
Total Posts: 862
14 Oct 2013 04:35 PM
I took the long route, and made two different bricks, each with a weld, so that I could control it remotely.

Gawd, I hate welds.
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