Answers for "TypeWriter Text Godot"

Go
0

TypeWriter Text Godot

extends RichTextLabel

onready var Timer = get_node("/root/Node2D/Timer")

onready var stringPrinted = "This is a test"

func _ready():
    Timer.set_wait_time(.1) # time between letters
    _dialogue( stringPrinted )

func _dialogue( string ):
    for letter in string:
        Timer.start()
        self.add_text( letter )
        yield(Timer, "timeout")
Posted by: Guest on August-26-2020

Browse Popular Code Answers by Language