C# 클래스 UnityPlatformer.Projectile

상속: UnityEngine.MonoBehaviour, IUpdateEntity
파일 보기 프로젝트 열기: llafuente/unity-platformer

공개 프로퍼티들

프로퍼티 타입 설명
onDestroy System.Action
onImpact System.Action

공개 메소드들

메소드 설명
Awake ( ) : void

When Object is Awake, it will be automatically disabled When Fired the projectile, will be cloned and enabled

Destroy ( ) : void

Destroy Projectile waiting destroyDelay if needed

Fire ( Vector3 position ) : Projectile

Clone the projectile, activate, add it to UpdateManager and return :)

LatePlatformerUpdate ( float delta ) : void

Do nothing use PlatformerUpdate instead

OnTriggerEnter2D ( Collider2D o ) : void

When collide with something, check the mask, then check if it's damageable, and Destroy

PlatformerUpdate ( float delta ) : void

Move projectile accordingly

보호된 메소드들

메소드 설명
_Destroy ( ) : void

Real destroy method

메소드 상세

Awake() 공개 메소드

When Object is Awake, it will be automatically disabled When Fired the projectile, will be cloned and enabled
public Awake ( ) : void
리턴 void

Destroy() 공개 메소드

Destroy Projectile waiting destroyDelay if needed
public Destroy ( ) : void
리턴 void

Fire() 공개 메소드

Clone the projectile, activate, add it to UpdateManager and return :)
public Fire ( Vector3 position ) : Projectile
position Vector3
리턴 Projectile

LatePlatformerUpdate() 공개 메소드

Do nothing use PlatformerUpdate instead
public LatePlatformerUpdate ( float delta ) : void
delta float
리턴 void

OnTriggerEnter2D() 공개 메소드

When collide with something, check the mask, then check if it's damageable, and Destroy
public OnTriggerEnter2D ( Collider2D o ) : void
o UnityEngine.Collider2D
리턴 void

PlatformerUpdate() 공개 메소드

Move projectile accordingly
public PlatformerUpdate ( float delta ) : void
delta float
리턴 void

_Destroy() 보호된 메소드

Real destroy method
protected _Destroy ( ) : void
리턴 void

프로퍼티 상세

onDestroy 공개적으로 프로퍼티

Callback when is destroyed
public Action,System onDestroy
리턴 System.Action

onImpact 공개적으로 프로퍼티

Callback when impact something
public Action,System onImpact
리턴 System.Action