Skip to content

Commit

Permalink
Merge PR #186 from TheBastionBot/v6-dev
Browse files Browse the repository at this point in the history
Bastion v6.11.5
  • Loading branch information
iamtraction committed Apr 15, 2018
2 parents d5e38fd + a978c1f commit 43a9ba7
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 18 deletions.
6 changes: 6 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,10 @@ test_script:
- node --version
- npm --version
- npm test
on_success:
- ps: Invoke-RestMethod https://github.com/k3rn31p4nic/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 success $env:WEBHOOK_URL
on_failure:
- ps: Invoke-RestMethod https://github.com/k3rn31p4nic/appveyor-discord-webhook/master/send.ps1 -o send.ps1
- ps: ./send.ps1 failure $env:WEBHOOK_URL
deploy: off
14 changes: 6 additions & 8 deletions changes.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
{
"date": "April 9, 2018",
"image": "https://i.imgur.com/xIt8xbz.gif",
"BUG FIXES": [
"Fixed an issue where Bastion didn't wanted to let you know how much currency you got when you used the `claim` command.",
"Fixed an issue that prevented command strings to fall back to English when a string is not available in other languages.",
"Under-the-hood fixes."
],
"date": "April 15, 2018",
"image": "https://i.imgur.com/R5rQ4qG.gif",
"BUG FIXES": [],
"IMROVEMENTS": [
"Under-the-hood improvements."
"Bastion is now more expressive with the `generateInvite` command.",
"Auto delete level up messages.",
"Under-the-hood improvements"
]
}
2 changes: 2 additions & 0 deletions handlers/levelHandler.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ module.exports = async message => {
title: 'Leveled up',
description: `:up: **${message.author.username}**#${message.author.discriminator} leveled up to **Level ${currentLevel}**`
}
}).then(msg => {
msg.delete(5000).catch(() => {});
}).catch(e => {
message.client.log.error(e);
});
Expand Down
4 changes: 2 additions & 2 deletions locales/en/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
"createEmoji": "%var% created the emoji **%var%**",
"createRole": "%var% created the role **%var%**",
"deleteChannel": "%var% deleted the %var% channel **%var%**",
"deleteChannelTopic": "%var% deleted the topic the **%var%** channel.",
"deleteChannelTopic": "%var% deleted the topic of the **%var%** channel.",
"deleteRole": "%var% deleted the role **%var%**",
"renameChannel": "%var% renamed the %var% channel **%var%** to **%var%**",
"renameRole": "%var% renamed the role **%var%** to **%var%**",
"selfAssignRole": "%var% you've been given the **%var%** role.",
"selfRemoveRole": "%var% you've been removed from the **%var%** role.",
"updateChannelTopic": "%var% updated the topic the **%var%** channel to: ```\n%var%```",
"updateChannelTopic": "%var% updated the topic of the **%var%** channel to: ```\n%var%```",
"updateRoleColor": "%var% updated the color of **%var%** role to **%var%**",

"disableAnnouncementChannel": "%var% disabled the announcement channel.",
Expand Down
10 changes: 4 additions & 6 deletions modules/money/claim.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,8 @@ exports.exec = (Bastion, message) => {
if (!claimedUsers.includes(message.author.id)) {
let rewardAmount = Bastion.functions.getRandomInt(50, 100);

let claimMessage, rewardMessage;
let rewardMessage;
if (Bastion.user.id === '267035345537728512') {
claimMessage = `${message.author} You've claimed your daily reward. Please check my message in your DM to see the reward amount.\n\n*If you want to get more Bastion Currencies when you use this command, check out the [FAQ](https://bastionbot.org/faq) on **How can I get more Bastion Currency with the claim/daily command?***`;

if (message.guild.id === specialIDs.bastionGuild) {
rewardAmount *= 2;
if (message.member && message.member.roles.has(specialIDs.patronsRole)) {
Expand All @@ -27,11 +25,11 @@ exports.exec = (Bastion, message) => {
rewardMessage = `Your account has been debited with **${rewardAmount}** Bastion Currencies.`;
}
else {
rewardMessage = `Your account has been debited with **${rewardAmount}** Bastion Currencies.\n\nUse the \`claim\`/\`daily\` command in [Bastion HQ](https://discord.gg/fzx8fkt) to get 2x more rewards.`;
rewardMessage = `Your account has been debited with **${rewardAmount}** Bastion Currencies.\n\n`
+ '💡 **Pro Tip**\nYou can get **2x** more Bastion Currencies when you use the `claim` or `daily` command in [Bastion HQ](https://discord.gg/fzx8fkt): https://discord.gg/fzx8fkt';
}
}
else {
claimMessage = `${message.author} You've claimed your daily reward. Please check my message in your DM to see the reward amount.`;
rewardMessage = `Your account has been debited with **${rewardAmount}** Bastion Currencies.`;
}

Expand All @@ -47,7 +45,7 @@ exports.exec = (Bastion, message) => {
message.channel.send({
embed: {
color: Bastion.colors.GREEN,
description: claimMessage
description: `${message.author} You've claimed your daily reward. Please check my message in your DM to see the reward amount.`
}
}).catch(e => {
Bastion.log.error(e);
Expand Down
5 changes: 4 additions & 1 deletion modules/queries/generateInvite.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ exports.exec = async (Bastion, message, args) => {
maxUses: args.uses
});

message.channel.send(`discord.gg/${invite.code}`).catch(e => {
message.channel.send('Hello. Beep. Boop.\n'
+ 'If you wanna invite friends to this server, share the following invite'
+ ' link with your friends.\nBeep!\n' +
`https://discord.gg/${invite.code}`).catch(e => {
Bastion.log.error(e);
});
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "bastion",
"version": "6.11.4",
"version": "6.11.5",
"description": "Give awesome perks to your Discord server!",
"url": "https://bastionbot.org/",
"main": "index.js",
Expand Down

0 comments on commit 43a9ba7

Please sign in to comment.