simonsays-drgreengiant


Namesimonsays-drgreengiant JSON
Version 2.0.4 PyPI version JSON
download
home_page
SummaryA Twitch Plays style programme to allow users in Twitch chats to control the broadcasters mouse and keyboard
upload_time2023-11-12 16:22:43
maintainer
docs_urlNone
author
requires_python>=3.11.4
license
keywords twitch chat twitchplays troll
VCS
bugtrack_url
requirements Pillow pynput requests semantic-version tomlkit twitchirc_drgreengiant
Travis-CI No Travis.
coveralls test coverage
            # SimonSays

[![CodeQL Vulnerabilities](https://github.com/howroyd/simonsays/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/codeql-analysis.yml)\
[![Bandit Python Vulnerabilities](https://github.com/howroyd/simonsays/actions/workflows/bandit.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/bandit.yml)\
[![Linting and Testing](https://github.com/howroyd/simonsays/actions/workflows/python-testing.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/python-testing.yml)\
[![Build and Release](https://github.com/howroyd/simonsays/actions/workflows/python-publish.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/python-publish.yml)

Taking inspiration from the many other "TwitchPlays" style programmes, including that featured by [DougDoug](#original-file-header-comments), this software has been specifically created to be an easy to use for those non programmers among the gaming community.

Out of the box, this uses a [connection](https://github.com/howroyd/twitchirc) to Twitch chat, in a receive-only mode, to capture messages typed by viewers.  Connections to multiple different chats simultaneously is possible for collaboration streams!

Trigger words must be at the start of a sentence typed in chat and ***do not*** need to be prepended by a `!` like many other bots.  However, you can reconfigure the trigger words however you like.

The beautiful artwork is courtesy of the wonderful **Szinie**.  Please do show appreciation over on her [Twitch channel](https://www.twitch.tv/szinie).

## How To Guide

For basic installation and usage in a video format, I have recorded the below on YouTube:

[![How to guide video](https://img.youtube.com/vi/tYnfSwJiYAY/default.jpg)](https://youtu.be/tYnfSwJiYAY)

The latest release can be found [here](https://github.com/howroyd/simonsays/releases/latest).

## Compatibility

This software talks directly to the operating system *as if* it were a mouse or keyboard plugged into your machine.  It does not modify any game code nor any files on your computer.  It has been tested in Windows and Linux.

The main use case to date has been for Phasmophobia streamers to allow their chat to troll them during gameplay.  Therefore, all the preset actions are Phasmophobia focused at the moment, however, if you would like another game to be considered then please raise a feature request [issue](https://github.com/howroyd/simonsays/issues) and I will look into it!  (Or, if you want to try your hand at programming, feel free to fork or PR this repository!)

### Windows Defender

Windows Defender will likely throw a fit if you download the executable and run it.  This is purely because I have not paid Microsoft for an exemption in Windows Defender.

So you have a few options:

- Disable Windows Defender; Hell no.  Don't do this.  Anyone who tells you to is either an idiot, dangerous or both.
- Go into Windows Defender, look at the history, and allow this, and only this, `exe` that it has blocked.
- ... or, don't use the `exe`; instead run the raw Python (see below)

This code opens connections over the internet, sends and receives data and initiates HID (keyboard and mouse) commands.  It looks exactly like many Trojans which do this nefariously.  It is only you, the human, that can decide whether it is malicious or not.  Hopefully you can see all the information here to inform that decision.  To assist I have added GitHub actions which will show a green tick on the repository if it has passed code analysis scans for security using `CodeQL`.  These scans also happen weekly, so if a vulnerability exists that currently is not known about, becomes known, then that green tick will change to a red cross.  Hopefully, this provides peace of mind even if this software stops being maintained; you can still see whether it is still safe or not.  Furthermore, I do not manually build the executables any more, this is done autonomously by GitHub *only* if the code scans pass at the time of release.

## Contributing and Thanks

This software is provided free of charge under the licence found [here](./LICENSE).  It is kindly requested that if you enjoy using SimonSays then please do promote the links to this so more people can have fun.

It would be fun to extend this to be able to connect to other chat servers such as, YouTube, Kick, etc.  If you're interested in this then please let me know by raising an [issue](https://github.com/howroyd/simonsays/issues).

If you would like to contribute artwork, programming, testing or in any other way, then please do get in touch in any way convenient, preferably [here](https://github.com/howroyd/simonsays/discussions).

No financial reward is expected to use this software, but if it is something you wish to consider then you can either sponsor this project or send a one off donation under [Sponsor this project](https://github.com/howroyd/simonsays).

You can find me on Twitch as [DrGreenGiant](https://www.twitch.tv/drgreengiant) and on [YouTube](https://youtube.com/@SimonHowroyd?si=wsQ0XuGwGjaXB7HU) too.

## Installation

### As an Executable

The latest release can be found [here](https://github.com/howroyd/simonsays/releases/latest).

Other releases are published on GitHub [here](https://github.com/howroyd/simonsays/releases).

Look for the one tagged in green `latest`.  At the bottom of that release you will see a drop-down box called **Assets** which has the `windows_release.zip` and `linux_release.tar.gz`.  Unzip the file to a location of your choice, e.g. your Desktop, and run the contained file.  It will generate a config file so that if you change any keybinding, etc, they will be remembered.

### As a Python Module

Available on PyPi at <https://pypi.org/project/simonsays-drgreengiant/>

```bash
pip install simonsays_drgreengiant
```

## Python Module Usage

If you install this as a Python module, then you can run the software by:

```python
from simonsays_drgreengiant import simonsays

simonsays.main()
```

## Original file header comments

Although this software is a complete re-write of the code that inspired me, I would still love to give credit to the original source code that got me started:

>
> Written by [DougDoug](https://www.twitch.tv/dougdoug) and DDarknut
>
> Hello! This file contains the main logic to process Twitch chat and convert it to game commands.
> The code is written in Python 3.X
> There are 2 other files needed to run this code:
>
> - `TwitchPlays_KeyCodes.py` contains the key codes and functions to press keys in-game. You should not modify this file.
> - `TwitchPlays_Connection.py` is the code that actually connects to Twitch. You should not modify this file.
>
> The source code primarily comes from:
>
> - Wituz's "Twitch Plays" tutorial: <http://www.wituz.com/make-your-own-twitch-plays-stream.html>
> - PythonProgramming's "Python Plays GTA V" tutorial: <https://pythonprogramming.net/direct-input-game-python-plays-gta-v/>
> - DDarknut's message queue and updates to the Twitch networking code
>
> Disclaimer:
>
> - This code is NOT intended to be professionally optimized or organized.
> - We created a simple version that works well for livestreaming, and I'm sharing it for educational purposes.

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "simonsays-drgreengiant",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.11.4",
    "maintainer_email": "",
    "keywords": "twitch,chat,twitchplays,troll",
    "author": "",
    "author_email": "Simon Howroyd <howroydlsu@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/3a/f9/458e9030fb89c9493d280031cc7f9f850f9e235ad0ecb41b97dac1ee0291/simonsays_drgreengiant-2.0.4.tar.gz",
    "platform": null,
    "description": "# SimonSays\n\n[![CodeQL Vulnerabilities](https://github.com/howroyd/simonsays/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/codeql-analysis.yml)\\\n[![Bandit Python Vulnerabilities](https://github.com/howroyd/simonsays/actions/workflows/bandit.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/bandit.yml)\\\n[![Linting and Testing](https://github.com/howroyd/simonsays/actions/workflows/python-testing.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/python-testing.yml)\\\n[![Build and Release](https://github.com/howroyd/simonsays/actions/workflows/python-publish.yml/badge.svg)](https://github.com/howroyd/simonsays/actions/workflows/python-publish.yml)\n\nTaking inspiration from the many other \"TwitchPlays\" style programmes, including that featured by [DougDoug](#original-file-header-comments), this software has been specifically created to be an easy to use for those non programmers among the gaming community.\n\nOut of the box, this uses a [connection](https://github.com/howroyd/twitchirc) to Twitch chat, in a receive-only mode, to capture messages typed by viewers.  Connections to multiple different chats simultaneously is possible for collaboration streams!\n\nTrigger words must be at the start of a sentence typed in chat and ***do not*** need to be prepended by a `!` like many other bots.  However, you can reconfigure the trigger words however you like.\n\nThe beautiful artwork is courtesy of the wonderful **Szinie**.  Please do show appreciation over on her [Twitch channel](https://www.twitch.tv/szinie).\n\n## How To Guide\n\nFor basic installation and usage in a video format, I have recorded the below on YouTube:\n\n[![How to guide video](https://img.youtube.com/vi/tYnfSwJiYAY/default.jpg)](https://youtu.be/tYnfSwJiYAY)\n\nThe latest release can be found [here](https://github.com/howroyd/simonsays/releases/latest).\n\n## Compatibility\n\nThis software talks directly to the operating system *as if* it were a mouse or keyboard plugged into your machine.  It does not modify any game code nor any files on your computer.  It has been tested in Windows and Linux.\n\nThe main use case to date has been for Phasmophobia streamers to allow their chat to troll them during gameplay.  Therefore, all the preset actions are Phasmophobia focused at the moment, however, if you would like another game to be considered then please raise a feature request [issue](https://github.com/howroyd/simonsays/issues) and I will look into it!  (Or, if you want to try your hand at programming, feel free to fork or PR this repository!)\n\n### Windows Defender\n\nWindows Defender will likely throw a fit if you download the executable and run it.  This is purely because I have not paid Microsoft for an exemption in Windows Defender.\n\nSo you have a few options:\n\n- Disable Windows Defender; Hell no.  Don't do this.  Anyone who tells you to is either an idiot, dangerous or both.\n- Go into Windows Defender, look at the history, and allow this, and only this, `exe` that it has blocked.\n- ... or, don't use the `exe`; instead run the raw Python (see below)\n\nThis code opens connections over the internet, sends and receives data and initiates HID (keyboard and mouse) commands.  It looks exactly like many Trojans which do this nefariously.  It is only you, the human, that can decide whether it is malicious or not.  Hopefully you can see all the information here to inform that decision.  To assist I have added GitHub actions which will show a green tick on the repository if it has passed code analysis scans for security using `CodeQL`.  These scans also happen weekly, so if a vulnerability exists that currently is not known about, becomes known, then that green tick will change to a red cross.  Hopefully, this provides peace of mind even if this software stops being maintained; you can still see whether it is still safe or not.  Furthermore, I do not manually build the executables any more, this is done autonomously by GitHub *only* if the code scans pass at the time of release.\n\n## Contributing and Thanks\n\nThis software is provided free of charge under the licence found [here](./LICENSE).  It is kindly requested that if you enjoy using SimonSays then please do promote the links to this so more people can have fun.\n\nIt would be fun to extend this to be able to connect to other chat servers such as, YouTube, Kick, etc.  If you're interested in this then please let me know by raising an [issue](https://github.com/howroyd/simonsays/issues).\n\nIf you would like to contribute artwork, programming, testing or in any other way, then please do get in touch in any way convenient, preferably [here](https://github.com/howroyd/simonsays/discussions).\n\nNo financial reward is expected to use this software, but if it is something you wish to consider then you can either sponsor this project or send a one off donation under [Sponsor this project](https://github.com/howroyd/simonsays).\n\nYou can find me on Twitch as [DrGreenGiant](https://www.twitch.tv/drgreengiant) and on [YouTube](https://youtube.com/@SimonHowroyd?si=wsQ0XuGwGjaXB7HU) too.\n\n## Installation\n\n### As an Executable\n\nThe latest release can be found [here](https://github.com/howroyd/simonsays/releases/latest).\n\nOther releases are published on GitHub [here](https://github.com/howroyd/simonsays/releases).\n\nLook for the one tagged in green `latest`.  At the bottom of that release you will see a drop-down box called **Assets** which has the `windows_release.zip` and `linux_release.tar.gz`.  Unzip the file to a location of your choice, e.g. your Desktop, and run the contained file.  It will generate a config file so that if you change any keybinding, etc, they will be remembered.\n\n### As a Python Module\n\nAvailable on PyPi at <https://pypi.org/project/simonsays-drgreengiant/>\n\n```bash\npip install simonsays_drgreengiant\n```\n\n## Python Module Usage\n\nIf you install this as a Python module, then you can run the software by:\n\n```python\nfrom simonsays_drgreengiant import simonsays\n\nsimonsays.main()\n```\n\n## Original file header comments\n\nAlthough this software is a complete re-write of the code that inspired me, I would still love to give credit to the original source code that got me started:\n\n>\n> Written by [DougDoug](https://www.twitch.tv/dougdoug) and DDarknut\n>\n> Hello! This file contains the main logic to process Twitch chat and convert it to game commands.\n> The code is written in Python 3.X\n> There are 2 other files needed to run this code:\n>\n> - `TwitchPlays_KeyCodes.py` contains the key codes and functions to press keys in-game. You should not modify this file.\n> - `TwitchPlays_Connection.py` is the code that actually connects to Twitch. You should not modify this file.\n>\n> The source code primarily comes from:\n>\n> - Wituz's \"Twitch Plays\" tutorial: <http://www.wituz.com/make-your-own-twitch-plays-stream.html>\n> - PythonProgramming's \"Python Plays GTA V\" tutorial: <https://pythonprogramming.net/direct-input-game-python-plays-gta-v/>\n> - DDarknut's message queue and updates to the Twitch networking code\n>\n> Disclaimer:\n>\n> - This code is NOT intended to be professionally optimized or organized.\n> - We created a simple version that works well for livestreaming, and I'm sharing it for educational purposes.\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "A Twitch Plays style programme to allow users in Twitch chats to control the broadcasters mouse and keyboard",
    "version": "2.0.4",
    "project_urls": {
        "Bug Tracker": "https://github.com/howroyd/simonsays/issues",
        "Homepage": "https://github.com/howroyd/simonsays",
        "Repository": "https://github.com/howroyd/simonsays"
    },
    "split_keywords": [
        "twitch",
        "chat",
        "twitchplays",
        "troll"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b9cbcc5ac983b95249b0c8eab06a947ba9722b69eddde9fb0c12feddcb71a529",
                "md5": "5c73abda05b0e7df243686cb4938d388",
                "sha256": "2ec9dc61ed555bb295ed9bb4f6b3f3f7253ad8970f1b2c7de05abf9ff8cebd39"
            },
            "downloads": -1,
            "filename": "simonsays_drgreengiant-2.0.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5c73abda05b0e7df243686cb4938d388",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11.4",
            "size": 35862,
            "upload_time": "2023-11-12T16:22:42",
            "upload_time_iso_8601": "2023-11-12T16:22:42.054921Z",
            "url": "https://files.pythonhosted.org/packages/b9/cb/cc5ac983b95249b0c8eab06a947ba9722b69eddde9fb0c12feddcb71a529/simonsays_drgreengiant-2.0.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3af9458e9030fb89c9493d280031cc7f9f850f9e235ad0ecb41b97dac1ee0291",
                "md5": "a6b9ab31189c2f75167d72aaf6100d56",
                "sha256": "9c4d7a8c84e8bf4fa1dd9f9e01eeed31bad47c3bfe46777f7813b7d6438c6d8a"
            },
            "downloads": -1,
            "filename": "simonsays_drgreengiant-2.0.4.tar.gz",
            "has_sig": false,
            "md5_digest": "a6b9ab31189c2f75167d72aaf6100d56",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11.4",
            "size": 33342,
            "upload_time": "2023-11-12T16:22:43",
            "upload_time_iso_8601": "2023-11-12T16:22:43.673943Z",
            "url": "https://files.pythonhosted.org/packages/3a/f9/458e9030fb89c9493d280031cc7f9f850f9e235ad0ecb41b97dac1ee0291/simonsays_drgreengiant-2.0.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-12 16:22:43",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "howroyd",
    "github_project": "simonsays",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": true,
    "requirements": [
        {
            "name": "Pillow",
            "specs": []
        },
        {
            "name": "pynput",
            "specs": []
        },
        {
            "name": "requests",
            "specs": []
        },
        {
            "name": "semantic-version",
            "specs": []
        },
        {
            "name": "tomlkit",
            "specs": []
        },
        {
            "name": "twitchirc_drgreengiant",
            "specs": []
        }
    ],
    "lcname": "simonsays-drgreengiant"
}
        
Elapsed time: 0.15380s