Spaces:
Building
Building
Update admincash.py
Browse files- admincash.py +3 -3
admincash.py
CHANGED
@@ -3,16 +3,16 @@ from discord import app_commands
|
|
3 |
|
4 |
from cash import user_cash
|
5 |
|
6 |
-
@app_commands.command(name="admincash", description="
|
7 |
async def admincash(interaction: discord.Interaction, user: discord.User, amount: int):
|
8 |
if interaction.user.id != 696434794174611477:
|
9 |
-
await interaction.response.send_message("
|
10 |
return
|
11 |
|
12 |
user_cash[user.id] = user_cash.get(user.id, 0) + amount
|
13 |
new_balance = user_cash[user.id]
|
14 |
|
15 |
-
embed = discord.Embed(title="Admin Cash Added", description=f"Added ${amount:.2f} to {user.name}'s balance", color=
|
16 |
embed.add_field(name="New Balance", value=f"${new_balance:.2f}", inline=False)
|
17 |
|
18 |
await interaction.response.send_message(embed=embed)
|
|
|
3 |
|
4 |
from cash import user_cash
|
5 |
|
6 |
+
@app_commands.command(name="admincash", description="admin cash")
|
7 |
async def admincash(interaction: discord.Interaction, user: discord.User, amount: int):
|
8 |
if interaction.user.id != 696434794174611477:
|
9 |
+
await interaction.response.send_message("no.", ephemeral=True)
|
10 |
return
|
11 |
|
12 |
user_cash[user.id] = user_cash.get(user.id, 0) + amount
|
13 |
new_balance = user_cash[user.id]
|
14 |
|
15 |
+
embed = discord.Embed(title="Admin Cash Added", description=f"Added ${amount:.2f} to {user.name}'s balance", color=0x787878)
|
16 |
embed.add_field(name="New Balance", value=f"${new_balance:.2f}", inline=False)
|
17 |
|
18 |
await interaction.response.send_message(embed=embed)
|