apparently it's supposed to be 4:3

This commit is contained in:
Darien Rousseau 2023-08-14 20:51:22 -06:00 committed by GitHub
parent e9faaf8a3e
commit 61b3d1855e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -338,14 +338,14 @@ client.on("interactionCreate", async interaction => {
ephemeral: true ephemeral: true
}); });
// Now check if they have enough for the tax // Now check if they have enough for the tax
if (balance < amount * 2) return interaction.reply({ if (balance < amount) return interaction.reply({
content: `You do not have enough coins to pay the tax of ${config.discord.coin}${amount}. You only have ${config.discord.coin}${balance}.`, content: `You do not have enough coins to pay the tax of ${config.discord.coin}${amount * 0.25}. You only have ${config.discord.coin}${balance}.`,
ephemeral: true ephemeral: true
}); });
// At this point we know they have enough coins, so we can take them away, make sure to take the tax away too // At this point we know they have enough coins, so we can take them away, make sure to take the tax away too
checkAndModifyPoints(interaction.user, -amount * 2); checkAndModifyPoints(interaction.user, -amount);
// Now we can give the other user the coins // Now we can give the other user the coins
checkAndModifyPoints(interaction.options.getMember("user").user, amount); checkAndModifyPoints(interaction.options.getMember("user").user, amount * 0.75);
// Now we can tell the user that it worked // Now we can tell the user that it worked
// get the amount sent with 2 decimal places if it has a decimal // get the amount sent with 2 decimal places if it has a decimal
if (amount % 1 != 0) { if (amount % 1 != 0) {