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
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:
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
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:
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.
BOTH ARE REQUIRED FOR THIS PLUGIN TO FUNCTION
[Click Here]
本贴来自国际rpgmaker官方论坛作者:Jiffy处,因国际论坛即将永久关站,为了存档多年珍贵资料,署名转载到本论坛存档,由于官方帖子为英文原帖,需要中文翻译请点击论坛顶部切换语言为中文就可以将帖子翻译成中文浏览,方便大家随时查看,原文地址:
https://forums.rpgmakerweb.com/threads/twitch-chat-integration-twitch-plays-mv-v-0-9-0.117201/