Upload files to "src/openonyx/events"
This commit is contained in:
1 parent
cb12563f5b
commit
21b3fbc342
5 files changed
+409
No files matched your search
@@ -0,0 +1,78 @@
|
||||
package openonyx.events;
|
||||
|
||||
import java.util.Locale;
|
||||
import net.minecraft.client.multiplayer.ServerData;
|
||||
import net.minecraft.scoreboard.ScoreObjective;
|
||||
import net.minecraft.scoreboard.Scoreboard;
|
||||
import net.minecraft.util.EnumChatFormatting;
|
||||
import openonyx.core.MinecraftAccess;
|
||||
|
||||
public final class HypixelUtils {
|
||||
private static final String H = "BED WARS";
|
||||
private static final int e = 1;
|
||||
|
||||
public static boolean d() {
|
||||
ServerData serverData;
|
||||
return (serverData = MinecraftAccess.mc.getCurrentServerData()) != null
|
||||
&& serverData.serverIP != null
|
||||
&& serverData.serverIP.toLowerCase(Locale.ROOT).contains("hypixel.net");
|
||||
}
|
||||
|
||||
private static String d(String string) {
|
||||
return string == null ? "" : EnumChatFormatting.getTextWithoutFormattingCodes(string);
|
||||
}
|
||||
|
||||
private static ScoreObjective L() {
|
||||
if (MinecraftAccess.mc.theWorld == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Scoreboard scoreboard;
|
||||
return (scoreboard = MinecraftAccess.mc.theWorld.getScoreboard()) == null ? null : scoreboard.getObjectiveInDisplaySlot(1);
|
||||
}
|
||||
|
||||
public static String decrypt(String string) {
|
||||
String string1 = string;
|
||||
int p = --2;
|
||||
int q = 4 << 4 ^ 3;
|
||||
String string2;
|
||||
int r = (string2 = string1).length();
|
||||
char[] ex = new char[r];
|
||||
boolean bl = true;
|
||||
int k;
|
||||
int n = k = r - 1;
|
||||
char[] c = ex;
|
||||
int j = q;
|
||||
int o = 5;
|
||||
int l = n;
|
||||
int i = p;
|
||||
|
||||
while (l >= 0) {
|
||||
int m = k;
|
||||
char d = string2.charAt(k);
|
||||
k--;
|
||||
c[m] = (char)(d ^ i);
|
||||
if (k < 0) {
|
||||
break;
|
||||
}
|
||||
|
||||
o = k--;
|
||||
c[o] = (char)(string2.charAt(o) ^ j);
|
||||
l = k;
|
||||
}
|
||||
|
||||
return new String(c);
|
||||
}
|
||||
|
||||
public static boolean L() {
|
||||
return d() && L().toUpperCase(Locale.ROOT).contains("BED WARS");
|
||||
}
|
||||
|
||||
private static String L() {
|
||||
ScoreObjective scoreObjective;
|
||||
return (scoreObjective = L()) == null ? "" : d(scoreObjective.getDisplayName());
|
||||
}
|
||||
|
||||
private HypixelUtils() {
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user