Delones
|
  |
| Joined: 19 Jul 2010 |
| Total Posts: 1703 |
|
|
| 31 Jan 2014 11:37 PM |
How?
Time is a tool you can put on a wall, or wear it on your rizd. |
|
|
| Report Abuse |
|
|
|
| 31 Jan 2014 11:41 PM |
| You just have to do it brick by brick. |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 31 Jan 2014 11:42 PM |
| Ew, no you don't, it's INSANELY simple, and I'll show you |
|
|
| Report Abuse |
|
|
Delones
|
  |
| Joined: 19 Jul 2010 |
| Total Posts: 1703 |
|
|
| 31 Jan 2014 11:43 PM |
:D?
Time is a tool you can put on a wall, or wear it on your rizd. |
|
|
| Report Abuse |
|
|
MHebes
|
  |
| Joined: 04 Jan 2013 |
| Total Posts: 2278 |
|
|
| 31 Jan 2014 11:43 PM |
That's not true. There are plenty of ways to do it using algorithms and methods like ToObject/WorldSpace. I would suggest using the qCmdUtl plugin, I believe that had a model rotation feature. |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 31 Jan 2014 11:44 PM |
for i = 1,5 do ModelPos = MODEL:GetModelCFrame() newPosition = ModelPos * Vector3.new(0.5,0,0) --Change this to make it faster/slower wait(0.1) MODEL:TranslateBy(newPosition - MODEL:GetModelCFrame().p) end |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 31 Jan 2014 11:45 PM |
| My method is for CFraming an entire model to move in increments. |
|
|
| Report Abuse |
|
|
Delones
|
  |
| Joined: 19 Jul 2010 |
| Total Posts: 1703 |
|
|
| 31 Jan 2014 11:47 PM |
How would I move that to the CFrame of one known as 'missile'?
Time is a tool you can put on a wall, or wear it on your rizd. |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 31 Jan 2014 11:48 PM |
And, Hi MHebes! :D
My favourite scripter on SH :p |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 31 Jan 2014 11:49 PM |
You could try doing a repeat until they have the same CFrame, but I beleive someone else on SH would have a much better idea.
MoveTo() only works to move the model, not incrementally. |
|
|
| Report Abuse |
|
|
|
| 01 Feb 2014 12:05 AM |
function CFrameModel(model,part) local center = model:GetModelCFrame() for _,v in pairs(model:GetChildren()) do if v:IsA("BasePart") then local offset = center:inverse()*v.CFrame v.CFrame = part.CFrame*offset end end end
CFrameModel(workspace.Model,workspace.Missile)
There, that should work fine. And sorry, but I can't really explain this to you. I barely understood it myself after a fair amount of thinking and a bunch of tests XD
(If it doesn't work, try this. Oysi apparently made a good model CFramer: http://www.roblox.com/Model-CFramer-by-Oysi-item?id=55719166) |
|
|
| Report Abuse |
|
|
jd678
|
  |
| Joined: 18 Apr 2008 |
| Total Posts: 11529 |
|
|
| 01 Feb 2014 12:14 AM |
| @Rob that won't work, unfortunately I don't really know of a way to do this, all though I know there is one out there. |
|
|
| Report Abuse |
|
|
|
| 01 Feb 2014 12:23 AM |
Hm, just tested it and it worked fine for me. It'll put the center of the model where the Missile is. Even along the same axis the missile is too. Of course, if OP just wanted to move a model by a CFrame value then...
function CFrameModel(model,cf) local center = model:GetModelCFrame() for _,v in pairs(model:GetChildren()) do if v:IsA("BasePart") then local offset = center:inverse()*v.CFrame v.CFrame = center*cf*offset end end end
CFrameModel(workspace.Model,CFrame.new(0,-2,0)) |
|
|
| Report Abuse |
|
|