-
Notifications
You must be signed in to change notification settings - Fork 0
/
test.js
76 lines (70 loc) · 1.33 KB
/
test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
const {Intents, Client} = require("discord.js")
const { setup } = require("./index")
const client = new Client({
intents: [
Intents.FLAGS.GUILDS,
Intents.FLAGS.GUILD_MEMBERS,
Intents.FLAGS.GUILD_MESSAGES,
],
});
setup({
client: client,
prefix: '!!',
commands: [
{
name: 'hlo',
reply: 'Hloooooo!',
type: 'reply'
},
{
name: 'boo',
reply: 'booo!'
}
],
triggers: [
{
name: 'hlo',
answer: 'Hloooo',
type: 'reply'
}
],
wlcm_channel: '836870465078558740', //wlcm channel id
leave_channel: '885113942903488534', //leave channel id
wlcm_embedType: true,
wlcm_embed: {
color: 0x0099ff,
title: 'Welcome!',
url: '',
author: {
name: 'Welcome to {guildName}',
icon_url: "{avatarDynamic}"
},
description: '{user} , {createdAt}',
thumbnail: {
url: '{avatarDynamic}'
},
image: {
url: '{avatarDynamic}'
},
timestamp: new Date(),
footer: {
text: 'welcome {user}',
icon_url: "{guildIcon}"
}
},
wlcm_msg: 'Hlo {user}',
leave_embedType: true,
leave_embed: {
title: 'byeeee {username}'
},
leave_msg: 'byeeeee {username}'
});
client.on('ready', () => {
console.log('hlo ' + client.user.username);
});
client.on("messageCreate", (message) => {
if(message.content === "!test"){
client.emit("guildMemberAdd", message.member)
}
})
client.login('//token');