import discord from discord.ext import commands from mcstatus import MinecraftServer class ServerInfo(commands.Cog): def __init__(self, client): self.client = client @commands.command(name="info") async def info(self, ctx): port = "25201" ip = "81.82.224.207" server = MinecraftServer.lookup(f"{ip}:{port}") # List of colours for the amount of servers that are online embed = discord.Embed() embed.set_author(name="Info") embed.colour = discord.Colour.orange() embed.add_field(name="Ip", value=f"play.worldcraft.us", inline=False) embed.add_field( name="Dynmap", value=f"https://map.worldcraft.us/", inline=False) embed.add_field( name="Online", value=f"There are **{server.status().players.online}** players online!", inline=False) await ctx.send(embed=embed) def setup(client): # client.add_cog(ServerInfo(client)) pass