[Solved] Dialogue continue

I have created a dialogue in which every time the player presses Space, it modifies the text. The problem is that when I press space, it skips to the last text that should be modified. Adding trigger once did not affect the outcome.

What can I do to fix this?

Add another trigger once? :sweat_smile:
Can you show us the events? Sometimes, it’s a problem of syntax, structure, spelling…


I’m a complete newbie, so I am really confused and frustrated when it comes to events

Ok.
What GDevelop does when you run a game is to read line by line the events sheet, and if the conditions are met, it executes the actions next to them. When all the sheet has been read, a game frame (one image/screenshot of the game) is built. And it does that 60 times per second to build the game.
So when you press Space, GD reads the events sheet, and finds that the condition of all these lines is met, because space is pressed, so it executes all of them in order and you end up with the last line.
So you need more strict conditions. You could check the value of a variable called… CurrentMessage, for instance. And each time you display a message, you’ll need to add 1 to that variable.
You will also need to replace “is pressed” by “is released”, because GD reads the events sheet 60 times per second or more, so even if you think you are not holding the key, you will hold it for at least a few cycles and you will end up with the last message.

If you have a lot of dialogues, GD has a brand new dialogue system called “yarn”.

1 Like

Alright I’ll try that, thank you

FINALLY!
I figured it out now, pressing space changes the text. And when space is released, it adds 1 to the variable without changing the text. Thank you for your support my man.

2 Likes