|
|
@@ -67,32 +67,32 @@ async def on_message_delete(
|
|
|
@bot.event
|
|
|
async def on_message_delete(msg):
|
|
|
if msg.author != bot.user:
|
|
|
- await msg.channel.send(f"Eine Nachricht von {msg.author} wurde gelöscht: {msg.content}")
|
|
|
+ await msg.channel.send(f"A Message from {msg.author} has been deleted: {msg.content}")
|
|
|
#---------------------------------#
|
|
|
|
|
|
#---------------------------------#
|
|
|
## Greet
|
|
|
-@bot.slash_command(description="Grüße einen User")
|
|
|
-async def greet(ctx, user: str = Option(discord.User, "Der User, den du grüßen möchtest")):
|
|
|
- await ctx.respond(f"Hallo {user.mention}")
|
|
|
+@bot.slash_command(description="Greet a User")
|
|
|
+async def greet(ctx, user: str = Option(discord.User, "The user, you want to greet")):
|
|
|
+ await ctx.respond(f"Hello {user.mention}")
|
|
|
#---------------------------------#
|
|
|
|
|
|
#---------------------------------#
|
|
|
## Say
|
|
|
-@bot.slash_command(description="Lass den Bot eine Nachricht senden")
|
|
|
+@bot.slash_command(description="Let the bot send a message")
|
|
|
async def say(
|
|
|
ctx,
|
|
|
- text: str = Option(description="Der Text, den du senden möchtest"),
|
|
|
- channel_input: discord.TextChannel = Option(description="Der Channel, in den du die Nachricht senden möchtest")
|
|
|
+ text: str = Option(description="Input the text you want to send"),
|
|
|
+ channel_input: discord.TextChannel = Option(description="Select the channel,where you want to send the message.")
|
|
|
):
|
|
|
channel= discord.utils.get(ctx.guild.channels, id = int(channel_input[2:-1]))
|
|
|
await channel.send(text)
|
|
|
- await ctx.respond("Nachricht gesendet", ephemeral=True)
|
|
|
+ await ctx.respond("Message sent", ephemeral=True)
|
|
|
#---------------------------------#
|
|
|
|
|
|
#---------------------------------#
|
|
|
## Userinfo
|
|
|
-@bot.slash_command(name="userinfo", description="Zeige Infos über einen User")
|
|
|
+@bot.slash_command(name="userinfo", description="Show informations of a user from this server")
|
|
|
async def info(
|
|
|
ctx,
|
|
|
user: str = Option(discord.User, "Select User"),
|
|
|
@@ -100,27 +100,30 @@ async def info(
|
|
|
if user is None:
|
|
|
user = ctx.author
|
|
|
elif user not in ctx.guild.members:
|
|
|
- await ctx.respond("Der User ist nicht auf diesem Server!", ephemeral=True)
|
|
|
+ await ctx.respond("The selected user is not a member on this Server!", ephemeral=True)
|
|
|
return
|
|
|
elif user == bot.user:
|
|
|
- await ctx.respond("Das bin ja ich!", ephemeral=True)
|
|
|
+ await ctx.respond(f"This is me - the {bot.user}", ephemeral=True)
|
|
|
return
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
embed = discord.Embed(
|
|
|
- title=f"Infos über {user.name}",
|
|
|
- description=f"Hier siehst du alle Details über {user.mention}",
|
|
|
+ title=f"Information about {user.name}",
|
|
|
+ description=f"Here you see all details about {user.mention}",
|
|
|
color=discord.Color.blue()
|
|
|
)
|
|
|
|
|
|
time = discord.utils.format_dt(user.created_at, "R")
|
|
|
|
|
|
- embed.add_field(name="Account erstellt", value=time, inline=False)
|
|
|
- embed.add_field(name="Rollen", value=", ".join([role.mention for role in user.roles if role.name != "@everyone"]), inline=False)
|
|
|
- embed.add_field(name="Server Join", value=discord.utils.format_dt(user.joined_at, "R"), inline=False)
|
|
|
- embed.add_field(name="ID", value=user.id)
|
|
|
+ embed.add_field(name="Account creation date", value=time, inline=False)
|
|
|
+ if len(user.roles) >= 2:
|
|
|
+ embed.add_field(name="Roles", value=", ".join([role.mention for role in user.roles if role.name != "@everyone"]), inline=False)
|
|
|
+ else:
|
|
|
+ embed.add_field(name="Roles", value="User has no roles", inline=False)
|
|
|
+ embed.add_field(name="Server join date", value=discord.utils.format_dt(user.joined_at, "R"), inline=False)
|
|
|
+ embed.add_field(name="User ID", value=user.id)
|
|
|
|
|
|
embed.set_thumbnail(url=user.display_avatar.url)
|
|
|
embed.set_footer(text="World Wide Modding - Bot | Made by BaumSplitter41")
|
|
|
@@ -130,23 +133,35 @@ async def info(
|
|
|
|
|
|
#---------------------------------#
|
|
|
## Serverinfo
|
|
|
-"""@bot.slash_command(name="Serverinfo", description = "Show Informations to this Server")
|
|
|
+@bot.slash_command(name="serverinfo", description = "Show Informations to this Server")
|
|
|
async def info(
|
|
|
ctx,
|
|
|
- server = discord.guild
|
|
|
):
|
|
|
-
|
|
|
+ server = ctx.guild
|
|
|
embed = discord.Embed(
|
|
|
- title=f"Infos über {server.name}",
|
|
|
- description=f"Hier siehst du alle Details über {server.mention}",
|
|
|
+ title=f"Serverinformations of {server.name}",
|
|
|
+ description=f"Here you see all details about {server.name}",
|
|
|
color=discord.Color.blue()
|
|
|
)
|
|
|
|
|
|
+ time = discord.utils.format_dt(server.created_at, "R")
|
|
|
+
|
|
|
+ embed.add_field(name="Server creation date", value=time, inline=False)
|
|
|
+
|
|
|
+ embed.add_field(name="Owner", value=server.owner, inline=False)
|
|
|
+ embed.add_field(name="Member", value=server.member_count, inline=False)
|
|
|
+ embed.add_field(name="Description", value=server.description, inline=False)
|
|
|
+
|
|
|
+
|
|
|
+ embed.add_field(name="Server ID", value=server.id)
|
|
|
+
|
|
|
+ embed.set_thumbnail(url=server.icon)
|
|
|
+ embed.set_footer(text="World Wide Modding - Bot | Made by BaumSplitter41")
|
|
|
|
|
|
await ctx.respond(embed=embed)
|
|
|
|
|
|
|
|
|
-"""
|
|
|
+
|
|
|
#---------------------------------#
|
|
|
|
|
|
|