From d5a02c905969e9b32cf14cda201b476572d9d0e0 Mon Sep 17 00:00:00 2001 From: Kumo's Lab <63556081+KumosLab@users.noreply.github.com> Date: Fri, 6 May 2022 19:38:54 +0100 Subject: [PATCH] v1.0.3-Beta --- Commands/play.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Commands/play.py b/Commands/play.py index 164d3cd..9bdf612 100644 --- a/Commands/play.py +++ b/Commands/play.py @@ -101,11 +101,11 @@ async def gtf(self, ctx): message = await channel.send(embed=embed) await KumosLab.set.gameMessage(guild=ctx.guild, user=ctx.author, id=message.id) correct_countries = [] + countries = [] while round != 10: message = await KumosLab.get.gameMessage(guild=ctx.guild, user=ctx.author) message = await ctx.fetch_message(message) random_country = await KumosLab.data.alldata() - countries = [] for i in random_country: countries.append(i[0]) random_country = random.choice(countries) @@ -113,8 +113,14 @@ async def gtf(self, ctx): # get a random image from the images folder image = await KumosLab.data.flagdata(country=random_country) - answers_array = [random_country, random.choice(countries), random.choice(countries), - random.choice(countries)] + answer_1 = random.choice(countries) + countries.remove(answer_1) + answer_2 = random.choice(countries) + countries.remove(answer_2) + answer_3 = random.choice(countries) + countries.remove(answer_3) + + answers_array = [random_country, answer_1, answer_2, answer_3] random.shuffle(answers_array) # send the image