Hello.
I have two questions.
1. I would like to treat the response that I selected at least once during the conversation with gray text. Is there a way to identify the response the player has chosen? If the feature is not provided, you want to save and implement an identifier for each response raised by the user. What is the unique ID of response to use as an identifier?
2. If the speaker changes during conversation, I want to put the enter key effect between texts. I think you can see that the Speaker has changed through Subtitle Class in the OnConversionLine function of StandardDialougeUI. Then I don't know where to approach after that and add '\n' or the appropriate rich text. TMP Text is in use.
I always appreciate the help you provide.
Best Regards.
I have two questions in Dialogue Panel.
Re: I have two questions in Dialogue Panel.
Hi,
Then set the corresponding Emphasis Setting (em#) to be gray:
Tick the Dialogue Manager GameObject's Display Settings > Input Settings > [em#] Tag For Old Responses:fbthd1234 wrote: ↑Sun Aug 20, 2023 4:26 am1. I would like to treat the response that I selected at least once during the conversation with gray text. Is there a way to identify the response the player has chosen? If the feature is not provided, you want to save and implement an identifier for each response raised by the user. What is the unique ID of response to use as an identifier?
Then set the corresponding Emphasis Setting (em#) to be gray:
You can add it to subtitle.formattedText.text:fbthd1234 wrote: ↑Sun Aug 20, 2023 4:26 am2. If the speaker changes during conversation, I want to put the enter key effect between texts. I think you can see that the Speaker has changed through Subtitle Class in the OnConversionLine function of StandardDialougeUI. Then I don't know where to approach after that and add '\n' or the appropriate rich text. TMP Text is in use.
Code: Select all
private int currentSpeakerID;
void OnConversationStart(Transform actor) { currentSpeakerID = -1; } // Reset.
void OnConversationLine(Subtitle subtitle)
{
var text = subtitle.formattedText.text;
if (string.IsNullOrEmpty(text)) return;
if (subtitle.speakerInfo.id != currentSpeakerID)
{
currentSpeakerID = subtitle.speakerInfo.if;
subtitle.formattedText.text = $"{text}\n";
}
}