Class PlayerMountBehaviour
Inheritance
Object
Component
Behaviour
MonoBehaviour
PlayerMountBehaviour
Inherited Members
MonoBehaviour.IsInvoking()
MonoBehaviour.CancelInvoke()
MonoBehaviour.StopCoroutine(Coroutine)
MonoBehaviour.StopAllCoroutines()
MonoBehaviour.useGUILayout
MonoBehaviour.runInEditMode
Behaviour.enabled
Behaviour.isActiveAndEnabled
Component.GetComponent<T>()
Component.TryGetComponent<T>(out T)
Component.GetComponentInChildren<T>()
Component.GetComponentsInChildren<T>()
Component.GetComponentInParent<T>()
Component.GetComponentsInParent<T>()
Component.GetComponents<T>()
Component.transform
Component.gameObject
Component.tag
Object.GetInstanceID()
Object.GetHashCode()
Object.Instantiate(Object, Vector3, Quaternion)
Object.Instantiate(Object, Vector3, Quaternion, Transform)
Object.Instantiate(Object)
Object.Instantiate(Object, Transform)
Object.Instantiate<T>(T)
Object.Instantiate<T>(T, Vector3, Quaternion)
Object.Instantiate<T>(T, Vector3, Quaternion, Transform)
Object.Instantiate<T>(T, Transform)
Object.Destroy(Object)
Object.DestroyImmediate(Object)
Object.DontDestroyOnLoad(Object)
Object.DestroyObject(Object)
Object.FindObjectsOfType<T>()
Object.FindObjectsByType<T>(FindObjectsSortMode)
Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)
Object.FindObjectOfType<T>()
Object.FindFirstObjectByType<T>()
Object.FindAnyObjectByType<T>()
Object.FindFirstObjectByType<T>(FindObjectsInactive)
Object.FindAnyObjectByType<T>(FindObjectsInactive)
Object.ToString()
Object.name
Object.hideFlags
Namespace: BomberDogs.PlayerBehaviours
Assembly: Assembly-CSharp.dll
Syntax
[RequireComponent(typeof(PlayerWalkBehaviour))]
[RequireComponent(typeof(PlayerBehaviourCore))]
public class PlayerMountBehaviour : PlayerBehaviourBase
Fields
| Edit this page View Sourcemountable
Declaration
[SerializeField]
protected MountableBehaviourCore mountable
Field Value
| Type | Description |
|---|---|
| MountableBehaviourCore |
mounted
Declaration
[SerializeField]
protected bool mounted
Field Value
| Type | Description |
|---|---|
| bool |
mountedToDownState
Declaration
[Tooltip("Mounted to down animator state")]
[AnimatorStatesDropdown(0)]
public string mountedToDownState
Field Value
| Type | Description |
|---|---|
| string |
mountedToRightState
Declaration
[Tooltip("Mounted to right animator state")]
[AnimatorStatesDropdown(0)]
public string mountedToRightState
Field Value
| Type | Description |
|---|---|
| string |
mountedToUpState
Declaration
[Tooltip("Mounted to up animator state")]
[AnimatorStatesDropdown(0)]
public string mountedToUpState
Field Value
| Type | Description |
|---|---|
| string |
mounting
Declaration
[Header("Debug")]
[SerializeField]
protected bool mounting
Field Value
| Type | Description |
|---|---|
| bool |
mountingJumpHeight
Declaration
[Tooltip("Jump height in the mount animation")]
public float mountingJumpHeight
Field Value
| Type | Description |
|---|---|
| float |
mountingLerpDuration
Declaration
[Header("General Tweaks")]
[Tooltip("Duration of lerp animation. Starting from ground to mountable")]
public float mountingLerpDuration
Field Value
| Type | Description |
|---|---|
| float |
mountingToDownState
Declaration
[Tooltip("Mounting to down animator state")]
[AnimatorStatesDropdown(0)]
public string mountingToDownState
Field Value
| Type | Description |
|---|---|
| string |
mountingToRightState
Declaration
[Header("animator states")]
[Tooltip("Mounting to right animator state")]
[AnimatorStatesDropdown(0)]
public string mountingToRightState
Field Value
| Type | Description |
|---|---|
| string |
mountingToUpState
Declaration
[Tooltip("Mounting to up animator state")]
[AnimatorStatesDropdown(0)]
public string mountingToUpState
Field Value
| Type | Description |
|---|---|
| string |
walkBehaviour
Declaration
[SerializeField]
protected IPlayerWalkBehaviour walkBehaviour
Field Value
| Type | Description |
|---|---|
| IPlayerWalkBehaviour |
Methods
| Edit this page View SourceEndMounting()
Finalize mounting
Declaration
public void EndMounting()
GetMountable()
Declaration
public MountableBehaviourCore GetMountable()
Returns
| Type | Description |
|---|---|
| MountableBehaviourCore |
IsMounted()
Check if is mounted
Declaration
public bool IsMounted()
Returns
| Type | Description |
|---|---|
| bool |
OnEggCollide(Egg, List<EggTrailDef>)
When it collides with an egg
Declaration
public virtual void OnEggCollide(Egg egg, List<MountableEggTrailBehaviour.EggTrailDef> followingEggsInheritance = null)
Parameters
| Type | Name | Description |
|---|---|---|
| Egg | egg | |
| List<MountableEggTrailBehaviour.EggTrailDef> | followingEggsInheritance |
OnEnterInTeleportPortal()
When the mountable enters in a portal
Declaration
public void OnEnterInTeleportPortal()
OnMountableUpdate()
When the mountable updates, this method is also called
Declaration
public void OnMountableUpdate()
OnTriggerEnter2D(Collider2D)
Declaration
public void OnTriggerEnter2D(Collider2D col)
Parameters
| Type | Name | Description |
|---|---|---|
| Collider2D | col |
StartMounting(MountableBehaviourCore, float)
Handle mounting and their animation
Declaration
public void StartMounting(MountableBehaviourCore mountable, float mountingLerpDuration)
Parameters
| Type | Name | Description |
|---|---|---|
| MountableBehaviourCore | mountable | |
| float | mountingLerpDuration |
UpdateMountedAnimation()
Update mounted animation
Declaration
public void UpdateMountedAnimation()
Events
| Edit this page View SourceonMount
Declaration
public event Action onMount
Event Type
| Type | Description |
|---|---|
| Action |