Connecting multiple services together like Twitch and Minecraft can be a tricky endeavour. Luckily, Stream Hydra makes this effortless to integrate with only a few clicks, and it’s FREE! So what is Stream Hydra? It’s an automation platform designed for streamers to connect many different platforms together to perform useful functions to streamers. Simply drag-and-drop “nodes” together to form applets and these will run whenever a certain trigger happens. Let’s take a look at how to setup a Minecraft mob spawning applet that will trigger whenever your viewers on Twitch redeem channel point rewards automatically. This functionality is only available to Twitch streamers who are at least affiliate and have unlocked the use of channel point rewards.
Setting up your account #
1. Firstly, if you haven’t already, sign in or create an account with Stream Hydra – It’s Free!
2. Since Stream Hydra connects services together, you’ll need to enable the services you want to use in the “Modules” page. For spawning mobs in Minecraft from Twitch channel points, we’re going to need to enable to Twitch and Minecraft Modules. Simply click Enable and follow the on-screen instructions to login to your accounts.
Adding the Applet #
3. Now that we have the required modules enabled, we can start to build our applet! To save time, the Stream Hydra team have already made an applet for this, and you can find this in the “Templates” section.
3. Find the template labelled “Channel Point Mob Spawns” and click “Use Template”. This will copy the template into a new applet on your account so you can make all the changes you need.
4. Here you can see all of the available options to configure for this applet. At the top you can see the “Main” section which contains general settings such as targeting a specific player, spawn amount and radius, or the minecraft server to spawn them on. As you can see in the screenshot, no Minecraft servers have been setup yet. We need to go and configure this to enable mob spawning on your server. On the left navigation bar, click “Servers” under “Minecraft Module”
Connecting your Minecraft Server #
5. Here we can setup and configure multiple Minecraft servers so you can pick and choose which applets control which servers. For now, we’re going to click “Register Server” to start setting up our own.
Give your server a name and follow the instructions to download and setup the Spigot plugin on your Minecraft server. If you don’t know how to do this, check out this guide.
Once your Minecraft server is up and running, type the command you saw in the setup screen to connect your server to Stream Hydra
Now that your server is connected, it’s time to start configuring your applet.
Configuring your Applet #
6. Head back to your applet, by clicking “Applets” on the left navigation bar, and then “Edit” under the applet name “Channel Point Mob Spawns”. You’ll now see a drop-down list under “Minecraft Server” in the Main settings. Select your Minecraft Server and hit “Save”
7. Now you can configure all the other options to your hearts content. Below the Main Settings, you’ll see a grid layout of many different mobs you can spawn in Minecraft. Click “Enable” on the channel point rewards you want to use and set a price for them. For example, we’ll enable spawning Zombies for a price of 100 channel points. Once your done, don’t forgot to hit “Save”
8. Once your ready to use the applet, hit “Close” and then “Enable” and you should now see on your Twitch channel that whatever mobs you enabled in the applet have been added as custom rewards on your channel! If you want to remove the rewards, simply “Disable” the applet and these rewards will be removed for you.
9. If you are having issues with anything or have questions about this guide, please feel to free to reach out to us on any platform and we’d be happy to help you!
Advanced – So what does this applet actually do? #
If you want to find out more about the inner workings of this applet then this section is for you. At this stage you should have a fully working applet that will add the rewards when you enable it, spawn mobs when people redeem those rewards, and then remove the rewards when the applet is disabled. To see how this applet works, from the config page click “Open Editor”.
This page can look daunting if you haven’t seen it before. Essentially you have a list of “nodes” on the left that are either triggers, actions or core nodes. You can drag these into the editor and connect them together to perform various functions, and putting them all together forms the applet. This applet has 3 parts to it: “On Enable”, “On Channel Point Redeem” and “On Disable”.
On Enable #
When the applet is enabled, we want to (depending on the options in the config file) ask Twitch to create certain rewards with the parameters we specified. When the applet makes the “Create Reward” call, Twitch returns an ID for that reward so that we can track it’s redemptions later on. We need to store this ID using the “Store Data” node so that we can load this ID in other areas of the Applet. You can double-click any of the nodes to see specific data getting passed through, however in this applet most data is dynamically loaded from the global variables list which you configured earlier in the config file.
On Channel Point Redeem #
When a viewer redeems one of the created rewards with their channel points, we want to capture that information to be used in the applet. Firstly, the applet loads the ID of the reward that we stored earlier. If it matches to a mob that was enabled in the config file then it proceeds with calling “Minecraft Spawn Mobs” and “Minecraft Send Chat”. Double-click any of the nodes to see what data is getting passed but again, this is usually all dynamically loaded from the config file.
On Disable #
Finally, when you disable the applet, we want to clean up the rewards that we created in Twitch. The applet checks which mobs you enabled to know which rewards were created, loads the ID of those rewards and calls “Delete Channel Point Reward” for each of them. That way, no residual data is left behind and the applet can be enabled/disable as many times as you like without causing any issues.
That’s it! There are endless possibilities with the applets you can create. We can’t wait to see how you use it for your stream! As always, if you have any questions please feel free to reach out and we’ll be happy to help you.