Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E yu m coder main #2

Merged
merged 57 commits into from
Jan 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
4209494
Comments added
eYuM-coder Sep 23, 2022
bf41018
Merge branch 'main' of https://github.com/Pogy-Bot/Pogy
eYuM-coder Sep 23, 2022
e795091
Added new command for Pogy
eYuM-coder Oct 4, 2022
d5ee927
Merge branch 'main' of https://github.com/Boeing-737-800/Pogy-1
eYuM-coder Oct 4, 2022
a37f1c9
Added Hack Command For Pogy (bugs fixed)
eYuM-coder Oct 4, 2022
9cbc416
Merge branch 'main' of https://github.com/Boeing-737-800/Pogy-1
eYuM-coder Oct 4, 2022
ca28247
Slash Command support
eYuM-coder Nov 10, 2022
e9bb3df
Slash Command Support for Pogy
eYuM-coder Nov 10, 2022
982dae5
Merge branch 'main' of https://github.com/Boeing-737-800/Pogy-1
eYuM-coder Nov 10, 2022
3fafc4b
Merge branch 'main' of https://github.com/Boeing-737-800/Pogy-1
eYuM-coder Nov 10, 2022
73c826b
Merge branch 'main' of https://github.com/Boeing-737-800/Pogy-1
eYuM-coder Nov 10, 2022
6c17c2a
Slash Commands For Pogy with Raw djs
eYuM-coder Nov 10, 2022
6305dd9
More slash commands for pogy (Plus new handler)
eYuM-coder Nov 17, 2022
d096515
Resolved merge conflicts
eYuM-coder Nov 17, 2022
2b8bede
Delete mute.js
eYuM-coder Nov 18, 2022
0817ab9
Delete unmute.js
eYuM-coder Nov 18, 2022
27b3635
New command for pogy
eYuM-coder Nov 18, 2022
efc8ec2
Why..
eYuM-coder Nov 18, 2022
749f04b
Quick fix in warnings.js
eYuM-coder Nov 28, 2022
5da539a
Warn command converted to slash command
eYuM-coder Nov 28, 2022
e0f2418
Another command
eYuM-coder Nov 28, 2022
0624100
New category :D
eYuM-coder Feb 15, 2023
98b246d
Create balance.js
eYuM-coder Feb 15, 2023
7c1ff75
Create beg.js
eYuM-coder Feb 15, 2023
f6fa81b
Deleted this.
eYuM-coder Feb 15, 2023
83098c4
Create e
eYuM-coder Feb 15, 2023
f649917
New category :D
eYuM-coder Feb 15, 2023
06f17e3
Delete e
eYuM-coder Feb 15, 2023
9ae63fa
Added profile.js
eYuM-coder Feb 15, 2023
83813a9
Update utils.js
eYuM-coder Feb 15, 2023
bc198ca
Finished information category
eYuM-coder Mar 6, 2023
fe4d39c
finished moderation category
eYuM-coder Mar 6, 2023
b8b7ec2
Create autoresponselist.js
eYuM-coder Mar 6, 2023
e1de5e8
finished config category
eYuM-coder Mar 6, 2023
effd7e0
Create quote.js
eYuM-coder Mar 6, 2023
b435373
finishing this later
eYuM-coder Mar 6, 2023
7fe5c22
Create addbadge.js
eYuM-coder Mar 6, 2023
bc560bf
unfinished
eYuM-coder Mar 6, 2023
fb8a6d0
Create vote.js
eYuM-coder Mar 6, 2023
9e3259a
Unfinished (still have a lot to convert here)
eYuM-coder Mar 6, 2023
21bf2d5
Merge branch 'Pogy-Bot:main' into main
eYuM-coder Mar 9, 2023
4c9061d
Changed url to hcaptcha api
eYuM-coder Mar 9, 2023
af83ab2
Update clear.js
eYuM-coder Mar 10, 2023
6f9a28a
minor update
Jan 3, 2024
4d77daa
Create config.json
eYuM-coder Jan 3, 2024
7b25825
Merge pull request #1 from eYuM-coder/eYuM-coder-patch-1
eYuM-coder Jan 3, 2024
9ceab9f
update
Jan 3, 2024
61dfde2
a
Jan 3, 2024
49d12f4
Slash Commands Update
Jan 3, 2024
4f64c28
update language files for better grammar
Jan 4, 2024
f34e1f9
minor website update
Jan 4, 2024
05e99e7
a
Jan 4, 2024
5a1b632
Slash command update
Jan 4, 2024
d95d83f
more updates
Jan 5, 2024
b98e84c
updated command
hotsu0p Jan 9, 2024
3b7a0a9
Merge branch 'main' of https://github.com/eYuM-coder/MEE8 into eYuM-c…
hotsu0p Jan 9, 2024
0f64192
Renamed stuff from MEE8 to Pogy
hotsu0p Jan 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion .replit
Original file line number Diff line number Diff line change
@@ -1,2 +1,17 @@
language = "nodejs"
run = "npm start"
run = "npm start"

