Skip to content
This repository has been archived by the owner on Jul 27, 2021. It is now read-only.

Latest commit

 

History

History
41 lines (29 loc) · 2.6 KB

README.md

File metadata and controls

41 lines (29 loc) · 2.6 KB

Twitch Vs Minecraft

Build status CurseForge

A Minecraft mod for Forge 1.12.2 inspired by Kaze Emanuar and CrowdControl that lets Twitch viewers interact with the game to provide a fun challenge for streamers.

View the project on CurseForge for more info!

See the documentation if you are making modifications to the code.

How it works

This mod integrates PircBotX, a Java IRC API. It uses PircBotX to connect to Twitch's IRC server and read a Twitch channel's chat. Every time a new chat message is recieved that isn't blacklisted and starts with the chosen prefix, it is added to a list. Every 30 seconds (this can be changed), a random message from the list is chosen, and if it's a valid command, e.g. "!creeper", the list of new chat messages will be cleared, the timer will restart and the command will be executed. A list of commands is available on the CurseForge page.

Twitch OAuth key

As stated on CurseForge, you will need a Twitch OAuth key. You can get this here.

You should keep this key private and safe. This key is stored in the mod's config file - DO NOT share this file with others!

Follow the instructions on the TwitchApps page for how to revoke access to the Twitch API if you want to stay extra safe.

Getting started

To setup a modding workspace using eclipse, use

./gradlew setupDecompWorkspace

If you're using IntelliJ IDEA, choose "import project" from the main screen and import the mod's build.gradle file. You are then able to run setupDecompWorkspace from the Gradle tab on the right of the screen, or from a terminal. Use this command to generate run configurations:

./gradlew genIntellijRuns

When moving over to IDEA from Eclipse, follow the above steps and then run cleanEclipse from the Gradle tab to remove all of Eclipse's files.

Building from source

To build the project using a terminal, type

./gradlew build

Or find it in the Gradle tab in IDEA.

The build will be located in the build/libs folder, alongside the "sources" file. The sources file is not a mod!