Yet another (linear) dialogue system/addon/plugin for Godot. With features such as:
- ✍️ Written in human-readable syntax.
- 😐 ....
- 📝 And 100% written in GDScript!
Rendered | Written |
Dia:
"Welcome! {d=0.8}to the
[fx1]Theatre[/fx1]!
d=0.9
yet another text-based dialogue addon
d=0.3
developed for Godot {gd_ver}."
\(^ ▽ ^) |
Important
This project is still in development, and is subject to frequent, breaking changes, and bugs.
Warning
Currently, this addon is compatible only with Godot 4.3
. It will not function with earlier versions, and while it may run on 4.4
, some features might not work as intended.
Fine-tune your dialogue flow with {delay}
and {speed}
.
Godette:
"Hello!{delay = 0.7} Nice to meet you."
Godette:
"Hello!
delay=0.7
Nice to meet you."
Connect your story to the game with function calls.
{player_name}:
"Thanks! That feels so much better."
Player.heal(20)
Ritsu:
"Cheers!"
Portrait.set("ritsu_smile.png")
Call functions only at specific points in the Dialogue.
Dia:
"Let's brighten up the room a little...{d = 1.1}
{0}
there we go."
# Call this function using its index: {0}
Background.set_brightness(1.0)
More comprehensive Dialogue features documented here.
Write your epic Dialogue!
# Write it directly with triple quotation marks.
var epic_dialogue = Dialogue.new("""
Dia:
"Loading the Dialogue, written in a *.dlg file
is much better for performance."
:
"It'll keep things clean and efficient."
:
"Plus, you’ll have syntax highlighting
for better readibility."
""")
# Write it in a *.dlg file, and load it.
# (Just use this, for the reason explained above.)
var epic_dialogue = Dialogue.load("res:https://epic_dialogue.dlg")
Set the Stage! Add Stage
and DialogueLabel
node to your scene. Structure your scene like the following:
Adjust the position and size of the PanelContainer
to your liking.
Select the Stage
node, and reference the Label
& DialogueLabel
node to display your Dialogue. Adjust and configure your Stage
via the inspector. Alternatively, you can also set them in script:
Reference the Stage
node in the script, and set up a way to progress your Dialogue with Stage.progress()
.
func _input(event):
if event.is_action_pressed("ui_accept"):
my_stage.progress()
And finally, start the Stage
with your epic_dialogue
.
func _ready():
my_stage.start(epic_dialogue)
More detailed quick start tutorial here.
- Theatre is licensed under MIT.
- Theatre logo, created by nnda, is licensed under CC-BY 4.0.
- Class icons from @fontawesome (recolored), are licensed under CC-BY 4.0.