I was watching a Twitch streamer playing Rimworld, their moderators were creating polls through the Strawpoll website, and the viewers were voting on these polls to trigger challenging events for the streamer. However the streamer was using the in-game developer tools to trigger these events and I thought at the time "You could automate this".
That's where the idea came from, a way for viewers to directly influence the narrative of a survival game. Rimworld is a perfect fit, but I think we can do more.
What it does
Our extension in its first release will attempt to achieve the above story, however in a native and automated flow. Moderators (and the Broadcaster) can create a poll, with options selected from a defined list of in-game events. Viewers then vote on their preferred outcome, and the game automatically triggers the winning event. This all occurs within the Twitch ecosystem via our video overlay extension, giving the viewer, moderator and broadcaster a unified experience; Never needing to leave Twitch.
How I built it
Challenges I ran into
I am familiar with JS, Node, and Mongo databases, I have however never made a mod for a game. Rimworld uses C# and I have very limited experience with it. After the initial struggle of debating architecture and designing our authentication flow (How do you link the game itself to a server when it has no idea about the Twitch streamer?), our next challenge was learning how to actually trigger the events in the game.
Luckily we have a well rounded team, and one of our developers (InfinitySamurai) was able to carry the bulk of the weight when it came to C#. Without his expertise this project would have been dead in the water.
Accomplishments that I'm proud of
We designed an authentication system that uses cryptographic keys to link the game mod to our back-end, creating a secure channel of communication between the streamers game instance and our events server. Bringing this together on top of the complexity involved in having so many moving parts was truly an accomplishment for us.
The first time we did an e2e test, and went from creating a poll to voting on options to seeing the item appear in the game was truly astounding!
What I learned
Releasing a Twitch extension is hard work, there are a lot of hoops you have to jump through to pass review, and what initially started as a very simple concept very quickly evolved into something quite complex. We are very glad that we planned far ahead and it has reinforced for us the importance of good design and planning. Don't leave your reviews to the last minute!
What's next for RimConnect
We have so much planned for our extension and we are very excited to make a start, here's a short list of our planned features: Bits! We want to help streamers make more money from their content, so we plan to add the ability for viewers to spend bits to trigger events in the game. Loyalty Points! We want to reward viewers for interacting with our extension and the streamer so we want to allow a system for viewers to earn and spend loyalty points. Event Store! We want the viewers to be able to take full control of the events in the game and directly purchase items/events with their loyalty points. AI Hooking! We want to connect to the games story telling AI, to automatically generate polls to take the weight off the moderators and allow the narrative to still be told in a somewhat natural way.
Finally, we want to keep going with this ideal, we want to bring our concept of Twitch integration to more games, we want to gamify the viewing experience on twitch and implement a system that allows the viewer to actually play with the streamer.