mjx-client 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/dist/tests/Commands/ping.d.ts +0 -2
- package/dist/tests/Commands/ping.js +0 -10
- package/dist/tests/Events/message.d.ts +0 -3
- package/dist/tests/Events/message.js +0 -14
- package/dist/tests/Events/ready.d.ts +0 -2
- package/dist/tests/Events/ready.js +0 -9
- package/dist/tests/main.d.ts +0 -1
- package/dist/tests/main.js +0 -17
- /package/dist/{src/client.d.ts → client.d.ts} +0 -0
- /package/dist/{src/client.js → client.js} +0 -0
- /package/dist/{src/lib → lib}/collector.d.ts +0 -0
- /package/dist/{src/lib → lib}/collector.js +0 -0
- /package/dist/{src/lib → lib}/logger.d.ts +0 -0
- /package/dist/{src/lib → lib}/logger.js +0 -0
package/package.json
CHANGED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { SlashCommandBuilder } from "discord.js";
|
|
2
|
-
const pingCommand = {
|
|
3
|
-
data: new SlashCommandBuilder()
|
|
4
|
-
.setName("ping")
|
|
5
|
-
.setDescription("Replies with Pong!"),
|
|
6
|
-
execute: async (interaction) => {
|
|
7
|
-
await interaction.reply("Pong!");
|
|
8
|
-
},
|
|
9
|
-
};
|
|
10
|
-
export default pingCommand;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { Events } from "discord.js";
|
|
2
|
-
const messageEvent = {
|
|
3
|
-
name: Events.MessageCreate,
|
|
4
|
-
once: false,
|
|
5
|
-
async execute(message) {
|
|
6
|
-
if (message.author.bot)
|
|
7
|
-
return;
|
|
8
|
-
const channel = message.client.channels.cache.get(process.env.TEST_CHANNEL);
|
|
9
|
-
if (channel?.isTextBased()) {
|
|
10
|
-
await channel.send(`Hello! Received a message from ${message.author.tag}`);
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
};
|
|
14
|
-
export default messageEvent;
|
package/dist/tests/main.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import "dotenv/config";
|
package/dist/tests/main.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import "dotenv/config";
|
|
2
|
-
import Client from "../src/client.js";
|
|
3
|
-
const client = new Client({ debug: true })
|
|
4
|
-
.setName("tuff bot");
|
|
5
|
-
client.registerEventsRoute("./dist/tests/Events");
|
|
6
|
-
client.registerCommandsRoute("./dist/tests/Commands");
|
|
7
|
-
client.discord.on("messageCreate", (msg) => {
|
|
8
|
-
if (msg.content === "!ping")
|
|
9
|
-
msg.reply("pong");
|
|
10
|
-
});
|
|
11
|
-
client.discord.once("ready", () => {
|
|
12
|
-
setTimeout(() => {
|
|
13
|
-
process.exit(0);
|
|
14
|
-
}, 20000);
|
|
15
|
-
});
|
|
16
|
-
client.start(process.env.TOKEN);
|
|
17
|
-
client.pushCommands(process.env.TOKEN);
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|