Page 1 of 1

Changing conversation field in dialogue entry script

Posted: Wed Oct 02, 2024 3:23 am
by vire7777
Hello

I missed something here
In the box SCRIPT of one of my dialogue entry (for example when the actor is speaking), i know how to change a variable, a quest, an item, etc... field
For this i write for example :
Variable["myboolean"] = false

But i don t know how to reach and modify a Conversation field (for example let s say i would love to change the description of this Conversation during the dialogue entry)
I thought it would be the same
Conversation["myboolean"] = false

But it doesn t work
Can someone know ?
Thanks

Re: Changing conversation field in dialogue entry script

Posted: Wed Oct 02, 2024 8:32 am
by Tony Li
Hi,

At runtime, some conversation data is stored in Lua. This includes the Description field. Conversations are stored by ID. For example, if your conversation ID is 9, then you can set conversation 9's Description like this in a Script field:

Code: Select all

Conversation[0].Description = "This is the new description."
In C#, you can use DialogueLua.GetConversationField() and SetConversationField().