mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 05:04:58 +05:00
action check
This commit is contained in:
parent
1f1289485b
commit
8fef235a39
1 changed files with 34 additions and 15 deletions
|
@ -33,21 +33,40 @@ class Debug extends Command {
|
|||
|
||||
const memberData = await this.client.findOrCreateMember({ id: member.id, guildID: message.guild.id });
|
||||
|
||||
if (status === "level") {
|
||||
memberData.level = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "xp") {
|
||||
memberData.exp = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "rep") {
|
||||
memberData.rep = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "credits") {
|
||||
memberData.money = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "bank") {
|
||||
memberData.bankSold = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
if (action === "set") {
|
||||
if (status === "level") {
|
||||
memberData.level = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "xp") {
|
||||
memberData.exp = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "rep") {
|
||||
memberData.rep = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "credits") {
|
||||
memberData.money = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "bank") {
|
||||
memberData.bankSold = parseInt(amount, 10);
|
||||
memberData.save();
|
||||
}
|
||||
} else if (action === "add") {
|
||||
if (status === "level") {
|
||||
memberData.level = memberData.level + parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "xp") {
|
||||
memberData.exp = memberData.exp + parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "rep") {
|
||||
memberData.rep = memberData.rep + parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "credits") {
|
||||
memberData.money = memberData.money + parseInt(amount, 10);
|
||||
memberData.save();
|
||||
} else if (status === "bank") {
|
||||
memberData.bankSold = memberData.bankSold + parseInt(amount, 10);
|
||||
memberData.save();
|
||||
}
|
||||
}
|
||||
|
||||
message.success("owner/debug:SUCCESS_" + status.toUpperCase() , { username: member.user.tag, amount });
|
||||
|
|
Loading…
Reference in a new issue