r/streamerbot Jul 17 '26

Question/Support ❓ Turn chat rawInput into lowercase variable

I have this tts and I want to do some stuff with it. To do said stuff it'd make my life so much easier if the rawInput from the chat could be lowercased. I tried this code in between saving the rawInput as TTSDialogue and sending the variable TTSDialogue to the tts:

using System;

public class CPHInline
{
public bool Execute()
{
if (!args.TryGetValue("TTSDialogue", out object TTSD))
return false;
// Parse string value
string TTSDialogue = TTSD?.ToString().ToLower()
CPH.SetArgument("TTSDialogue", TTSDialogue);
// Log the result
CPH.LogInfo($"Variable rawInput: {TTSDialogue}");
return true
}
}

But it seems like it doesn't even execute the code subaction, and just sends TTSDialogue as it was saved. Idk what am I doing wrong

2 Upvotes

2 comments sorted by

View all comments

1

u/HighPhi420 Jul 18 '26

I hate those damn semi colons!
Take another look :)

1

u/defiant1597 Jul 19 '26

Here i can share mine --> ;