generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Scripting Help

Previous Thread :: Next Thread 
Samson918 is not online. Samson918
Joined: 15 Apr 2012
Total Posts: 174
10 Apr 2017 04:34 PM
How can I make an object always point towards another?
For example, an arrow that always points towards a players torso.

Thank you!
Report Abuse
chexyalani is online. chexyalani
Joined: 26 Mar 2017
Total Posts: 694
10 Apr 2017 04:38 PM
--localscript

local player=game.Players.LocalPlayer

repeat wait() until player.Character
repeat wait() until player.Character.HumanoidRootPart

local char=player.Character
local hrp=char.HumanoidRootPart
local part=workspace.Part

game:GetService("RunService").RenderStepped:Connect(function()
part.CFrame=CFrame.new(part.Position, hrp.Position)
end)
Report Abuse
Samson918 is not online. Samson918
Joined: 15 Apr 2012
Total Posts: 174
10 Apr 2017 04:42 PM
Did nothing D:
Report Abuse
chexyalani is online. chexyalani
Joined: 26 Mar 2017
Total Posts: 694
10 Apr 2017 04:46 PM
It is just an example
Report Abuse
Samson918 is not online. Samson918
Joined: 15 Apr 2012
Total Posts: 174
10 Apr 2017 04:59 PM
nevermind I got it working.

ty
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image