C# Class X10D.Unity.GameObjectExtensions

Extension methods for GameObject.
Mostrar archivo Open project: oliverbooth/X10D

Public Methods

Method Description
LookAt ( GameObject gameObject, GameObject other ) : void

Rotates the Transform component on the current GameObject such that is is facing another GameObject.

LookAt ( GameObject gameObject, Transform other ) : void

Rotates the Transform component on the current GameObject such that is is facing another Transform.

Method Details

LookAt() public static method

Rotates the Transform component on the current GameObject such that is is facing another GameObject.
/// is null /// - or - /// is null. ///
public static LookAt ( GameObject gameObject, GameObject other ) : void
gameObject GameObject The current game object.
other GameObject The target.
return void

LookAt() public static method

Rotates the Transform component on the current GameObject such that is is facing another Transform.
/// is null /// - or - /// is null. ///
public static LookAt ( GameObject gameObject, Transform other ) : void
gameObject GameObject The current game object.
other Transform The target.
return void