IDKBlox
|
  |
| Joined: 05 Apr 2013 |
| Total Posts: 1304 |
|
|
| 27 Dec 2016 03:23 AM |
| How would I be able to move a whole model with a script? |
|
|
| Report Abuse |
|
|
Soybeen
|
  |
| Joined: 17 Feb 2010 |
| Total Posts: 21462 |
|
|
| 27 Dec 2016 03:29 AM |
Set its PrimaryPart, and then say..
Model:SetPrimaryPartCFrame(CFrame.new(0,0,0)) -- input your own coords
|
|
|
| Report Abuse |
|
|
IDKBlox
|
  |
| Joined: 05 Apr 2013 |
| Total Posts: 1304 |
|
|
| 27 Dec 2016 03:36 AM |
Thanks man! Now is there a way to make the model go down until it finds ground? if that makes sense.. Well make it where its not floating
This is what I'm using:
Crate:SetPrimaryPartCFrame(CFrame.new(Player.Character.Torso.Position+Player.Character.Torso.CFrame.lookVector*5)) |
|
|
| Report Abuse |
|
|
Soybeen
|
  |
| Joined: 17 Feb 2010 |
| Total Posts: 21462 |
|
|
| 27 Dec 2016 03:47 AM |
-- you would have to find the bottom-most part of the model. If I were you, I would make an invisible part on the bottom of your crate that you assign to be the PrimaryPart with minimal thickness
ray = Ray.new(Crate.PrimaryPart.Position,Vector3.new(0,-1,0).unit*9999) part,pos = workspace:FindPartOnRayWithIgnoreList(ray,Crate) startCFrame = Crate.PrimaryPart.CFrame distance = (startCFrame.p-pos)
for i=0,distance,1/10000 do Crate:SetPrimaryPartCFrame(startCFrame:lerp(endCFrame,i) wait() -- crate gon' fall slow end
|
|
|
| Report Abuse |
|
|
IDKBlox
|
  |
| Joined: 05 Apr 2013 |
| Total Posts: 1304 |
|
| |
|