add custom categories to the liquid bounce mod menu (custom)



  • praise https://forum.ccbluex.net/thread.php?id=2604

    henlo friend))

    i back witcher another tuto XD i was show how make cool custom good click jui mod menu categorys with water jump slimeblock mod api ok???? i paste from uc mysef))
    ok ok ok ok
    fist uu need import class definition lmao heheheXDDD

                                                                         Constructor = Java.type("java.lang.reflect.Constructor");
                         Modifier = Java.type("java.lang.reflect.Modifier");
    
                                    Field = Java.type("java.lang.reflect.Field");
    
    
    ModuleCategory = Java.type("net.ccbluex.liquidbounce.features.module.ModuleCategory");
    

    ok now you go got tcheese enum category valuables XDDD

    valuablesField = ModuleCategory.class.getDeclaredField("$VALUES");
    

    they is aber final!!!!! not good)))))))) need adjust heheheeh

    fizzt get modifiers fieldDDDDDD

    modifiersField = Field.class.getDeclaredField("modifiers")
    //how to remove final modifier is left out as an excercise for the reader, of course.
    

    now you change it!!!!!!!!!!!))))))))))

    you need made new enum valuable

    you need get construction pfield (plant)DDDD

    constructionField = ModuleCategory.class.getDeclaredConstructors()[0]
    

    now you to delegation as an delegator and ackqire delegator via acesor)))))

    akqirreMethod = Constructor.class.getDeclaredMethod("acquireConstructorAccessor");
    

    now you delegate to the construction field XDDDDDDDDDDD

    acesor = akqirreMethod.invoke(constructionField);
    

    okokokokk)))))) time make new enum valuable final time!!!!!!!!

    as sait 100 times new valuable make
    delegation make new value in construction field

    valuable = acesor.newInstance(["KUSTOM", 0, "lololoolool"]);
    

    now you cat valuables)))))))

    need convert to jsscript and back

    jsscriptValuables = Java.from(valuablesField.get(null));
    newValuables = jsscriptValuables.concat(valuable);
    newenumValuables = Java.to(newValuables, "net.ccbluex.liquidbounce.features.module.ModuleCategory[]");
    

    set newenum valuables!!!!!!! and you've done]]]]]]

    valuablesField.set(null, newenumValuables);
    

    do before register modules else reload clickgui

    now you can make things like this
    9011f5a8-4ca0-4abb-bf10-a3431a999985-image.png

    ok thank me for your read afteryt best devlopmen on earth ok??!! some weird language
    he has coronavirus(((((

    if you actually want to know how i did this

    all fields and methods are inacesible you make acesible you self LLLLL
    you trash can just do this with core 1.5.0+
    45444c51-890e-42e3-9cb0-c38fe5386c4c-image.png



  • not a single comment



  • @CzechHek ηŽ°εœ¨ζœ‰δΊ†:)



  • @CzechHek ugh so add this before register module?
    also core 1.5.0 added custom category?



  • well, if I edit src, it will only take 1 line to create a new category in clickgui and tabgui

    simple & fast πŸ˜†



  • @notautismatall lmao how would you distribute it

    well if you use Core you don't even have to write any additional line, just set module category to one that doesn't exist and Core will create it



  • @CzechHek omg wow

    even faster



  • Can U make tutorial how to change Font ?



  • @MCHacks said in add custom categories to the liquid bounce mod menu (custom):

    Can U make tutorial how to change Font ?

    wdym change font


Log in to reply