hidden = [".config", "package-lock.json"]
entrypoint = "index.js"
modules = ["nodejs-20:v8-20230920-bd784b9"]

[nix]
channel = "stable-22_11"

[unitTest]
language = "nodejs"

[deployment]
deploymentTarget = "static"
ignorePorts = false
publicDir = "./"
4 changes: 3 additions & 1 deletion Pogy.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
const { Client, Collection } = require("discord.js");
const Util = require("./src/structures/Util");
const config = require("./config.json");
const fs = require("node:fs");
const path = require("node:path");
const { status } = config;

module.exports = class PogyClient extends Client {
Expand Down Expand Up @@ -30,9 +32,9 @@ module.exports = class PogyClient extends Client {
],
},
});

this.validate(options);
this.botCommands = new Collection();
this.slashCommands = new Collection();
this.botEvents = new Collection();
this.aliases = new Collection();
this.utils = require("./src/utils/utils.js");
Expand Down
35 changes: 35 additions & 0 deletions config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"clientId": "1135714988493910136",
"developers": ["1067137336674107453"],
"status": "!help | website here",
"discord": "https://discord.gg/",
"dashboard": "true",
"server": "",
"prefix": "!",
"webhooks": {
"logs": "https://discord.com/api/webhooks/1191872792031932416/H2PmMiAF4ANN9XbGukEXQqHPBPFwIdCCiKGte3YCZeE0QO_My-8cbkvcw0Zw1_JNWn3T",
"maintenance_logs": "https://discord.com/api/webhooks/1191873962796392500/rB7t4OXNc4YAoRQBlBCPdtV1hRmr0wOmBVJb-4Q8b1oTyZpausXqACLDWsSFRXSNGi3B",
"ratelimit_logs": "https://discord.com/api/webhooks/1191874767704297593/AcMwK-t1kzEk6RFU-SmkQ7uIwf9dfHPu8JbuPJCkdQHAi17f7vZUB_iSc0XvnCQ1tN9r",
"blacklist": "https://discord.com/api/webhooks/1191875214368329809/5hkt3OXKkQuElqJEIQ6Tq-rxBDNz1MkGUKs7xTVkzJcAg53WvuO2jjQWcvLGSRKHYra6",
"report": "https://discord.com/api/webhooks/1191875430219776062/Kd_wqFD2I911e5fRew21E1_bNoFZAO29eJ6tdVSs0e0OnJMyK5EU-oeLpXJ50pYVhZPC",
"contact": "https://discord.com/api/webhooks/1191875563737067581/3Uib7OOD_y1MwVDlOUVu7B6DayFySZ5UAOUIhSxlBMNjWdSIdygWR-_Gs6-KdpzgvYoy",
"bugs": "https://discord.com/api/webhooks/1191875015319228456/q0Y8MCmtC6WCUzu3-Nk9ltc3By4oGSFnl8j-x4A8rtoVw4kjRyRHYLfH_oReFNOAp41n",
"premium": "https://discord.com/api/webhooks/1191874623776768142/7NW5AV84rIz4yC92aaZYYl0frdVQmJfNqzvRY3QglzBL_AkakjhhHf6KR-NTdhb-Jz7h",
"suggestions": "https://discord.com/api/webhooks/1191875689067061308/Aqt67syItFzuYR7XZqaRUMZlqumTfHz6Tyjg1P_hkYACgckq0JqvBRAWNJqu5uc9cPg2",
"votes": "https://discord.com/api/webhooks/1191875845271343144/vQ2TheQMXCT2aqR_hkoZKZZnrPRCQt640tI7zHYSJb3HDpyGZJKsOn44e9F42pgrHZ6B",
"errors": "https://discord.com/api/webhooks/1191876024607199403/t3MW9tGu4zliCbPSUY-ItHJVejPaNWjDD13afUnMbqSMrZtsOiMt4AoSY4bTH27dyM4v",
"auth": "https://discord.com/api/webhooks/1191876187421675701/1RiQKyKvR4Ise6d6J8suAf4piFSY0HkgDjVrr4x--chvnYFh0fYjwUPlzAhjhHFmOLOR",
"joinsPublic": "https://discord.com/api/webhooks/1191876306393108551/2tdtejyuGdfgZyA22wDsK-vG_bCcY6WBOReriE4DTCb5fAHbNLprwUs3r4DOOiWSn5jo",
"joinsPrivate": "https://discord.com/api/webhooks/1191876306393108551/2tdtejyuGdfgZyA22wDsK-vG_bCcY6WBOReriE4DTCb5fAHbNLprwUs3r4DOOiWSn5jo",
"leavesPublic": "https://discord.com/api/webhooks/1191876447091052655/7G1samQc5pPXnKy72MWX6ZFBc0dctsSsrlPFpP8pNx-ciXFmy81MZUxNqH4VBK09mrtm",
"leavesPrivate": "https://discord.com/api/webhooks/1191876447091052655/7G1samQc5pPXnKy72MWX6ZFBc0dctsSsrlPFpP8pNx-ciXFmy81MZUxNqH4VBK09mrtm"
},
"maintenance": "false",
"maintenance_threshold": "5",
"invite_link": "https://discord.com/api/oauth2/authorize?client_id=1135714988493910136&permissions=70368744177663&scope=bot+applications.commands",
"seo": {
"enabled": "false",
"title": "Bot Name",
"description": "Bot description"
}
}
32 changes: 31 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
require("dotenv").config();
const PogyClient = require("./Pogy");
const config = require("./config.json");
const deploy = require("./src/deployCommands.js");
const path = require("node:path");
const { Collection } = require("discord.js");
const logger = require("./src/utils/logger");
const fs = require("node:fs");
const Pogy = new PogyClient(config);

