Summary
A
Weaver.Examples.FloatingText
that uses Unity's inbuilt UnityEngine.TextMesh
component.
- Assembly
- Weaver
.dll - Namespace
- Weaver
.Examples - Interfaces
- Base Types
-
- MonoBehaviour
- PoolableBehaviour
<FloatingText> - FloatingText
graph BT
Type-->Base0["FloatingText"]
click Base0 "/weaver/api/Weaver.Examples/FloatingText"
Base0-->Base1["PoolableBehaviour<FloatingText>"]
Base1-->Base2["MonoBehaviour"]
Type-.->Interface0["IPoolable"]
click Interface0 "/weaver/api/Weaver/IPoolable"
Type["FloatingTextUnity"]
class Type type-node
Syntax
public sealed class FloatingTextUnity : FloatingText, IPoolable
Properties
Name | Value | Summary |
---|---|---|
Color | Color |
The
UnityEngine.Color of the text. |
LifeTime | float |
The amount of time (in seconds) which this text will be shown for.
Inherited from FloatingText
|
Manager | BillboardManager |
The
Weaver.Examples.BillboardManager that controls the rotation of this text.
Usually that means keeping it facing the camera.
Inherited from FloatingText
|
Progress | float |
The
Weaver.Examples.FloatingText.Timer rescaled to between 0-1 based on the total Weaver.Examples.FloatingText.LifeTime .Inherited from FloatingText
|
Size | float |
The height of the text in world-space.
|
Text | string |
The text string currently being shown.
|
TextMesh | TextMesh |
The component used to display the actual text.
|
Timer | float |
The amount of time since this text was shown.
Inherited from FloatingText
|
Transform | Transform |
The
UnityEngine.Transform of the text.Inherited from FloatingText
|
Methods
Name | Value | Summary |
---|---|---|
InitializeDefaults |
void | |
OnRelease |
void |
Called by the
Weaver.PoolableBehaviour`1.Pool when releasing this component to it.
Removes this text from the Weaver.Examples.FloatingText.Manager , asserts that the UnityEngine.Component.gameObject was
active and deactivates it (unless overridden).
Inherited from FloatingText
|
Reset |
void |
Called by Unity when this component is first added (in Edit Mode) or the "Reset" function is used.
|
Show |
FloatingText |
Creates a simple floating text in front of the camera for a short time (generally for debugging purposes).
static
|
Show |
void |
Calls
Weaver.Examples.FloatingText.Show(System.String,UnityEngine.Vector3,Weaver.Examples.BillboardManager) using Weaver.Examples.BillboardManager.GetMain as
the `manager`.
Inherited from FloatingText
|
Show |
void |
Sets the details of this text and activates its
UnityEngine.GameObject .
Inherited from FloatingText
|
Update |
void |
Called once per frame by Unity.
Updates the
Weaver.Examples.FloatingText.Timer and checks if it has exceeded the Weaver.Examples.FloatingText.LifeTime .
If so, this text is returned to its Weaver.ObjectPool`1 if it was created by one, otherwise this
text is destroyed.
Inherited from FloatingText
|