changed order for quickmode
This commit is contained in:
@@ -296,10 +296,6 @@ async function nutsNut(interaction, quickMode) {
|
|||||||
files: [`${asset_path}nuts_onCD.avif`]
|
files: [`${asset_path}nuts_onCD.avif`]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
embed.setDescription('\u200B')
|
|
||||||
// pseudo animation
|
|
||||||
|
|
||||||
|
|
||||||
// set 1 hour cooldown
|
// set 1 hour cooldown
|
||||||
const cd = Math.floor((Date.now() + 3600000) / 1000)
|
const cd = Math.floor((Date.now() + 3600000) / 1000)
|
||||||
await cdColl.findOneAndUpdate({
|
await cdColl.findOneAndUpdate({
|
||||||
@@ -338,36 +334,37 @@ async function nutsNut(interaction, quickMode) {
|
|||||||
|
|
||||||
if (quickMode) {
|
if (quickMode) {
|
||||||
return interaction.editReply({ content: `Du hast ${formatNut(amount)} bekommen! :chestnut:` })
|
return interaction.editReply({ content: `Du hast ${formatNut(amount)} bekommen! :chestnut:` })
|
||||||
} else {
|
|
||||||
embed.setImage(assets.box)
|
|
||||||
await interaction.editReply({
|
|
||||||
embeds: [embed],
|
|
||||||
files: [`${asset_path}nuts_box.png`]
|
|
||||||
})
|
|
||||||
await delay(1337)
|
|
||||||
embed.setImage(assets.explosion)
|
|
||||||
await interaction.editReply({
|
|
||||||
embeds: [embed],
|
|
||||||
files: [`${asset_path}nuts_explosion.gif`]
|
|
||||||
})
|
|
||||||
await delay(1337)
|
|
||||||
|
|
||||||
let assetFile
|
|
||||||
if (amount === 0) assetFile = assets.none
|
|
||||||
else if (amount > 8) assetFile = assets.high
|
|
||||||
else if (amount > 4) assetFile = assets.normal
|
|
||||||
else assetFile = assets.low
|
|
||||||
|
|
||||||
embed.setTitle(`Du hast ${formatNut(amount)} bekommen!`)
|
|
||||||
embed.setThumbnail(assetFile)
|
|
||||||
embed.setImage(null)
|
|
||||||
|
|
||||||
return interaction.editReply({
|
|
||||||
embeds: [embed],
|
|
||||||
files: [`${asset_path}${assetFile.split('://')[1]}`]
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// pseudo animation
|
||||||
|
embed.setImage(assets.box)
|
||||||
|
await interaction.editReply({
|
||||||
|
embeds: [embed],
|
||||||
|
files: [`${asset_path}nuts_box.png`]
|
||||||
|
})
|
||||||
|
await delay(1337)
|
||||||
|
embed.setImage(assets.explosion)
|
||||||
|
await interaction.editReply({
|
||||||
|
embeds: [embed],
|
||||||
|
files: [`${asset_path}nuts_explosion.gif`]
|
||||||
|
})
|
||||||
|
await delay(1337)
|
||||||
|
|
||||||
|
let assetFile
|
||||||
|
if (amount === 0) assetFile = assets.none
|
||||||
|
else if (amount > 8) assetFile = assets.high
|
||||||
|
else if (amount > 4) assetFile = assets.normal
|
||||||
|
else assetFile = assets.low
|
||||||
|
|
||||||
|
embed.setTitle(`Du hast ${formatNut(amount)} bekommen!`)
|
||||||
|
embed.setThumbnail(assetFile)
|
||||||
|
embed.setImage(null)
|
||||||
|
|
||||||
|
return interaction.editReply({
|
||||||
|
embeds: [embed],
|
||||||
|
files: [`${asset_path}${assetFile.split('://')[1]}`]
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|||||||
Reference in New Issue
Block a user