|
| 06 Jan 2017 07:40 PM |
local P1 = script.Parent.Base
local Parts = script.Parent.Model:GetChildren()
for i = 1, #Parts do local P2 = script.Parent.Model[i] P2.CFrame = P1.CFrame * CFrame.Angles(0, ((math.rad(360/#Parts) * i) - math.rad(360/#Parts)) + math.rad(180), 0) * CFrame.new(-45, 10.98, 0) * CFrame.new(P1.CFrame.lookVector * 10, 0, 0)
end
lookVector isn't working or I'm messing it up.
When I uploaded the meshes I didn't fix them properly so they're rotated wrongly relative to the part, so I have to rotate the parts around to face the main part's RightSurface. I'm ok with that, but this lookVector thing just doesn't wanna work. No matter what number I set it to they just won't budge. |
|
|
| Report Abuse |
|
|
GonnaW
|
  |
| Joined: 10 Oct 2016 |
| Total Posts: 3853 |
|
|
| 06 Jan 2017 08:13 PM |
try lookVector * 10 instead of 10,0,0
https://www.roblox.com/Trade/TradeWindow.aspx?TradePartnerID=170052312 |
|
|
| Report Abuse |
|
|
|
| 06 Jan 2017 08:16 PM |
I'm not sure what you're doing, multiplying CFrames, but
local P2 = Parts[i] will make them go do it. |
|
|
| Report Abuse |
|
|
|
| 06 Jan 2017 08:18 PM |
| Oh yeah... I'm not supposed to put it into the Vector3. How silly of me lol |
|
|
| Report Abuse |
|
|
|
| 06 Jan 2017 08:23 PM |
local P1 = script.Parent.Base
local Parts = script.Parent.Model:GetChildren()
for i = 1, #Parts do local P2 = script.Parent.Model[i] P2.CFrame = P1.CFrame * CFrame.Angles(0, ((math.rad(360/#Parts) * i) - math.rad(360/#Parts)) + math.rad(180), 0) * CFrame.new(-45, 10.98, 0) + P1.CFrame.rightVector * -14.2
end
That fixed it lmao... Now for the tremendously long and arduous process of resizing and aligning everything by hand now that they're positioned properly.
That's what I get for using multiple meshes lol |
|
|
| Report Abuse |
|
|
GonnaW
|
  |
| Joined: 10 Oct 2016 |
| Total Posts: 3853 |
|
|
| 06 Jan 2017 08:26 PM |
Your script confuses me What are you even trying to do?
https://www.roblox.com/Trade/TradeWindow.aspx?TradePartnerID=170052312 |
|
|
| Report Abuse |
|
|