Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
|
| 05 Mar 2012 04:30 PM |
| How can you make an object face another object? Like the front of one objects turns to the direction of another object. |
|
|
| Report Abuse |
|
|
Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
| |
|
07lchris
|
  |
| Joined: 28 Feb 2010 |
| Total Posts: 1603 |
|
|
| 05 Mar 2012 04:46 PM |
What? CFrame rotation?
obj1.CFrame = CFrame.new(x,y,z) * CFrame.Angles(x,y,z)
|
|
|
| Report Abuse |
|
|
Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
|
| 05 Mar 2012 04:49 PM |
| Ugh, does no one know? I've seen it before. |
|
|
| Report Abuse |
|
|
nate890
|
  |
| Joined: 22 Nov 2008 |
| Total Posts: 21686 |
|
|
| 05 Mar 2012 04:52 PM |
obj.CFrame=CFrame.new(obj.Position,obj2.Position)
"Bro five! Wear this to let everyone know you think they deserve a high five." |
|
|
| Report Abuse |
|
|
07lchris
|
  |
| Joined: 28 Feb 2010 |
| Total Posts: 1603 |
|
|
| 05 Mar 2012 04:52 PM |
| Know-one can help if you are as vague as you are. If you explained clearer we might be able to help, and even so; you're not supposed to request on this forum. Why not have a go first? |
|
|
| Report Abuse |
|
|
07lchris
|
  |
| Joined: 28 Feb 2010 |
| Total Posts: 1603 |
|
|
| 05 Mar 2012 04:56 PM |
@nate, it's
obj.CFrame = CFrame.new(Vector3 position, Vector3 point) |
|
|
| Report Abuse |
|
|
nate890
|
  |
| Joined: 22 Nov 2008 |
| Total Posts: 21686 |
|
|
| 05 Mar 2012 04:57 PM |
Shush
"Bro five! Wear this to let everyone know you think they deserve a high five." |
|
|
| Report Abuse |
|
|
Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
|
| 05 Mar 2012 04:58 PM |
| Thanks nate. Now, is there a way to make it so it only uses the x and z value, and if the two objects were on different y values, they would only face each other on the x,z plane, and wouldn't face up/down. |
|
|
| Report Abuse |
|
|