Package com.forgeessentials.core.preloader.asm.EventInjector

Examples of com.forgeessentials.core.preloader.asm.EventInjector.ClassPatch


        initEntityPlayerMPPatch(); // disable if 1403 is pulled
    }

    public static void initNHPSPatch()
    {
        ClassPatch nhps = new ClassPatch("net.minecraft.network.NetHandlerPlayServer");
        nhps.methodMappings.add(new MethodMapping("func_147343_a", "processUpdateSign", "(Lnet/minecraft/network/play/client/C12PacketUpdateSign;)V", "Sign editing"){
            @Override
            public void defineMethod(ClassWriter classWriter) {
                MethodVisitor mv = classWriter.visitMethod(ACC_PUBLIC, getName(), "(Lnet/minecraft/network/play/client/C12PacketUpdateSign;)V", null, null);
                mv.visitCode();
View Full Code Here


        EventInjector.addClassPatch(nhps);
    }

    public static void initCommandHandlerPatches()
    {
        ClassPatch commandHandler = new ClassPatch("net.minecraft.command.CommandHandler");
        commandHandler.methodMappings.add(new MethodMapping("func_71558_b", "getPossibleCommands", "(Lnet/minecraft/command/ICommandSender;Ljava/lang/String;)Ljava/util/List;", "Permissions patch 1, CommandHandler") {
            @Override
            public void defineMethod(ClassWriter classWriter) {
                MethodVisitor mv = classWriter.visitMethod(ACC_PUBLIC, getName(), desc, null, null);
                mv.visitCode();
View Full Code Here

        EventInjector.addClassPatch(commandHandler);
    }

    public static void initEntityPlayerMPPatch()
    {
        ClassPatch patch = new ClassPatch("net.minecraft.entity.player.EntityPlayerMP");
        patch.methodMappings.add(new MethodMapping("func_70003_b", "canCommandSenderUseCommand", "(ILjava/lang/String;)Z", "Permissions (EntityPlayerMP)")
        {
            @Override public void defineMethod(ClassWriter classWriter)
            {
                MethodVisitor mv = classWriter.visitMethod(ACC_PUBLIC, getName(), "(ILjava/lang/String;)Z", null, null);
View Full Code Here

TOP

Related Classes of com.forgeessentials.core.preloader.asm.EventInjector.ClassPatch

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.