PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI Class Reference

Implements IBarkUI using TextMeshPro. More...

Inheritance diagram for PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI:
Collaboration diagram for PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI:

Public Member Functions

void Awake ()
 
void Start ()
 
void Update ()
 Updates the seconds left and hides the label if time is up. More...
 
void Bark (Subtitle subtitle)
 Barks the specified subtitle. More...
 
void OnBarkEnd (Transform actor)
 
void Show ()
 
void Hide ()
 Hides the currently-playing bark. More...
 

Public Attributes

TMPro.TextMeshPro textMeshPro
 The TextMeshPro to use. More...
 
TMPro.TextMeshProUGUI textMeshProUGUI
 The TextMeshPro to use. More...
 
RectTransform panel
 
bool includeName = false
 Set true to include the barker's name in the text. More...
 
float duration = 5f
 The duration in seconds to show the bark text before fading it out. More...
 
bool waitUntilSequenceEnds
 Set true to keep the bark text onscreen until the sequence ends. More...
 
bool checkIfPlayerVisible = true
 Set true to run a raycast to the player. More...
 
LayerMask visibilityLayerMask = 1
 The layer mask to use when checking for player visibility. More...
 

Properties

bool IsPlaying [get]
 Indicates whether a bark is playing or not. More...
 
- Properties inherited from PixelCrushers.DialogueSystem.IBarkUI
bool IsPlaying [get]
 Indicates or sets whether a bark is playing. More...
 

Events

BarkUIDelegate ShowedBark = delegate { }
 Occurs when showing a bark. More...
 
BarkUIDelegate HidBark = delegate { }
 Occurs when hiding a bark. More...
 

Detailed Description

Implements IBarkUI using TextMeshPro.

To use this component, add it to a character. If the character has more than one TextMeshPro in its hierarchy, manually assign the Text Mesh Pro field with the correct one.

Member Function Documentation

◆ Awake()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Awake ( )

◆ Bark()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Bark ( Subtitle  subtitle)

Barks the specified subtitle.

Parameters
subtitleSubtitle to bark.

Implements PixelCrushers.DialogueSystem.IBarkUI.

◆ Hide()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Hide ( )

Hides the currently-playing bark.

Implements PixelCrushers.DialogueSystem.IBarkUI.

◆ OnBarkEnd()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.OnBarkEnd ( Transform  actor)

◆ Show()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Show ( )

◆ Start()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Start ( )

◆ Update()

void PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.Update ( )

Updates the seconds left and hides the label if time is up.

Member Data Documentation

◆ checkIfPlayerVisible

bool PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.checkIfPlayerVisible = true

Set true to run a raycast to the player.

If the ray is blocked (e.g., a wall blocks visibility to the player), don't show the bark.

◆ duration

float PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.duration = 5f

The duration in seconds to show the bark text before fading it out.

◆ includeName

bool PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.includeName = false

Set true to include the barker's name in the text.

◆ panel

RectTransform PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.panel

◆ textMeshPro

TMPro.TextMeshPro PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.textMeshPro

The TextMeshPro to use.

◆ textMeshProUGUI

TMPro.TextMeshProUGUI PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.textMeshProUGUI

The TextMeshPro to use.

◆ visibilityLayerMask

LayerMask PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.visibilityLayerMask = 1

The layer mask to use when checking for player visibility.

◆ waitUntilSequenceEnds

bool PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.waitUntilSequenceEnds

Set true to keep the bark text onscreen until the sequence ends.

Property Documentation

◆ IsPlaying

bool PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.IsPlaying
get

Indicates whether a bark is playing or not.

true if this instance is playing; otherwise, false.

Event Documentation

◆ HidBark

BarkUIDelegate PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.HidBark = delegate { }

Occurs when hiding a bark.

You can hook in to run a coroutine to do something special with the TextMeshPro.

◆ ShowedBark

BarkUIDelegate PixelCrushers.DialogueSystem.TextMeshPro.TextMeshProBarkUI.ShowedBark = delegate { }

Occurs when showing a bark.

You can hook in to run a coroutine to do something special with the TextMeshPro.


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