Class UFEOtherTrigger
Detects trigger collisions.
Inherited Members
Namespace: Xareus.Unity
Assembly: Xareus.Unity.Librairies.dll
Syntax
public class UFEOtherTrigger : MonoBehaviour
Fields
colliders
Declaration
public List<Collider> colliders
Field Value
Type | Description |
---|---|
List<Collider> |
Methods
AreColliding(Collider, Collider)
Indicates whether a trigger collides another trigger.
Declaration
public static bool AreColliding(Collider trigger1, Collider trigger2)
Parameters
Type | Name | Description |
---|---|---|
Collider | trigger1 | The first trigger |
Collider | trigger2 | The second trigger |
Returns
Type | Description |
---|---|
bool |
|
AreColliding(GameObject, GameObject)
Indicates whether an object collides another object.
Declaration
public static bool AreColliding(GameObject obj1, GameObject obj2)
Parameters
Type | Name | Description |
---|---|---|
GameObject | obj1 | The object trigger |
GameObject | obj2 | The object trigger |
Returns
Type | Description |
---|---|
bool |
|
GetColliding(Collider)
Get all triggers colliding with the given one
Declaration
public static IEnumerable<Collider> GetColliding(Collider trigger)
Parameters
Type | Name | Description |
---|---|---|
Collider | trigger | The trigger |
Returns
Type | Description |
---|---|
IEnumerable<Collider> | All the triggers colliding with the given one. Empty IEnumerable if the given trigger is not present |
GetColliding(GameObject)
Get all objects colliding with the given one
Declaration
public static IEnumerable<GameObject> GetColliding(GameObject obj)
Parameters
Type | Name | Description |
---|---|---|
GameObject | obj |
Returns
Type | Description |
---|---|
IEnumerable<GameObject> | All the triggers colliding with the given one. Empty IEnumerable if the given trigger is not present |
IsColliding(Collider)
Check if the given trigger if colliding with any other one
Declaration
public static bool IsColliding(Collider trigger)
Parameters
Type | Name | Description |
---|---|---|
Collider | trigger | The trigger |
Returns
Type | Description |
---|---|
bool | True if this trigger is colliding with another one, false otherwise |
IsColliding(GameObject)
Check if the given object if colliding with any other one
Declaration
public static bool IsColliding(GameObject obj)
Parameters
Type | Name | Description |
---|---|---|
GameObject | obj | The object holding the trigger |
Returns
Type | Description |
---|---|
bool | True if this object is colliding with another one, false otherwise |