//@ts-nocheck const express = require("express"); const app = express(); app.get("/",…
- User
//@ts-nocheck
const express = require("express"); const app = express();
app.get("/", function (req, res) { res.send("Dank Grinder Running !!"); });
app.listen(3000);
const schedule = require("node-schedule"); var colors = require("colors"); var convertTime = require("convert-time"); require("dotenv").config(); const { Client } = require("discord.js-selfbot-v13"); const client = new Client(); var moment = require("moment-timezone");
client.on("ready", () => { console.log(
\nLogged in as+ client.user.tag.underline.brightRed); client.user.setStatus("invisible"); });var channelid = process.env.channelID; var storageac = process.env.storageAccount;
var begin = moment.tz(process.env.startTime, "H", process.env.timezone); var beginTime = begin.utc().format("H");
var end = moment.tz(process.env.endTime, "H", process.env.timezone); var ceaseTime = end.utc().format("H");
if (parseInt(process.env.endTime) > 24) { console.log("You cannot put a value above 24 in endTime !".red); return; }
if (parseInt(process.env.startTime) > 24) { console.log("You cannot put a value above 24 in startTime !".red); return; }
if (parseInt(process.env.startTime) >= parseInt(process.env.endTime)) { console.log(
Invald Format !!!\nEnd Time should be greater than start time !!.red .underline.bold ); return; }var begin_m = moment.tz("00", "mm", process.env.timezone); var beginTime_m = begin_m.utc().format("mm");
var end_m = moment.tz("00", "mm", process.env.timezone); var endTime_m = end_m.utc().format("mm");
console.log( "Start Time : ".red + convertTime(
${process.env.startTime}:${beginTime_m}, "hh:mm A".blue) ); console.log( "End Time : ".red + convertTime(${process.env.endTime}:${endTime_m}, "hh:mm A".blue) ); console.log( "Runtime : ".red,${process.env.endTime - process.env.startTime} hrs.blue );/////////////////// //// Auto Buy //// /////////////////
if (process.env.autoBuy === "true") { console.log("\nAuto Buy Running !".magenta); client.on("messageCreate", (message) => { if ( message.author.id !== "270904126974590976" && message.channel.id !== channelid ) return;
if (!message.mentions.has(client.user.id)) return; if (message.content.indexOf("You don't have a shovel") > -1) { const dankChannel = client.channels.cache.get(channelid); dankChannel.sendTyping(); dankChannel.send("pls with 25000"); setTimeout(function () { dankChannel.send("pls buy shovel"); }, 3000); console.log(">".green + " bought" + " a shovel !".yellow); } if (message.content.indexOf("You don't have a hunting rifle") > -1) { const dankChannel = client.channels.cache.get(channelid); dankChannel.sendTyping(); dankChannel.send("pls with 25000"); setTimeout(function () { dankChannel.send("pls buy rifle"); }, 3000); console.log(">".green + " bought" + " a hunting rifle !".yellow); } if (message.content.indexOf("You don't have a fishing pole") > -1) { const dankChannel = client.channels.cache.get(channelid); dankChannel.sendTyping(); dankChannel.send("pls with 25000"); setTimeout(function () { dankChannel.send("pls buy pole"); }, 3000); console.log(">".green + " bought" + " a fishing rod !".yellow); } - Assistant