|
| 09 Jun 2016 12:59 AM |
| How would I do this for a npc..? |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2016 01:02 AM |
local g = game.Workspace.Zombies:GetChildren() for i=1,#g do if g[i] ~= nil then if g[i]:FindFirstChild('Torso') ~= nil then
--face the torso to the script.Parent
end end end |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2016 01:02 AM |
Torso.CFrame = CFrame.new(Torso.Position, Object.Position)
|
|
|
| Report Abuse |
|
|
Hedr0n
|
  |
| Joined: 05 Jan 2016 |
| Total Posts: 1524 |
|
|
| 09 Jun 2016 01:04 AM |
| CFrame.new(Specific_Object, Npc.Character.HumanoidRootPart.CFrame) |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2016 01:07 AM |
"CFrame.new(Specific_Object, Npc.Character.HumanoidRootPart.CFrame)" you're dumb |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2016 01:08 AM |
for i=1,#g do if g[i] ~= nil then if g[i]:FindFirstChild('Torso') ~= nil then g[i].Torso.CFrame = CFrame.new(g[i].Torso.Position,explosion.Position) end end end
Doesn't work |
|
|
| Report Abuse |
|
|
| |
|
|
| 09 Jun 2016 01:40 AM |
| I dont feel like typing the code, but try to get the magnitude of the nearest object you are looking for, and use BodyGyro. |
|
|
| Report Abuse |
|
|
|
| 09 Jun 2016 01:43 AM |
*just remembered you said for a NPC* In that case; Do not use BodyGyro, change to C0 for the weld of the torso, and such. |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 09 Jun 2016 02:26 AM |
I'm using this right now and it works perfect.
local P = Char:WaitForChild("Torso") P.CFrame = CFrame.new(P.Position, Vector3.new(workspace.CamToPart.Position.X,P.Position.y,workspace.CamToPart.Position.Z))
Super Fast Profit Finder - https://www.roblox.com/games/421528235/Super-Fast-Profit-Finder |
|
|
| Report Abuse |
|
|