Text Juicer for Text Mesh PRO Is a plugin to allow you do "per-character-animation" on text fields, like this one:
This git is a ready to be used as sub-module, so just add to your project anywhere inside the Assets Folder, something like Assets/Text Juicer/
If you don't know how to add as a sub-module you can check this guide
Basically you can access and change the progress of the animation by the animator itself, or using the helpers inside the TextAnimation, by simply caling, Play()
, Stop()
and Restart()
Is quite simple, you just need to extend the TextJuicerVertexModifier
[RequireComponent(typeof(TMP_TextJuicer))]
public abstract class TextJuicerVertexModifier : MonoBehaviour
{
private TMP_TextJuicer cachedTextJuicer;
public abstract bool ModifyGeometry { get; }
public abstract bool ModifyVertex { get; }
protected TMP_TextJuicer TextJuicer
{
get
{
if (cachedTextJuicer == null)
cachedTextJuicer = GetComponent<TMP_TextJuicer>();
return cachedTextJuicer;
}
}
private void OnValidate()
{
TextJuicer.SetDirty();
}
public abstract void ModifyCharacter(CharacterData characterData, TMP_Text textComponent,
TMP_TextInfo textInfo,
float progress,
TMP_MeshInfo[] meshInfo);
}
Current Effects:
- Transform Modifier (Position / Scale / Rotation)
- Color Modifier
- Gradient Modifier
- Color Modifier
- Warp Modifier
Inspired in this post from reddit, and the awesome ui-extensions