Guest User

Untitled

a guest
Nov 2nd, 2017
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.99 KB | None | 0 0
  1. In the TextDrawingArea class you should have 2 methods, assuming you have the standard obfuscated client. method389 and method390
  2. In both methods you should see something similar to
  3.  
  4. for (int index = 0; index < s.length(); index++) {
  5.             if (s.charAt(index) == '@' && index + 4 < s.length() && s.charAt(index + 4) == '@') {
  6.                 int j1 = getColorByName(s.substring(index + 1, index + 4));
  7.                 if (j1 != -1) {
  8.                     j = j1;
  9.                 }
  10.                 index += 4;
  11.             }
  12. }
  13.  
  14. Above that you're going to want to put in this code
  15.             if (s.charAt(index) == '#' && s.length() >= index + 1) {
  16.                 String newString = s.substring(index + 1);
  17.                 int hashIndex = newString.indexOf("#");
  18.                 if (hashIndex >= 0) {
  19.                     String color = newString.substring(0, hashIndex);
  20.                     String formattedColor = color.toLowerCase().startsWith("0x") ? color : "0x" + color;
  21.                     try {
  22.                         int colorHex = Integer.decode(formattedColor);
  23.                         j = colorHex;
  24.                         index += color.length() + 1;
  25.                     } catch (Exception e) {
  26.  
  27.                     }
  28.                 }
  29.             }
Advertisement
Add Comment
Please, Sign In to add comment