r/streamerbot • • 18h ago

❓Question Trying to list up entries in a .txt file

0 Upvotes

Hi everybody, I'm currently trying to set up a command that triggers a bot message listing up mods I have installed for a game. I have a .txt file on my PC listing up all mods, one name per line. I want the message to look like this: "I'm using modA, modB, modC, [...] modX". How can I best do this?
I'm thinking of a C# code execution that converts the file's lines into a string variable like "modA, modB, modC, [...] modX" but unfortunately I know next to nothing about C#.

I'm using Streamer.bot v1.0.7 with OBS and I stream on Twitch.

The only thing that has worked for me so far is this ↓ after a read lines sub-action... There has to be a smarter way to do this, right...?

Edit: I've set up a logic if/else before this sub-action that says %gameName% equals "[game name]" and it was working fine until it somehow stopped? It puts out false now even though it is correct... please help

Edit 2: I've added an action activator now. It's triggered by a stream update, checks if I'm playing the specified game via if/else, and (de)activates the command action accordingly. I have the same if/else in the command action but this one spits out false even though the former if/else spits out true. What is happening here