2D Toolkit Bark UI

2D Toolkit Bark UI Component

The TK2D Bark UI component uses 2D Toolkit to display text above the NPC's head. Follow these instructions to set up 2D Toolkit barks:

  1. Add a tk2dTextMesh to a child object of the actor. Name it, for example, "Bark Text Mesh".
    • Position it above the actor's head [e.g., at (0,2,0)].
    • Set Max Chars to the maximum length of bark text that the actor will say.
    • Set the Anchor to Middle Center.
    • Click HFlip to flip the text horizontally.
    • Select Window > Dialogue System > Components > Example > Always Face Camera if you want the bark text to always face the camera.
    • Optionally add a fader (Window > Dialogue System > Components > UI > 2D Toolkit > Fader) if you want barks to fade in and out.
  2. Add a TK2DBark UI to the actor (Window > Dialogue System > Components > UI > 2D Toolkit > Bark UI).
  3. Optionally assign the tk2dTextMesh to the TK2DBark UI. If you don't assign it, the bark UI will automatically look in its children for a tk2dTextMesh; however, this runs the risk of finding the wrong one if you have more than one under the actor's hierarchy.
  4. You can also tick Include Name to include the barker's name in the bark text. Ticking Wait Until Sequence Ends will keep the bark text onscreen until the bark's associated cutscene sequence (if any) is over.

Script reference: PixelCrushers.DialogueSystem.TK2D.TK2DBarkUI


<< 2D Toolkit