Twitch Chat Integration (Twitch Plays MV) v.0.9.0

Jiffy

Veteran
Veteran
Joined
Jan 30, 2017
Messages
110
Reaction score
125
First Language
English
Primarily Uses
N/A
Untitled.png
Ever wanted to let your toxic twitch chat control your RPG Maker game?
If you answered yes, you're insane, but that's ok.

Introducing JIF_TwitchChatIntegration. This plugin cofunctions with a Twitch bot that reads inputs from Twitch chat, allowing your chat to control your game.


This is mostly a proof of concept but is technically fully functional (just a pain to get working). It is very messy and could definitely be done better, but honestly, I don't see a lot of people utilizing this to justify me completely cleaning it up.

This plugin is free for commercial use (why you would do that I don't know), just credit me. If you do a stream of this DM me! I'd love to see it in use in a chat other than mine ;)

Untitled2.png
This plugin is not for beginners to basic js, it's installation process is kinda difficult and requires knowledge on installing nodejs and making very basic edits to a js file.

There's a good chance this will become a lot more streamlined in the future.

STEP ONE: INSTALLING THE PLUGIN AND BOT
This first step is easy, just download both the EXTRACT ME.zip and the plugin file. Put the plugin in your js/plugins folder and install it via the plugin manager. Set the "enabled" plugin param to true.

STEP TWO: INSTALLING NODE JS
- Download node js from here.
- Open the TwitchChatBot file in your choice of IDE (I use Visual Studio Code). Install tmi JS through the terminal (just type this in your terminal):
Code:
npm install tmi.js
STEP THREE: CREATE JIF_twitch.txt
Navigate to your MV projects data folder and create a new txt file titled "JIF_twitch.txt" (case sensitive). The only contents of the file should be an open and closed bracket:
Code:
[]
Now you want to copy the exact location of the txt file. You can do this by:
- Right-clicking the txt file
- Hitting properties
- Copying everything next to the "Location:" section
1578889326673.png

STEP FOUR: CHANGE THE FILE LOCATION IN THE "index.js" FILE IN THE TWITCH CHAT BOT AND PLUGIN
On lines 70, 79, 85, and 83 of the bots index.js, you will notice some file paths, replace these with the one you copied from earlier, and double up the "/".
For example:
C:\Users\Jacob\Documents\ProgrammingFiles\MV Plugins\twitchchat\data\JIF_twitch.txt
becomes
C:\\Users\\Jacob\\Documents\\ProgrammingFiles\\MV Plugins\\twitchchat\\data\\JIF_twitch.txt

Now on lines 40 and 68, do the exact same thing.

STEP FIVE: HOOKUP THE BOT TO YOUR TWITCH ACCOUNT
This is by far the most annoying part.
- Create a new twitch account that will act as your bot.
- Put the account username in the quotation marks on line 16 of the index.js file
- Get your OAuth string.
Here is an easy way to get it.

- Now put the twitch account's username whose chat you want to control your game in the single quotes on lines 19 and 22.

STEP SIX: RUN THE BOT AND ENJOY
At long last, the installation is done. Open your terminal and type
Code:
node index.js
Now, you can properly control the game using the following controls:
!mv up
!mv down
!mv right
!mv left
!mv z
!mv x
!mv start

If you have any problems when installing this, please let me know. It was only tested on my machine so I very well could have left something important out.

Untitled3.png
BOTH ARE REQUIRED FOR THIS PLUGIN TO FUNCTION


[Click Here]
 

Kes

Global Moderators
Global Mod
Joined
Aug 3, 2012
Messages
21,612
Reaction score
10,925
First Language
English
Primarily Uses
RMVXA
@Jiffy As this is version 0.9, does that mean that it is still under development? If it is, then it needs to be moved to a different section.
 

Jiffy

Veteran
Veteran
Joined
Jan 30, 2017
Messages
110
Reaction score
125
First Language
English
Primarily Uses
N/A
@Kes No it is released and functional, I just want the 1.0 version to be more accessible.
 

Kes

Global Moderators
Global Mod
Joined
Aug 3, 2012
Messages
21,612
Reaction score
10,925
First Language
English
Primarily Uses
RMVXA
Okay, in that case it can stay where it is.
 

decinbr

Villager
Member
Joined
Mar 20, 2015
Messages
20
Reaction score
0
First Language
brazil
Primarily Uses
I tryied install, but did not work. can you make a video tutorial? thanks so much
 

Jiffy

Veteran
Veteran
Joined
Jan 30, 2017
Messages
110
Reaction score
125
First Language
English
Primarily Uses
N/A
@decinbr I don't really have time to make a video tutorial, but I can try to help with any issues you have. Where are you getting hung up?
 

HawkZombie

Lord of Shadow
Veteran
Joined
Jun 9, 2015
Messages
234
Reaction score
294
First Language
English
Primarily Uses
N/A
Ok, this may actually be VERY relevant to my interests. But I'm guessing there isn't exactly a frontend for this where chat can play any game you set up, unless this plugin was installed into the game itself?
 

Jiffy

Veteran
Veteran
Joined
Jan 30, 2017
Messages
110
Reaction score
125
First Language
English
Primarily Uses
N/A
@HawkZombie right, although for your interest i’m sure it would be possible to write a script that does essentially the same thing that instead emulates keyboard inputs. Not in the scope of this project though.
 

HawkZombie

Lord of Shadow
Veteran
Joined
Jun 9, 2015
Messages
234
Reaction score
294
First Language
English
Primarily Uses
N/A
Still, this is pretty cool regardless. I hope you find time to continue it and work more on it.
 

Val

Veteran
Veteran
Joined
Oct 12, 2015
Messages
281
Reaction score
167
First Language
Français
Primarily Uses
Wow that a nice plugin I will try it for sure in the futur, I hope you will continue develop this one. Its as a lot of potential for a lot of game !! I will take some time to think how it can be really fun to useful by a crowd of people really angry to right anything in the game.... thanks :D
 

Jiffy

Veteran
Veteran
Joined
Jan 30, 2017
Messages
110
Reaction score
125
First Language
English
Primarily Uses
N/A
@Val some form of crowd control is certainly in the realm of possibility. My goal rn is to eliminate the need of a separate program for the twitch bot and put everything in the plugin. After that additional features will be much more viable to implement.
 
  • Like
Reactions: Val

TenTranVN

Veteran
Veteran
Joined
Apr 13, 2017
Messages
164
Reaction score
17
First Language
Vietnam
Primarily Uses
RMMV
It would be better to have a tutorial video !!!. But thanks for your contribution
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Stream will be live shortly with some Witcher 3! Feel free to drop by!
This forum is a great source of procrastination for me.
Today I read "The mouth speaks what the heart is full of." Simple, and reminds me I have a ton of work to do.
Why are cats so darn cute when their tongues are sticking out? If I did that, it wouldn't have the same effect.
The joy when you see a notification, the down when it's just a unnecessary quote of one of your posts again.

Forum statistics

Threads
94,399
Messages
920,647
Members
124,184
Latest member
richvolter15
Top