removed class imports from command scripts
This commit is contained in:
parent
948877f0ee
commit
98d8e96922
@ -1,10 +1,6 @@
|
||||
from abc import ABCMeta, abstractmethod
|
||||
from enum import Enum, auto
|
||||
|
||||
import twitch.chat
|
||||
|
||||
from twitch_script import Twitch_Module
|
||||
|
||||
|
||||
class AbstractCommand(metaclass=ABCMeta):
|
||||
"""
|
||||
|
||||
@ -1,9 +1,6 @@
|
||||
from abc import ABCMeta
|
||||
|
||||
import twitch.chat
|
||||
|
||||
from commands.command_base import AbstractCommand
|
||||
from twitch_script import Twitch_Module
|
||||
|
||||
|
||||
class CommandTest(AbstractCommand, metaclass=ABCMeta):
|
||||
@ -12,6 +9,6 @@ class CommandTest(AbstractCommand, metaclass=ABCMeta):
|
||||
def __init__(self):
|
||||
super().__init__(CommandTest.command, command_type=AbstractCommand.CommandType.TWITCH)
|
||||
|
||||
def do_command(self, bot: Twitch_Module, twitch_message: twitch.chat.Message):
|
||||
def do_command(self, bot, twitch_message):
|
||||
print("!test Detected")
|
||||
twitch_message.chat.send("test acknowledged")
|
||||
|
||||
@ -1,9 +1,7 @@
|
||||
from abc import ABCMeta
|
||||
|
||||
import twitch.chat
|
||||
|
||||
from commands.command_base import AbstractCommand
|
||||
from twitch_script import Twitch_Module
|
||||
|
||||
|
||||
|
||||
class CommandTTS(AbstractCommand, metaclass=ABCMeta):
|
||||
@ -12,7 +10,7 @@ class CommandTTS(AbstractCommand, metaclass=ABCMeta):
|
||||
def __init__(self):
|
||||
super().__init__(CommandTTS.command, n_args=1, command_type=AbstractCommand.CommandType.TWITCH)
|
||||
|
||||
def do_command(self, bot: Twitch_Module, twitch_message: twitch.chat.Message):
|
||||
def do_command(self, bot, twitch_message):
|
||||
args = self.get_args(twitch_message.text)
|
||||
if args[1] == "start":
|
||||
bot.send_message("tts activated on #%s" % twitch_message.channel)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user