Highroad Engine v1.3
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
MoreMountains.Tools.MMFloatingTextMeshPro Class Reference

A floating text variant using TextMeshPro instead of regular TextMesh More...

Inheritance diagram for MoreMountains.Tools.MMFloatingTextMeshPro:
MoreMountains.Tools.MMFloatingText

Public Member Functions

override void SetText (string newValue)
 Sets the TMP's value More...
 
override void SetColor (Color newColor)
 Sets the color of the target TMP More...
 
override void SetOpacity (float newOpacity)
 Sets the opacity of the target TMP More...
 
- Public Member Functions inherited from MoreMountains.Tools.MMFloatingText
virtual float GetTime ()
 
virtual float GetDeltaTime ()
 
virtual void SetUseUnscaledTime (bool status, bool resetStartedAt)
 Changes whether or not this floating text should use unscaled time More...
 
virtual void SetProperties (string value, float lifetime, Vector3 direction, bool animateMovement, MMFloatingTextSpawner.AlignmentModes alignmentMode, Vector3 fixedAlignment, bool alwaysFaceCamera, Camera targetCamera, bool animateX, AnimationCurve animateXCurve, float remapXZero, float remapXOne, bool animateY, AnimationCurve animateYCurve, float remapYZero, float remapYOne, bool animateZ, AnimationCurve animateZCurve, float remapZZero, float remapZOne, bool animateOpacity, AnimationCurve animateOpacityCurve, float remapOpacityZero, float remapOpacityOne, bool animateScale, AnimationCurve animateScaleCurve, float remapScaleZero, float remapScaleOne, bool animateColor, Gradient animateColorGradient)
 Called by the spawner, sets all required variables More...
 
virtual void ResetPosition ()
 Resets this text's position More...
 

Public Attributes

TextMeshPro TargetTextMeshPro
 the TextMeshPro object to use to display values More...
 
- Public Attributes inherited from MoreMountains.Tools.MMFloatingText
Transform MovingPart
 the part of the prefab that we'll move More...
 
Transform Billboard
 the part of the prefab that we'll rotate to face the target camera More...
 
TextMesh TargetTextMesh
 the TextMesh used to display the value More...
 
Vector3 Direction = Vector3.up
 the direction of this floating text, used for debug only More...
 

Protected Member Functions

override void Initialization ()
 On init we grab our TMP's color More...
 
- Protected Member Functions inherited from MoreMountains.Tools.MMFloatingText
virtual void OnEnable ()
 On enable, we initialize our floating text More...
 
virtual void Update ()
 On Update we move our text More...
 
virtual void UpdateFloatingText ()
 Handles the text's life cycle, movement, scale, color, opacity, alignment and billboard More...
 
virtual void HandleMovement ()
 Moves the text along the specified curves More...
 
virtual void HandleColor ()
 Animates the text's color over the specified gradient More...
 
virtual void HandleOpacity ()
 Animates the text's opacity over the specified curve More...
 
virtual void HandleScale ()
 Animates the text's scale over the specified curve More...
 
virtual void HandleAlignment ()
 Handles text rotation to match either a fixed alignment, the initial direction or the movement's direction More...
 
virtual void HandleBillboard ()
 Forces the text to face the camera More...
 
virtual void TurnOff ()
 Turns of the text for recycling More...
 

Additional Inherited Members

- Protected Attributes inherited from MoreMountains.Tools.MMFloatingText
bool _useUnscaledTime = false
 
float _startedAt
 
float _lifetime
 
Vector3 _newPosition
 
Color _initialTextColor
 
bool _animateMovement
 
bool _animateX
 
AnimationCurve _animateXCurve
 
float _remapXZero
 
float _remapXOne
 
bool _animateY
 
AnimationCurve _animateYCurve
 
float _remapYZero
 
float _remapYOne
 
bool _animateZ
 
AnimationCurve _animateZCurve
 
float _remapZZero
 
float _remapZOne
 
MMFloatingTextSpawner.AlignmentModes _alignmentMode
 
Vector3 _fixedAlignment
 
Vector3 _movementDirection
 
Vector3 _movingPartPositionLastFrame
 
bool _alwaysFaceCamera
 
Camera _targetCamera
 
Quaternion _targetCameraRotation
 
bool _animateOpacity
 
AnimationCurve _animateOpacityCurve
 
float _remapOpacityZero
 
float _remapOpacityOne
 
bool _animateScale
 
AnimationCurve _animateScaleCurve
 
float _remapScaleZero
 
float _remapScaleOne
 
bool _animateColor
 
Gradient _animateColorGradient
 
Vector3 _newScale
 
Color _newColor
 
float _elapsedTime
 
float _remappedTime
 

Detailed Description

A floating text variant using TextMeshPro instead of regular TextMesh

Member Function Documentation

◆ Initialization()

override void MoreMountains.Tools.MMFloatingTextMeshPro.Initialization ( )
protectedvirtual

On init we grab our TMP's color

Reimplemented from MoreMountains.Tools.MMFloatingText.

◆ SetColor()

override void MoreMountains.Tools.MMFloatingTextMeshPro.SetColor ( Color  newColor)
virtual

Sets the color of the target TMP

Parameters
newColor

Reimplemented from MoreMountains.Tools.MMFloatingText.

◆ SetOpacity()

override void MoreMountains.Tools.MMFloatingTextMeshPro.SetOpacity ( float  newOpacity)
virtual

Sets the opacity of the target TMP

Parameters
newOpacity

Reimplemented from MoreMountains.Tools.MMFloatingText.

◆ SetText()

override void MoreMountains.Tools.MMFloatingTextMeshPro.SetText ( string  newValue)
virtual

Sets the TMP's value

Parameters
newValue

Reimplemented from MoreMountains.Tools.MMFloatingText.

Member Data Documentation

◆ TargetTextMeshPro

TextMeshPro MoreMountains.Tools.MMFloatingTextMeshPro.TargetTextMeshPro

the TextMeshPro object to use to display values


The documentation for this class was generated from the following file: