Skip to content
This repository was archived by the owner on Dec 18, 2021. It is now read-only.

Commit a854b36

Browse files
Update tictactoe.py
Fix playing against yourself.
1 parent 2e2e4ec commit a854b36

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

examples/games/tictactoe.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ def __init__(self, bot):
1515

1616
@command(aliases=['tictactoe'])
1717
async def ttt(self, ctx, member: discord.Member):
18+
if ctx.author == member:
19+
return await ctx.send("You can't play against yourself!")
1820
embed = discord.Embed(color=0xF5F5F5, title=f"Hey, {ctx.author.name} wants to play tic-tac-toe with you!")
1921
acceptdenycomps = [
2022
[

0 commit comments

Comments
 (0)