Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need automod functions #17

Open
MitchellHarrison opened this issue May 14, 2021 · 5 comments
Open

Need automod functions #17

MitchellHarrison opened this issue May 14, 2021 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@MitchellHarrison
Copy link
Owner

"WaNnA bEcOmE fAmOuS?!!?"

@MitchellHarrison MitchellHarrison added the enhancement New feature or request label May 14, 2021
@MitchellHarrison MitchellHarrison self-assigned this May 14, 2021
@MitchellHarrison
Copy link
Owner Author

user should get a warning/ban if trying to shoutout themselves once/more than once.

@VinylVault
Copy link

user should get a warning/ban if trying to shoutout themselves once/more than once.

i dont see it as automod, and i honesthly thik it should be part of the !so stuff, that way its configured in the same place as the !so message

@VinylVault
Copy link

some channels allow self shoutout, but only every {{ definable }} period of time, this is useful for small streamers who have very few mods and sometimes only one is active in a channel, and the mods are streamers. might be worth having a switch for allowing self shoutout and a variable for time period in minutes.

@MitchellHarrison
Copy link
Owner Author

I'm not sure I understand your use case example, but I think a GUI to control the bot setting is a great idea and very possible. But that's a different issue. Could you elaborate? If the mods are streamers, why should they be allowed to self-shoutout? Making it configurable makes it easier of course.

@flyboy1565
Copy link

flyboy1565 commented Jul 16, 2021

To start on this you'd want to do a few things. First, elevate privileges for your bot.

Next in your regex add the following:
id=(?P<message_id>.*);

    def delete_message(self, user, channel, message_body, message_id):
        self.irc_command('@login={user};target-msg-id={message_id} :tmi.twitch.tv CLEARMSG #{channel} :{message_body}')
                message_id = message_data['message_id']
                text = message_data["text"]
                user = message_data["username"]
                display_name = message_data["display_name"]
                chatter_id = message_data["user_id"]
                user_color = message_data["color"].lstrip("#")

                if 'so you wanna be famous'  in text.lower():
                    self.delete_message(user, self.channel, text, message_id)
                    return 

This would remove the chat message (i think) and also remove it from ending up in your local chat stream.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants