Dialogue Not Working with Yarn System! Please help!

Okay everyone, so I apologize in advance if it’s something obvious that I just can’t tell.

I have been watching tutorial after tutorial about the yarn dialogue system. I have done my best to program what I can-- but nothing seems to work.

Everything else I’ve done with gdevelop, I’ve understood so far, and it makes sense! But nothing with yarn makes sense at All. No matter how hard I work at it.

For example, this is the programming I’ve done- and all it does is make the text box disappear. It seems to refuse to load any of the text from the yarn file. I can’t figure out how to actually load the file into the text box, and this is not the first time I’ve tried this.

I just don’t understand loading the yarn system into the game at all. Please help, I’m very stressed out, and nothing I’ve found on youtube helps in the slightest-- even with the step by step process, it doesn’t click.

Thanks in advance for any help you give!! I want to make this game come to life, and working dialogue is vital for that.

Sorry for the late answer.
How much is your TextScrollSpeed?
Try adding a whichever key release condition to your scrolling complete condition.
Aside from that, it looks okay.
When you’re stuck, change or remove conditions and actions to find the culprit.

Hey no problem! I’ve had time to cool down anyway, I was clearly frustrated when I did my post.

That’s the speed! I got it from watching some tutorials on Youtube.

You’re absolutely right, changing or removing conditions can find the culprit. I guess I’m just so confused by yarn, I am unsure where to begin. It really feels like I’m trying to read a foreign language, so I appreciate your patience on this while I try to figure it out. For example, how can it tell I want it to begin at ‘MomStart’ instead of any other node, if it’s not specified in the text?

0.5 is okay. It’s a global variable, right?


Start from the basics, remove the scrolling and timers and whatnots to make sure that your dialogue and your text object both work.

LOL whoops. Looks like I already set up the branch, ahhaha. Thank you!

And yes, it’s a global variable!

What I’ve decided to do, was jump to a different scene. The text I’m working with in my first example was from a cutscene, so instead, I decided to jump away from the cutscene (with all the complicated behaviors that come with one) so I can focus completely on dialogue.

This is a new scene, with nothing that can interfere with the yarn text and formatting. I am starting as simple as I can, so I can hopefully figure this out and REALLY have yarn ‘click’ for me. I’m afraid I might need this explained as simply as possible until I really ‘get’ what the problem is with my programming.


The text disappears when I press Z, so the text of TextObject does not change to DialogueTree::ClippedLineText(). That seems to be my biggest issue with yarn in both examples.

(Also seriously, thank you SO much for helping with this Gruk. I know for a fact if I can master yarn, it will make dialogue with NPCs and everything SO much better in the long run, then if I do annoying workarounds. This might be frustrating to see, and if so I understand, but it really means the world to have you help. I love making games, and I want to be a good programmer! Anyway I’ll stop. Thanks!)

Just a quick update: When I changed it from clippedlinetext to branch, the text finally showed up for the first time-- all at once. So I’m wondering if ClippedLineText() somehow isn’t registering what I want it to connect to?

clippedlinetext is for scrolling effect, so it displays one single character and then it adds another character each time the scroll action is called.
I tried on my side, and I’m not sure why, but it doesn’t show any character until the first scroll action. :thinking:
Back to your troubleshooting, use clippedlinetext and add a scroll action like before, but without any condition/timer.

Oh-- scrolling, that makes so much sense!!! It’s really starting to click now for me! I’m not sure why I didn’t get it before… maybe because I didn’t understand the scrolling mechanism!

I’ve gone about it like this, and it all works beautifully! Gruk thank you so so much!! There’s still a lot about yarn I don’t quite get yet, but honestly just having the groundwork is all I need to start working and understanding the rest!

Thank you, you’ve saved my hide, and hours of late-game work!

Cool :+1:
So what fixed it? Just adding the key released condition?
Take a look at the Dialogue tree example project to learn about all the features (and find guidance when you’re stuck :wink: )

Both adding a key released condition, and creating a ‘MomDialogue’ scene variable, so it wouldn’t continuously try to begin from Start!

Okay, one true last question! After the dialogue is completely done- no more dialogue lines left, what is your quick suggestion on hiding text/word bubbles?

I’ve looked over the example game with the crumb, but I’m still just a little shy of figuring out this one last hiccup. Thank you again!

There’s an object group called textHud

The red arrows on the left mean the condition is inverted (right-click on it).