UniFlow is a library that can connect various Unity components without writing any C# script.
You can implement easily processes such as "Tutorial that accepts user interaction" and "Waiting for the end of playback of Animation, Audio, Timeline, etc.".
upm add package dev.monry.uniflow
Please refer to this repository about the upm
command.
Attach one or more Components what implements ConnectorBase
listed below into GameObject.
Set Next ConnectorBase
into Target Instances field for each Connectors.
It is also possible to solve with Zenject.ResolveIdAll<T>()
by setting ID in Target Ids field
Implement Component what inherits ReceiverBase
.
Implement the process you want to execute when the event is received in the OnReceive()
method that needs to override by ReceiverBase
.
This method will be passed EventMessages
what contains all propagated event informations.
Specify instances what inherits ConnectableBase
into this field.
* ConnectorBase
and ReceiverBase
are inherits ConnectableBase
Fire messages at the correct time for each component.
Specify IDs what provides instances of IConnectable
resolved by Zenject.ResolveIdAll()
into this field.
Fire messages at the correct time for each component.
Set true to allow to act as the entry point of events.
Individual parameters can be specified for each component.
UniFlow provides GraphView to view/edit connectables in scenes/prefabs
This component observes lifecycle events like as Start
, Update
, FixedUpdate
, OnEnable
, Destroy
, ...
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- Start
- Update
- FixedUpdate
- LateUpdate
- OnEnable
- OnDisable
- OnDestroy
This component observes events like as OnPointerXxx
, OnDrag
, ...
If you do not specify instance of UIBehaviour
will be obtained by GetComponent<UIBehaviour>()
Component supports below events to observe.
- PointerEnter
- PointerExit
- PointerDown
- PointerUp
- PointerClick
- Drag
- Drop
- Scroll
- UpdateSelected
- Select
- Deselect
- Move
- InitializePotentialDrag
- BeginDrag
- EndDrag
- Submit
- Cancel
This component observes Transform events.
If you do not specify instance of Component
will be obtained by this.transform
.
Component supports below events to observe.
- BeforeTransformParentChanged
- TransformParentChanged
- TransformChildrenChanged
This component observes RectTransform events.
If you do not specify instance of Component
will be obtained by GetComponent<RectTransform>()
Component supports below events to observe.
- CanvasGroupChanged
- RectTransformDimensionsChange
- RectTransformRemoved
This component observes Camera events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- BecomeVisible
- BecomeInvisible
This component observes Particle events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- ParticleCollision
- ParticleTrigger
This component observes Mouse events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- MouseDown
- MouseUp
- MouseUpAsButton
- MouseEnter
- MouseExit
- MouseOver
- MouseDrag
Note: Do not notify on mobile platforms.
This component observes PhysicsCollision events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- CollisionEnter
- CollisionExit
- CollisionStay
This component observes PhysicsCollision2D events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- CollisionEnter2D
- CollisionExit2D
- CollisionStay2D
This component observes PhysicsTrigger events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- TriggerEnter
- TriggerExit
- TriggerStay
This component observes PhysicsTrigger2D events.
If you do not specify instance of Component
will be used self instance.
Component supports below events to observe.
- TriggerEnter2D
- TriggerExit2D
- TriggerStay2D
This component will control activation of GameObject
and MonoBehaviour
.
Invoke GameObject.SetActive(bool)
if TargetGameObjects
field specified.
Change MonoBehaviour.enabled
field if TargetMonoBaheviours
field specified.
This component will destroy instances.
This component will control SimpleAnimation components.
This component will observe event that triggered from SimpleAnimation components.
This component will fire Animator.SetTrigger()
.
If you do not specify instance of Animator
will be obtained by GetComponent<Animator>()
Note: Currently, parameter invocation such as SetInt()
is not supported.
This component observes AnimationEvent firing.
To receive AnimationEvent, Component needs to be attached to the same GameObject as Animator.
This component will fire AudioSource.Xxx()
.
If you do not specify instance of AudioSource
will be obtained by GetComponent<AudioSource>()
Supported methods are listed below.
- Play
- Stop
- Pause
- UnPause
This component observes state changes of AudioSource.
If you do not specify instance of AudioSource
will be obtained by GetComponent<AudioSource>()
Supported events are listed below.
- Play
- Stop
- Pause
- UnPause
- Loop
This component will fire PlayableDirector.Play()
.
If you do not specify instance of PlayableDirector
will be obtained by GetComponent<PlayableDirector>()
This component observes Timeline Signals emission.
Specify TimelineSignal.Dispatch()
in the destination method of the UnityEngine.Timeline.SignalReceiver
component
This component controls some Raycaster such as PhysicsRaycaster
, Physics2DRaycaster
and GraphicRaycaster
.
This component controls raycastTarget such as Collider.enabled
, Graphic.raycastTarget
.
This component changes parent transform.
This component will load scene specified as string.
This component will load scene specified as enum.
This component will unload scene specified as string.
This component will unload scene specified as enum.
This component observes time specified by inspector.
This component observes interval specified by inspector.
This component nothing to observing and firing.
- OtoLogic (https://otologic.jp) (CC BY 4.0)
Assets/Tests/Runtime/Sounds/TimeReport.mp3