|
1 |
| -package me.TechsCode.TechDiscordBot.module.modules; |
2 |
| - |
3 |
| -import me.TechsCode.TechDiscordBot.TechDiscordBot; |
4 |
| -import me.TechsCode.TechDiscordBot.module.Module; |
5 |
| -import me.TechsCode.TechDiscordBot.mysql.storage.Verification; |
6 |
| -import me.TechsCode.TechDiscordBot.objects.DefinedQuery; |
7 |
| -import me.TechsCode.TechDiscordBot.objects.Query; |
8 |
| -import me.TechsCode.TechDiscordBot.objects.Requirement; |
9 |
| -import me.TechsCode.TechDiscordBot.util.TechEmbedBuilder; |
10 |
| -import net.dv8tion.jda.api.entities.Role; |
11 |
| -import net.dv8tion.jda.api.events.guild.member.GuildMemberJoinEvent; |
12 |
| -import net.dv8tion.jda.api.hooks.SubscribeEvent; |
13 |
| - |
14 |
| -public class JoinModule extends Module { |
15 |
| - |
16 |
| - private final DefinedQuery<Role> MUTED_ROLE = new DefinedQuery<Role>() { |
17 |
| - protected Query<Role> newQuery() { |
18 |
| - return JoinModule.this.bot.getRoles("Muted"); |
19 |
| - } |
20 |
| - }; |
21 |
| - |
22 |
| - public JoinModule(TechDiscordBot bot) { |
23 |
| - super(bot); |
24 |
| - } |
25 |
| - |
26 |
| - @Override |
27 |
| - public void onEnable() { } |
28 |
| - |
29 |
| - @Override |
30 |
| - public void onDisable() { } |
31 |
| - |
32 |
| - public String getName() { |
33 |
| - return "JoinModule"; |
34 |
| - } |
35 |
| - |
36 |
| - @SubscribeEvent |
37 |
| - public void onGuildMemberJoin(GuildMemberJoinEvent e) { |
38 |
| - Verification existingVerification = TechDiscordBot.getStorage().retrieveVerificationWithDiscord(e.getMember().getId()); |
39 |
| - |
40 |
| - new TechEmbedBuilder("Welcome to Tech's Plugin Support") |
41 |
| - .text((existingVerification == null ? "Welcome to Tech's Plugin Support,\nIf you are looking for help, you must first verify your Spigot Account in <#695493411117072425>.\n\nAfter you have been verified, you will have access to the support channel(s)." : "Hello there,\nYou have previously verified yourself and your roles will be automatically updated as a result.\n\nThis update may take 10 to 15 minutes to complete.") + "\n\nThanks & Welcome,\nTechsCode & Team") |
42 |
| - .queue(e.getMember()); |
43 |
| - } |
44 |
| - |
45 |
| - public Requirement[] getRequirements() { |
46 |
| - return new Requirement[0]; |
47 |
| - } |
48 |
| -} |
| 1 | +//package me.TechsCode.TechDiscordBot.module.modules; |
| 2 | +// |
| 3 | +//import me.TechsCode.TechDiscordBot.TechDiscordBot; |
| 4 | +//import me.TechsCode.TechDiscordBot.module.Module; |
| 5 | +//import me.TechsCode.TechDiscordBot.mysql.storage.Verification; |
| 6 | +//import me.TechsCode.TechDiscordBot.objects.DefinedQuery; |
| 7 | +//import me.TechsCode.TechDiscordBot.objects.Query; |
| 8 | +//import me.TechsCode.TechDiscordBot.objects.Requirement; |
| 9 | +//import me.TechsCode.TechDiscordBot.util.TechEmbedBuilder; |
| 10 | +//import net.dv8tion.jda.api.entities.Role; |
| 11 | +//import net.dv8tion.jda.api.events.guild.member.GuildMemberJoinEvent; |
| 12 | +//import net.dv8tion.jda.api.hooks.SubscribeEvent; |
| 13 | +// |
| 14 | +//public class JoinModule extends Module { |
| 15 | +// |
| 16 | +// private final DefinedQuery<Role> MUTED_ROLE = new DefinedQuery<Role>() { |
| 17 | +// protected Query<Role> newQuery() { |
| 18 | +// return JoinModule.this.bot.getRoles("Muted"); |
| 19 | +// } |
| 20 | +// }; |
| 21 | +// |
| 22 | +// public JoinModule(TechDiscordBot bot) { |
| 23 | +// super(bot); |
| 24 | +// } |
| 25 | +// |
| 26 | +// @Override |
| 27 | +// public void onEnable() { } |
| 28 | +// |
| 29 | +// @Override |
| 30 | +// public void onDisable() { } |
| 31 | +// |
| 32 | +// public String getName() { |
| 33 | +// return "JoinModule"; |
| 34 | +// } |
| 35 | +// |
| 36 | +// @SubscribeEvent |
| 37 | +// public void onGuildMemberJoin(GuildMemberJoinEvent e) { |
| 38 | +// Verification existingVerification = TechDiscordBot.getStorage().retrieveVerificationWithDiscord(e.getMember().getId()); |
| 39 | +// |
| 40 | +// new TechEmbedBuilder("Welcome to Tech's Plugin Support") |
| 41 | +// .text((existingVerification == null ? "Welcome to Tech's Plugin Support,\nIf you are looking for help, you must first verify your Spigot Account in <#695493411117072425>.\n\nAfter you have been verified, you will have access to the support channel(s)." : "Hello there,\nYou have previously verified yourself and your roles will be automatically updated as a result.\n\nThis update may take 10 to 15 minutes to complete.") + "\n\nThanks & Welcome,\nTechsCode & Team") |
| 42 | +// .queue(e.getMember()); |
| 43 | +// } |
| 44 | +// |
| 45 | +// public Requirement[] getRequirements() { |
| 46 | +// return new Requirement[0]; |
| 47 | +// } |
| 48 | +//} |
0 commit comments