Readd
Some checks failed
Deploy bot / build-and-deploy (push) Failing after 2s

This commit is contained in:
2025-08-26 00:28:59 +02:00
commit 7a87b284af
40 changed files with 3681 additions and 0 deletions

32
bot/commands/cb.js Normal file
View File

@ -0,0 +1,32 @@
const log = require("../log");
exports.name = "cb";
exports.description =
":crossed_swords: Calculate calamity blade damage taking in to account projectile speed.";
exports.usage = "CLIENT_PREFIX:cb <damage> <ups> [projectile speed]";
exports.example = "CLIENT_PREFIX:cb 10000 250 10000";
exports.hidden = false;
exports.run = (client, message, args) => {
if (!args[0] || !args[1])
return message.channel.send(
"Not enough arguments, consult CLIENT_PREFIX:help.".replaceAll(
"CLIENT_PREFIX:",
client.prefix
)
);
let cb = parseInt(args[0]);
let ups = parseInt(args[1]);
if (isNaN(cb) || isNaN(ups))
return message.channel.send("Damage or ups should be a number.");
let initialspeed = null;
if (args[2]) {
initialspeed = parseInt(args[2]);
if (isNaN(initialspeed))
return message.channel.send("Projectile speed should be a number.");
initialspeed = 30000 - initialspeed;
let t = Math.ceil(initialspeed / 1200);
log.info(t);
ups = ups - t;
}
let resnum = cb + ups * 192;
message.channel.send(`Your Calamity Blade will hit **${resnum}** damage.`);
};