The code I have at the moment doesn’t accompany for all users as the json file which it stores the "coins" in only saves it as userid. This is the code for storing the coins in the json file:
@client.command()
async def Shibaku1(ctx, coin1, coin2, coin3, coin4, coin5, coin6):
with open('Shibaku1.json', 'r') as f:
coins_data = json.load(f)
coins_data['userid'] = (coin1, coin2, coin3, coin4, coin5, coin6)
with open('Shibaku1.json', 'w') as f:
json.dump(coins_data, f)
Example of what gets stored in the json file:
{"userid": [":Helicopter:", ":Skateboard1:", ":swords:", ":mace:", ":mace:", ":mangosteen:"]}
How do I make it so it stores a different set for each user?
>Solution :
Replace coins_data['userid'] with coins_data[ctx.author.id].
Then your json file will look like this:
{123456789: [":Helicopter:", ":Skateboard1:", ":swords:", ":mace:", ":mace:", ":mangosteen:"]}