const color = require("./src/data/colors");
Expand All @@ -13,7 +17,6 @@ Pogy.emoji = emoji;
let client = Pogy;
const jointocreate = require("./src/structures/jointocreate");
jointocreate(client);
const fs = require('fs');

// Load user data from the JSON file
let userData = require('./src/data/users.json');
Expand Down Expand Up @@ -44,6 +47,33 @@ client.on('messageCreate', message => {
if (err) console.error('Error writing file:', err);
});
});
client.slashCommands = new Collection();
const commandsFolders = fs.readdirSync("./src/slashCommands");

for (const folder of commandsFolders) {
const commandFiles = fs.readdirSync(`./src/slashCommands/${folder}`).filter((file) => file.endsWith(".js"));

for(const file of commandFiles) {
const slashCommand = require(`./src/slashCommands/${folder}/${file}`);
client.slashCommands.set(slashCommand.data.name, slashCommand);
Promise.resolve(slashCommand);
}
}

client.on('interactionCreate', async interaction => {
if(!interaction.isCommand()) return;

const slashCommand = client.slashCommands.get(interaction.commandName);

if (!slashCommand) return;

try {
await slashCommand.execute(interaction);
} catch (error) {
await interaction.reply({ content: 'There was an error while executing this command!', ephemeral: true });
}
});

Pogy.react = new Map();
Pogy.fetchforguild = new Map();

Expand Down
Loading