66
77log = logging .getLogger (__name__ )
88
9+ from bot .cogs import get_info
10+
911
1012class Snakes :
1113 """
@@ -15,34 +17,11 @@ class Snakes:
1517 def __init__ (self , bot : AutoShardedBot ):
1618 self .bot = bot
1719
18- async def get_snek (self , name : str = None ) -> Dict [str , Any ]:
19- """
20- Go online and fetch information about a snake
21-
22- The information includes the name of the snake, a picture of the snake, and various other pieces of info.
23- What information you get for the snake is up to you. Be creative!
24-
25- If "python" is given as the snake name, you should return information about the programming language, but with
26- all the information you'd provide for a real snake. Try to have some fun with this!
27-
28- :param name: Optional, the name of the snake to get information for - omit for a random snake
29- :return: A dict containing information on a snake
30- """
31-
32- @command ()
33- async def get (self , ctx : Context , name : str = None ):
34- """
35- Go online and fetch information about a snake
36-
37- This should make use of your `get_snek` method, using it to get information about a snake. This information
38- should be sent back to Discord in an embed.
39-
40- :param ctx: Context object passed from discord.py
41- :param name: Optional, the name of the snake to get information for - omit for a random snake
42- """
43-
44- # Any additional commands can be placed here. Be creative, but keep it to a reasonable amount!
45-
20+ @command (name = 'blah' )
21+ async def get (self , ctx : Context , * args ):
22+ snake_info = await get_info .get_snek (* args )
23+ await ctx .send (snake_info )
24+
4625
4726def setup (bot ):
4827 bot .add_cog (Snakes (bot ))
0 commit comments