Skip to content

Commit

Permalink
finishing touches, like flip
Browse files Browse the repository at this point in the history
  • Loading branch information
othello777 committed Sep 22, 2021
1 parent 5a5ba7a commit 7c0f93a
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions src/MyEventListener.java
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ public void onMessageReceived(MessageReceivedEvent event) {
"join - boby joins vc for no reason\r\n" +
"stop - boby leaves vc\r\n" +
"????? - I just wanna tell you how I'm feeling\r\n" +
"face - Sends user's profile picture\r\n" +
"```\r\n" +
"Other Features:\r\n" +
"```\r\n" +
Expand Down Expand Up @@ -367,6 +368,15 @@ public void onMessageReceived(MessageReceivedEvent event) {
}
channel.sendMessage(sendString).addFile(ret.file).queue();
}
if(command.startsWith("flip")) {
FileReturn ret = getFileFromDir("flip", null);
String sendString = "Error";
if(ret.index == 1)
sendString = "**Heads! :+1:**";
if(ret.index == 0)
sendString = "**Tails! :-1:**";
channel.sendMessage(sendString).addFile(ret.file).queue();
}
if(command.startsWith("spamE")) {
String l = command.substring(6);
String E = "";
Expand Down Expand Up @@ -529,6 +539,23 @@ else if(random.nextBoolean())
if(command.startsWith("sing")) {
sing = true;
}
if(command.startsWith("face")) {
User funguy;
List<Member> mentionsList = inputMessage.getMentionedMembers();
if(mentionsList.size() > 1) {
channel.sendMessage("crig only 1 mentn plz").queue();
}
if(mentionsList.size() < 1) {
funguy = event.getAuthor();
}
try {
funguy = mentionsList.get(0).getUser();
} catch (Exception e) {
channel.sendMessage("Error in getting mention").queue();
return;
}
channel.sendMessage(funguy.getAvatarUrl()).queue();
}



Expand Down

0 comments on commit 7c0f93a

Please sign in to comment.