Can a nametag command have a text variable in Yarn's <nametag> command?

I want to use nametags for Yarn, the question i face is that, can a nametag be a text variable? if so, how can i set it up and use i,t including in yarn(if required).

You need a bbtext object for your nametag

image

Put it where you want it in your scene

image

Invoke a Yarn command with an event like this

In your dialogue you want the name of the Yarn command and the name you want to appear in the bbtext object

image

You get this when you run your game

image

Your dialogue might look something like this

image

image

image

The dialogue would need to be in its own bbtext box, not the same one as the nametag.

image

You could give the string “Fred” to a Yarn variable and do something with that string back in GDevelop, but I haven’t tried that.

2 Likes