Fly Up Text
Last updated
Last updated
Presented by FlyUpText class, it makes gameobject with attached Text/TMP_Text/TextMesh component move up with certain speed and disappear after certain amount of time. This movement automatically begins when its gameobject becomes active on scene.
This component is inherited from IPooledObject interface, so it can be pooled via Pool System. Also, when it ends flying, it automatically returns to pool.
Lifetime – how much time this object will fly before disappearance (in seconds)
Floating Speed – movement speed (should be set in pixels per second in case if its Canvas UI element, where Canvas is not in World Space, otherwise – it should be set in world units per second)
Curved – if set to true, object will fly up by curved trajectory, otherwise it will just move along Fly Direction
Fly Direction – direction of object movement (Vector3.up by default)
Curve Direction – direction of curvature (Vector3.right by default); sign of direction is not important, so Vector3.right will give the same result as Vector3.left.
This method sets Curved parameter value. If set to true, object will fly up by curved trajectory, otherwise it will just move along Fly Direction.
This method sets text color.
This method sets text string.