Blaknet
|
  |
| Joined: 22 Jul 2011 |
| Total Posts: 67 |
|
|
| 17 Mar 2015 06:12 PM |
| I need a welding script that works with Wedge |
|
|
| Report Abuse |
|
|
Dwarlon
|
  |
| Joined: 18 Jul 2013 |
| Total Posts: 4604 |
|
|
| 17 Mar 2015 06:13 PM |
| post the script you have now please |
|
|
| Report Abuse |
|
|
Blaknet
|
  |
| Joined: 22 Jul 2011 |
| Total Posts: 67 |
|
|
| 17 Mar 2015 08:06 PM |
function Weld(x,y) local W = Instance.new("Weld") W.Part0 = x W.Part1 = y local CJ = CFrame.new(x.Position) local C0 = x.CFrame:inverse()*CJ local C1 = y.CFrame:inverse()*CJ W.C0 = C0 W.C1 = C1 W.Parent = x end
function Get(A) if A.className == "Part" then Weld(script.Parent.Handle, A) A.Anchored = false else local C = A:GetChildren() for i=1, #C do Get(C[i]) end end end
function Finale() Get(script.Parent) end
script.Parent.Equipped:connect(Finale) script.Parent.Unequipped:connect(Finale) Finale() |
|
|
| Report Abuse |
|
|
Dwarlon
|
  |
| Joined: 18 Jul 2013 |
| Total Posts: 4604 |
|
|
| 17 Mar 2015 08:10 PM |
function Weld(x,y) local W = Instance.new("Weld") W.Part0 = x W.Part1 = y local CJ = CFrame.new(x.Position) local C0 = x.CFrame:inverse()*CJ local C1 = y.CFrame:inverse()*CJ W.C0 = C0 W.C1 = C1 W.Parent = x end
function Get(A) if A.className == "Part" or A.className == "WedgePart" then Weld(script.Parent.Handle, A) A.Anchored = false else local C = A:GetChildren() for i=1, #C do Get(C[i]) end end end
function Finale() Get(script.Parent) end
script.Parent.Equipped:connect(Finale) script.Parent.Unequipped:connect(Finale) Finale() |
|
|
| Report Abuse |
|
|
Blaknet
|
  |
| Joined: 22 Jul 2011 |
| Total Posts: 67 |
|
| |
|