Photon Fusion 1.1.9

Public Member Functions | Static Public Member Functions | List of all members
Behaviour Class Reference

Alternative base class to Unity's MonoBehaviour. This allows for components that work both in Unity, as well as the Photon relays. More...

Inherits MonoBehaviour.

Inherited by Hitbox, NetworkEvents, NetworkObject, NetworkRunner, RunnerVisibilityNodes, and SimulationBehaviour.

Public Member Functions

AddBehaviour< T > ()
 Wrapper for Unity's GameObject.AddComponent()
 
GetBehaviour< T > ()
 Wrapper for Unity's GameObject.GetComponentInChildren()
 
bool TryGetBehaviour< T > (out T behaviour)
 Wrapper for Unity's GameObject.TryGetComponent()
 

Static Public Member Functions

static void DestroyBehaviour (Behaviour behaviour)
 Wrapper for Unity's GameObject.Destroy()
 

Detailed Description

Alternative base class to Unity's MonoBehaviour. This allows for components that work both in Unity, as well as the Photon relays.

Member Function Documentation

◆ AddBehaviour< T >()

T AddBehaviour< T > ( )

Wrapper for Unity's GameObject.AddComponent()

Type Constraints
T :Behaviour 

◆ GetBehaviour< T >()

T GetBehaviour< T > ( )

Wrapper for Unity's GameObject.GetComponentInChildren()

Type Constraints
T :Behaviour 

◆ TryGetBehaviour< T >()

bool TryGetBehaviour< T > ( out T  behaviour)

Wrapper for Unity's GameObject.TryGetComponent()

Type Constraints
T :Behaviour