channel.sendMessage("Trying to retrieve map from discord status...").queue(m->mid.add(m.getId()));//DONE custom status masks presence now, will not be as effective; any way to get manually? //JDA 4 API change fixed this
long ms = Math.abs(timesent.until(timeReceived, ChronoUnit.MILLIS));
System.out.println("Time taken: " + ms + "ms");*/
if(details!=null){//TODO if name is sth like `Feryquitous - (S).0ngs//---::compilation.[TQR-f3] [-[//mission:#FC.0011-excindell.defer.abferibus]-]` it breaks (but reasonable break tbh)
channel.sendMessage("For "+uid+" to actually gain "+df.format(targetPP)+"pp in "+modes.get(modeId)+", they have to play a map worth approximately **"+df.format(mid)+"pp** raw.").queue();
booleanpassOnly=params.removeAll(Collections.singleton("-p"));//no need space, as spaced ones are split (if a player has a name with spaced -p it might be a problem)
XYChartchart=newXYChartBuilder().width(800).height(600).title("Top PP plays for "+concName+" ("+modes.get(modeId)+")").yAxisTitle("PP").xAxisTitle("Plays (100 = top)").build();
returnnewCommandResult(CommandResultType.INVALIDARGS,"Please enter search words or an URL.");
}/* else if (words.length > 2) {
try {
page = Integer.parseInt(words[2]);
} catch (NumberFormatException e) {
throw new IllegalArgumentException("Please enter a valid page number.");
}
}*/
Stringid="",set="";
try{
newURL(words[0]);
}catch(MalformedURLExceptione){
//throw new IllgalArgumentException("Invalid URL."); //NOFIX: for some reason, discord seems to continue the typing after this has been sent //its because of queue()
mode=card.getContentDisplay().contains("Mania")?"mania":card.getContentDisplay().split("Most Recent ")[1].split(" ")[0];//ye fucking blame owobot for being so inconsistent
returnnewCommandResult(CommandResultType.INVALIDARGS,"Unknown player `"+uid+"` or the player has no scores on this map.");
}
},"[username] [| index]",null,"Compare your score with the most recent map/score card in the channel!",Arrays.asList(" * Specify the index to skip to the nth recent score card in the channel."));