C# Class UnityPlatformer.BoxTrigger2D

Shortcut to create a Trigger2D, configure: BoxCollider2D and Rigidbody2D. *NOTE* BoxCollider2D and Rigidbody2D will be hidden.
Inheritance: Trigger2D
Exibir arquivo Open project: llafuente/unity-platformer

Public Properties

Property Type Description
collisionMask UnityEngine.LayerMask
onTriggerEnter2D OnTrigger
onTriggerExit2D OnTrigger
onTriggerStay2D OnTrigger

Public Methods

Method Description
OnTriggerEnter2D ( Collider2D o ) : void
OnTriggerExit2D ( Collider2D o ) : void
OnTriggerStay2D ( Collider2D o ) : void
Start ( ) : void

Get/Create BoxCollider2D & Rigidbody2D, then configure

Private Methods

Method Description
OnDrawGizmos ( ) : void

Method Details

OnTriggerEnter2D() public method

public OnTriggerEnter2D ( Collider2D o ) : void
o UnityEngine.Collider2D
return void

OnTriggerExit2D() public method

public OnTriggerExit2D ( Collider2D o ) : void
o UnityEngine.Collider2D
return void

OnTriggerStay2D() public method

public OnTriggerStay2D ( Collider2D o ) : void
o UnityEngine.Collider2D
return void

Start() public method

Get/Create BoxCollider2D & Rigidbody2D, then configure
public Start ( ) : void
return void

Property Details

collisionMask public_oe property

Allowed mask, if something in the mask collide, trigger will fire!
public LayerMask,UnityEngine collisionMask
return UnityEngine.LayerMask

onTriggerEnter2D public_oe property

callback when OnTriggerEnter2D is called with a object that match collisionMask
public OnTrigger onTriggerEnter2D
return OnTrigger

onTriggerExit2D public_oe property

callback when OnTriggerExit2D is called with a object that match collisionMask
public OnTrigger onTriggerExit2D
return OnTrigger

onTriggerStay2D public_oe property

callback when OnTriggerStay2D is called with a object that match collisionMask
public OnTrigger onTriggerStay2D
return OnTrigger