Jump to content

Recommended Posts

Posted

I call it from onKeyPressed() event. Now i can see my GUI and items, but I can't edit it.  Items just go back in their slots when I try to take them. Is it GUI problem or I need to fully setup my messages and message handlers first? I have class GUICustomPlayerInventory extends GuiContainer and separate inventory stored in extendedProperties of player. I want to fully replace standart player inventory with mine. What's simplier: to overriding player.inventory or using my current method?

Posted

I made message and message handler, but I can't open inventory again. Server receives message (it logs it) and then executes EntityPlayer.openGui method

@Override

    public IMessage onMessage(CustomPlayerOpenInventoryMessage message, MessageContext ctx) {

        if (ctx.side == Side.SERVER) {

            System.out.println("Received message from " + ctx.getServerHandler().playerEntity.getCommandSenderName());

            ((EntityPlayer) ctx.getServerHandler().playerEntity).openGui(TESItems.instance, 0, ((EntityPlayer) ctx.getServerHandler().playerEntity).worldObj, 0, 0, 0);

        }

        return null;

    }

 

Here's message class:

 

public class CustomPlayerOpenInventoryMessage implements IMessage {

 

    public CustomPlayerOpenInventoryMessage() {}

 

    @Override

    public void fromBytes(ByteBuf buf) {

    }

 

    @Override

    public void toBytes(ByteBuf buf) {

    }

}

 

 

Posted

full handler class:

 

public class CustomPlayerOpenInventoryHandler implements IMessageHandler<CustomPlayerOpenInventoryMessage, IMessage> {

 

    public CustomPlayerOpenInventoryHandler() {}

 

    @Override

    public IMessage onMessage(CustomPlayerOpenInventoryMessage message, MessageContext ctx) {

        if (ctx.side == Side.SERVER) {

            System.out.println("Received message from " + ctx.getServerHandler().playerEntity.getCommandSenderName());

            ((EntityPlayer) ctx.getServerHandler().playerEntity).openGui(TESItems.instance, 0, ((EntityPlayer) ctx.getServerHandler().playerEntity).worldObj, 0, 0, 0);

        }

        return null;

    }

}

 

 

 

Posted

Here's GUI handler:

 

public class CustomPlayerGUIHandler implements IGuiHandler {

    @Override

    public Object getServerGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {

        return new CustomPlayerContainer(player, player.inventory, ((CustomPlayer)player.getExtendedProperties("CustomPlayer")).inventory);

    }

    @Override

    public Object getClientGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {

        return new GUICustomPlayerInventory(player, player.inventory, ((CustomPlayer)player.getExtendedProperties("CustomPlayer")).inventory);

    }

}

 

,

message handler:

 

public class CustomPlayerOpenInventoryHandler implements IMessageHandler<CustomPlayerOpenInventoryMessage, IMessage> {

    public CustomPlayerOpenInventoryHandler() {}

    @Override

    public IMessage onMessage(CustomPlayerOpenInventoryMessage message, MessageContext ctx) {

        if (ctx.side == Side.SERVER) {

            System.out.println("Received message from " + ctx.getServerHandler().playerEntity.getCommandSenderName());

            ctx.getServerHandler().playerEntity.openGui(TESItems.instance, 0, ctx.getServerHandler().playerEntity.worldObj, 0, 0, 0);

        }

        return null;

    }

}

 

 

 

Registration of handlers:

 

networkWrapper = NetworkRegistry.INSTANCE.newSimpleChannel("customPlayerChannel");

networkWrapper.registerMessage(CustomPlayerOpenInventoryHandler.class, CustomPlayerOpenInventoryMessage.class, 1, Side.SERVER);

NetworkRegistry.INSTANCE.registerGuiHandler(this, new CustomPlayerGUIHandler());

 

It receives message, but GUI doesn't work

Posted

Here's key listener:

 

 

@SubscribeEvent

    public void onKeyInput(InputEvent.KeyInputEvent event) {

        if (!FMLClientHandler.instance().isGUIOpen(GuiChat.class)) {

            int kb = Keyboard.getEventKey();

            boolean isDown = Keyboard.getEventKeyState();

            if (kb == keys[CUSTOM_INV].getKeyCode()) {

                TESItems.networkWrapper.sendToServer(new CustomPlayerOpenInventoryMessage());

            }

        }

    }

 

 

I don't close GUI, and problem is not in it, because it was working earlier.

 

GUI:

public class GUICustomPlayerInventory extends GuiContainer {

    private int xSize = 218, ySize = 300;

    private final CustomPlayerInventory inventory;

    ResourceLocation resourceLocation = new ResourceLocation("tesitems:textures/gui/custom_inventory.png");

 

    public GUICustomPlayerInventory(EntityPlayer player, InventoryPlayer inventoryPlayer, CustomPlayerInventory inventoryCustom) {

        super(new CustomPlayerContainer(player, inventoryPlayer, inventoryCustom));

        this.inventory = inventoryCustom;

        this.guiLeft = (this.width - this.xSize) / 2;

        this.guiTop = (this.height - this.ySize) / 2;

    }

 

    @Override

    protected void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {

        GL11.glColor4f(0,0,0,100);

        Minecraft.getMinecraft().renderEngine.bindTexture(resourceLocation);

        GL11.glEnable(GL11.GL_BLEND);

        GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);

        Tessellator t = Tessellator.instance;

        t.startDrawingQuads();

        t.addVertexWithUV(guiLeft, guiTop, 0, 0, 0);

        t.addVertexWithUV(guiLeft, guiTop + ySize, 0, 0, 1);

        t.addVertexWithUV(guiLeft + xSize, guiTop + ySize, 0, 1, 1);

        t.addVertexWithUV(guiLeft + xSize, guiTop, 0, 1, 0);

        t.draw();

        GL11.glDisable(GL11.GL_BLEND);

    }

 

    @Override

    protected void drawGuiContainerForegroundLayer(int mouseX, int mouseY) {

    }

}

 

 

Posted

Only thing I can see is you are sending the message twice - once when the key is pressed, and again when it is released. You should add ' && isDown' to your condition.

 

You're not getting any error messages at all in your console log?

 

Show your Container class, then, since that is the only other thing that has been added since it stopped working.

Posted

Container:

 

public class CustomPlayerContainer extends Container {

    private static final int ARMOR_START = 0, ARMOR_END = 3, HANDS_START = 4, HANDS_END = 5, INV_START = 6;

    private static int INV_END;

 

    InventoryPlayer inventoryPlayer;

    CustomPlayerInventory customPlayerInventory;

 

    @Override

    public boolean canInteractWith(EntityPlayer player) {

        return true;

    }

 

    private int size;

 

    public CustomPlayerContainer(EntityPlayer player, InventoryPlayer inventoryPlayer, CustomPlayerInventory customPlayerInventory) {

        this.inventoryPlayer = inventoryPlayer;

        this.customPlayerInventory = customPlayerInventory;

        size = customPlayerInventory.getSizeInventory();

        INV_END = size-1;

        addSlotToContainer(new ArmorSlot(player, customPlayerInventory, 0, 10, 10, 0));//helmet

        addSlotToContainer(new ArmorSlot(player, customPlayerInventory, 1, 10, 29, 1));//chestplate

        addSlotToContainer(new ArmorSlot(player, customPlayerInventory, 2, 10, 48, 2));//leggings

        addSlotToContainer(new ArmorSlot(player, customPlayerInventory, 3, 10, 67, 3));//boots

        addSlotToContainer(new Slot(customPlayerInventory, 4, 29, 29));//hand 1

        addSlotToContainer(new Slot(customPlayerInventory, 5, 48, 29));//hand 2

        for (int i = 0; i < size; i++) {

            addSlotToContainer(new Slot(customPlayerInventory, 6 + i, 29 + i * 19, 10));

        }

    }

 

    public void updateSlots() {

        if (customPlayerInventory.getSizeInventory() > size) {

            for (int i = size; i < customPlayerInventory.getSizeInventory(); i++) {

                addSlotToContainer(new Slot(customPlayerInventory, 6 + size, 29 + i * 19, 10));

            }

        }

    }

 

    @Override

    public ItemStack transferStackInSlot(EntityPlayer player, int par2)

    {

        ItemStack itemstack = null;

        Slot slot = (Slot) this.inventorySlots.get(par2);

        if (slot != null && slot.getHasStack()) {

            ItemStack itemstack1 = slot.getStack();

            itemstack = itemstack1.copy();

            if (par2 < HANDS_START) {

                if (!this.mergeItemStack(itemstack1, HANDS_START, INV_END + 1, true)) {

                    return null;

                }

                slot.onSlotChange(itemstack1, itemstack);

            } else {

                if (itemstack1.getItem() instanceof ItemArmor) {

                    int type = ((ItemArmor) itemstack1.getItem()).armorType;

                    if (!this.mergeItemStack(itemstack1, ARMOR_START + type, ARMOR_START + type + 1, false)) {

                        return null;

                    }

                } else if (par2 >= INV_START) {

                    if (!this.mergeItemStack(itemstack1, HANDS_START, HANDS_END + 1, false)) {

                        return null;

                    }

                } else if (par2 >= HANDS_START && par2 < HANDS_END + 1) {

                    if (!this.mergeItemStack(itemstack1, INV_START, INV_END + 1, false)) {

                        return null;

                    }

                }

            }

            if (itemstack1.stackSize == 0) {

                slot.putStack((ItemStack) null);

            } else {

                slot.onSlotChanged();

            }

            if (itemstack1.stackSize == itemstack.stackSize) {

                return null;

            }

            slot.onPickupFromSlot(player, itemstack1);

        }

        return itemstack;

    }

 

 

    public class ArmorSlot extends Slot {

        final int armorType;

        final EntityPlayer player;

 

        public ArmorSlot(EntityPlayer player, IInventory inventory, int slot, int x, int y, int armorType) {

            super(inventory, slot, x, y);

            this.player = player;

            this.armorType = armorType;

        }

 

        public int getSlotStackLimit()

        {

            return 1;

        }

 

        public boolean isItemValid(ItemStack itemstack)

        {

            Item item = (itemstack == null ? null : itemstack.getItem());

            return item != null && item.isValidArmor(itemstack, armorType, player);

        }

 

        @SideOnly(Side.CLIENT)

        public IIcon getBackgroundIconIndex()

        {

            return ItemArmor.func_94602_b(this.armorType);

        }

    }

}

 

 

 

All I get when press key is

 

[19:25:22] [server thread/INFO] [sTDOUT]: [ru.iammaxim.tesitems.Player.CustomPlayerOpenInventoryHandler:onMessage:21]: Received message from Player72

 

Posted

I register it from

@EventHandler

public void preInit(FMLInitializationEvent event)

with NetworkRegistry.INSTANCE.registerGuiHandler(this, new CustomPlayerGUIHandler());

Posted

I register it from

@EventHandler

public void preInit(FMLInitializationEvent event)

with NetworkRegistry.INSTANCE.registerGuiHandler(this, new CustomPlayerGUIHandler());

Why is your FMLInitializationEvent handled in a method named 'preInit'? Is that an accident?

 

Anyway, can you show your entire Main class? Something in there is not right.

Posted

Main class:

 

@Mod(modid = TESItems.MODID, version = TESItems.VERSION)

public class TESItems

{

    public static SimpleNetworkWrapper networkWrapper;

    public static TESItems instance = new TESItems();

 

    private static int modGuiIndex = 0;

    public static final int customInventoryGUIIndex = modGuiIndex++;

 

    public static final String MODID = "tesitems";

    public static final String VERSION = "1.0";

 

    public static Material dwarven_material;

 

    //Damage modifiers

    public static final float daggerDamageModifier = 1.0f,

            swordDamageModifier = 1.5f,

            waraxeDamageModifier = 2.2f,

            greadswordDamageModifier = 2.0f,

            maceDamageModifier = 1.8f,

            axeDamageModifier = 1.7f;

 

    public static int dungeon_generator_mode = 0,

        room_width = 10,

        room_height = 10,

        room_length = 10;

 

    public static DungeonGeneratorItem dungeon_generator_item;

 

    public static GenericBlock dungeon_generator_block,

            dwarven_block_01,

            dungeon_bricks_01,

            dungeon_bricks_02,

            dungeon_bricks_03,

            dungeon_bricks_04,

            dungeon_bricks_05,

            dungeon_bricks_06,

            dungeon_bricks_07,

            dungeon_bricks_07_lamp,

            dungeon_bricks_08,

            dungeon_bricks_09,

            dungeon_bricks_09_lamp,

            dirt_01,

            dirt_02,

            planks_01,

            planks_02,

            grass_01_top,

            bark_01,

            bricks_block_01;

 

    public static DwarvenDoor dwarven_door;

    public static DwarvenDoorItem dwarven_door_item;

    public static dwarven_pipe_block dwarven_pipe;

    public static TableBlock table_block;

 

    //Clothes

    public static ItemArmor.ArmorMaterial clothMaterial = EnumHelper.addArmorMaterial("Cloth", 1000, new int[]{0,0,0,0}, 100);;

    /*public static ClothesItemArmor clothes01_helmet;

    public static ClothesItemArmor clothes01_chestplate;

    public static ClothesItemArmor clothes01_leggings;

    public static ClothesItemArmor clothes01_boots;*/

 

    //Armor

    public static ItemArmor.ArmorMaterial daedricArmorMaterial = EnumHelper.addArmorMaterial("Daedric", 37, new int[]{4,10,4,2}, 25);

    public static ItemArmor.ArmorMaterial ebonyArmorMaterial = EnumHelper.addArmorMaterial("Ebony", 37, new int[]{4,9,3,2}, 25);

    public static ItemArmor.ArmorMaterial dragonArmorMaterial = EnumHelper.addArmorMaterial("Dragon", 37, new int[]{4,8,3,3}, 25);

    public static ItemArmor.ArmorMaterial dwarvenArmorMaterial = EnumHelper.addArmorMaterial("Dwarven", 37, new int[]{3,8,3,2}, 25);

    public static ItemArmor.ArmorMaterial orcishArmorMaterial = EnumHelper.addArmorMaterial("Orcish", 37, new int[]{2,7,3,2}, 25);

    public static ItemArmor.ArmorMaterial glassArmorMaterial = EnumHelper.addArmorMaterial("Glass", 37, new int[]{2,7,3,2}, 25);

    public static ItemArmor.ArmorMaterial steelArmorMaterial = EnumHelper.addArmorMaterial("Steel", 37, new int[]{2,6,3,1}, 25);

    public static ItemArmor.ArmorMaterial elvenArmorMaterial = EnumHelper.addArmorMaterial("Elven", 37, new int[]{2,6,3,1}, 25);

    public static ItemArmor.ArmorMaterial ironArmorMaterial = EnumHelper.addArmorMaterial("Iron", 37, new int[]{2,5,2,1}, 25);

    public static ItemArmor.ArmorMaterial mithrilArmorMaterial = EnumHelper.addArmorMaterial("Mithril", 37, new int[]{2,5,2,1}, 25);

    public static ItemArmor.ArmorMaterial chainArmorMaterial = EnumHelper.addArmorMaterial("Chain", 37, new int[]{2,4,2,1}, 25);

    public static ItemArmor.ArmorMaterial hideArmorMaterial = EnumHelper.addArmorMaterial("Hide", 37, new int[]{1,1,1,1}, 25);

    public static ItemArmor.ArmorMaterial dawnguardArmorMaterial = EnumHelper.addArmorMaterial("Dawnguard", 37, new int[]{4,9,7,4}, 25);

 

    //Damage

    public static float daedricDamage = 5,

            dawnbreakerDamage = 5,

            dragonDamage = 4.5f,

            dwarvenDamage = 4,

            ebonyDamage = 4,

            elvenDamage = 4,

            emeraldDamage = 3.5f,

            falmerDamage = 3,

            forswornDamage = 3.5f,

            glassDamage = 4,

            headsmansDamage = 4,

            imperialDamage = 3,

            ironDamage = 2.5f,

            notchedDamage = 2,

            orcishDamage = 4.5f,

            silverDamage = 2,

            stalhrimDamage = 4,

            steelDamage = 3,

            wuuthradDamage = 2.5f;

 

    public static Item daedric_sword,

            daedric_mace,

            dawnbreaker,

            dragon_sword,

            dragon_waraxe,

            dwarven_axe,

            dwarven_sword,

            ebony_dagger,

            ebony_mace,

            ebony_waraxe,

            elven_sword,

            elven_waraxe,

            emerald_sword,

            falmer_axe,

            falmer_sword,

            forsworn_sword,

            glass_axe,

            glass_dagger,

            glass_sword,

            headsmans_axe,

            imperial_sword,

            iron_greatsword,

            notched_pickaxe,

            orcish_mace,

            orcish_sword,

            silver_sword,

            stalhrim_battleaxe,

            stalhrim_sword,

            steel_mace,

            steel_sword,

            steel_waraxe,

            wuuthrad;

 

    public static BlacksmithBlock blacksmith_block;

    public static Septim_coin septim_coin;

 

    //Material01

    public static final Item.ToolMaterial material01 = EnumHelper.addToolMaterial("material01", 3, 10, 15, 7, 100);

 

    @EventHandler

    public void serverStarting(FMLServerStartingEvent event)

    {

        event.registerServerCommand(new dungeonGeneratorCommands());

        event.registerServerCommand(new TestCommands());

    }

 

    @EventHandler

    public void Init(FMLInitializationEvent event)

    {

        networkWrapper = NetworkRegistry.INSTANCE.newSimpleChannel("customPlayerChannel");

        networkWrapper.registerMessage(CustomPlayerMessageHandler.class, CustomPlayerMessage.class, 0, Side.SERVER);

        networkWrapper.registerMessage(CustomPlayerOpenInventoryHandler.class, CustomPlayerOpenInventoryMessage.class, 1, Side.SERVER);

        NetworkRegistry.INSTANCE.registerGuiHandler(this, new CustomPlayerGUIHandler());

        MinecraftForge.EVENT_BUS.register(new CustomPlayerHandler());

 

        dwarven_material = new Material(MapColor.yellowColor);

 

        GameRegistry.registerTileEntity(dwarven_pipe_tileEntity.class, "dwarven_pipe_tile_entity");

        GameRegistry.registerTileEntity(TableTileEntity.class, "table_tile_entity");

 

        //Register weapon

        GameRegistry.registerItem(daedric_sword =      new ItemSword(createToolMaterial("Daedric", 1500, daedricDamage * swordDamageModifier)).setUnlocalizedName("daedric_sword").setTextureName("tesitems:daedricsword").setCreativeTab(CreativeTabs.tabCombat), "daedric_sword");

        GameRegistry.registerItem(daedric_mace =        new ItemSword(createToolMaterial("Daedric", 1500, daedricDamage * maceDamageModifier)).setUnlocalizedName("daedric_mace").setTextureName("tesitems:daedricmace").setCreativeTab(CreativeTabs.tabCombat), "daedric_mace");

        GameRegistry.registerItem(dawnbreaker =        new ItemSword(createToolMaterial("Dawnbreaker", 1700, dawnbreakerDamage * swordDamageModifier)).setUnlocalizedName("dawnbreaker").setTextureName("tesitems:dawnbreaker").setCreativeTab(CreativeTabs.tabCombat), "dawnbreaker");

        GameRegistry.registerItem(dragon_sword =        new ItemSword(createToolMaterial("Dragon", 1700, dragonDamage * swordDamageModifier)).setUnlocalizedName("dragon_sword").setTextureName("tesitems:dragonsword").setCreativeTab(CreativeTabs.tabCombat), "dragon_sword");

        GameRegistry.registerItem(dragon_waraxe =      new ItemSword(createToolMaterial("Dragon", 1700, dragonDamage * waraxeDamageModifier)).setUnlocalizedName("dragon_waraxe").setTextureName("tesitems:dragonwaraxe").setCreativeTab(CreativeTabs.tabCombat), "dragon_waraxe");

        GameRegistry.registerItem(dwarven_axe =        new ItemSword(createToolMaterial("Dwarven", 1300, dwarvenDamage * axeDamageModifier)).setUnlocalizedName("dwarven_axe").setTextureName("tesitems:dwarvenaxe").setCreativeTab(CreativeTabs.tabCombat), "dwarven_axe");

        GameRegistry.registerItem(dwarven_sword =      new ItemSword(createToolMaterial("Dwarven", 1300,daedricDamage * swordDamageModifier)).setUnlocalizedName("dwarven_sword").setTextureName("tesitems:dwarvensword").setCreativeTab(CreativeTabs.tabCombat), "dwarven_sword");

        GameRegistry.registerItem(ebony_dagger =        new ItemSword(createToolMaterial("Ebony", 1200, ebonyDamage * daggerDamageModifier)).setUnlocalizedName("ebony_dagger").setTextureName("tesitems:ebonydagger").setCreativeTab(CreativeTabs.tabCombat), "ebony_dagger");

        GameRegistry.registerItem(ebony_mace =          new ItemSword(createToolMaterial("Ebony", 1200, ebonyDamage * maceDamageModifier)).setUnlocalizedName("ebony_mace").setTextureName("tesitems:ebonymace").setCreativeTab(CreativeTabs.tabCombat), "ebony_mace");

        GameRegistry.registerItem(ebony_waraxe =        new ItemSword(createToolMaterial("Ebony", 1200, ebonyDamage * waraxeDamageModifier)).setUnlocalizedName("ebony_waraxe").setTextureName("tesitems:ebonywaraxe").setCreativeTab(CreativeTabs.tabCombat), "ebony_waraxe");

        GameRegistry.registerItem(elven_sword =        new ItemSword(createToolMaterial("Elven", 1200, elvenDamage * swordDamageModifier)).setUnlocalizedName("elven_sword").setTextureName("tesitems:elvensword").setCreativeTab(CreativeTabs.tabCombat), "elven_sword");

        GameRegistry.registerItem(elven_waraxe =        new ItemSword(createToolMaterial("Elven", 1200, elvenDamage * waraxeDamageModifier)).setUnlocalizedName("elven_waraxe").setTextureName("tesitems:elvenwaraxe").setCreativeTab(CreativeTabs.tabCombat), "elven_waraxe");

        GameRegistry.registerItem(emerald_sword =      new ItemSword(createToolMaterial("Emerald", 1400, emeraldDamage * swordDamageModifier)).setUnlocalizedName("emerald_sword").setTextureName("tesitems:emeraldsword").setCreativeTab(CreativeTabs.tabCombat), "emerald_sword");

        GameRegistry.registerItem(falmer_axe =          new ItemSword(createToolMaterial("Falmer", 800, falmerDamage * axeDamageModifier)).setUnlocalizedName("falmer_axe").setTextureName("tesitems:falmeraxe").setCreativeTab(CreativeTabs.tabCombat), "falmer_axe");

        GameRegistry.registerItem(falmer_sword =        new ItemSword(createToolMaterial("Falmer", 800, falmerDamage * swordDamageModifier)).setUnlocalizedName("falmer_sword").setTextureName("tesitems:falmersword").setCreativeTab(CreativeTabs.tabCombat), "falmer_sword");

        GameRegistry.registerItem(forsworn_sword =      new ItemSword(createToolMaterial("Forsworn", 1500, forswornDamage * swordDamageModifier)).setUnlocalizedName("forsworn_sword").setTextureName("tesitems:forswornsword").setCreativeTab(CreativeTabs.tabCombat), "forsworn_sword");

        GameRegistry.registerItem(glass_axe =          new ItemSword(createToolMaterial("Glass", 1300, glassDamage * axeDamageModifier)).setUnlocalizedName("glass_axe").setTextureName("tesitems:glassaxe").setCreativeTab(CreativeTabs.tabCombat), "glass_axe");

        GameRegistry.registerItem(glass_dagger =        new ItemSword(createToolMaterial("Glass", 1300, glassDamage * daggerDamageModifier)).setUnlocalizedName("glass_dagger").setTextureName("tesitems:glassdagger").setCreativeTab(CreativeTabs.tabCombat), "glass_dagger");

        GameRegistry.registerItem(glass_sword =        new ItemSword(createToolMaterial("Glass", 1300, glassDamage * swordDamageModifier)).setUnlocalizedName("glass_sword").setTextureName("tesitems:glasssword").setCreativeTab(CreativeTabs.tabCombat), "glass_sword");

        GameRegistry.registerItem(headsmans_axe =      new ItemSword(createToolMaterial("Headsman", 1200, headsmansDamage * axeDamageModifier)).setUnlocalizedName("headsmans_axe").setTextureName("tesitems:headsmansaxe").setCreativeTab(CreativeTabs.tabCombat), "headsmans_axe");

        GameRegistry.registerItem(imperial_sword =      new ItemSword(createToolMaterial("Imperial", 800, imperialDamage * swordDamageModifier)).setUnlocalizedName("imperial_sword").setTextureName("tesitems:imperialsword").setCreativeTab(CreativeTabs.tabCombat), "imperial_sword");

        GameRegistry.registerItem(iron_greatsword =    new ItemSword(createToolMaterial("Iron", 800, ironDamage * greadswordDamageModifier)).setUnlocalizedName("iron_greatsword").setTextureName("tesitems:irongreatsword").setCreativeTab(CreativeTabs.tabCombat), "iron_greatsword");

        GameRegistry.registerItem(notched_pickaxe =    new ItemSword(createToolMaterial("Notched", 2, 600, 0, notchedDamage * axeDamageModifier, 20)).setUnlocalizedName("notched_pickaxe").setTextureName("tesitems:notchedpickaxe").setCreativeTab(CreativeTabs.tabCombat), "notched_pickaxe");

        GameRegistry.registerItem(orcish_mace =        new ItemSword(createToolMaterial("Orcish", 1500, orcishDamage * maceDamageModifier)).setUnlocalizedName("orcish_mace").setTextureName("tesitems:orcishmace").setCreativeTab(CreativeTabs.tabCombat), "orcish_mace");

        GameRegistry.registerItem(orcish_sword =        new ItemSword(createToolMaterial("Orcish", 1500, orcishDamage * swordDamageModifier)).setUnlocalizedName("orcish_sword").setTextureName("tesitems:orcishsword").setCreativeTab(CreativeTabs.tabCombat), "orcish_sword");

        GameRegistry.registerItem(silver_sword =        new ItemSword(createToolMaterial("Silver", 800, silverDamage * swordDamageModifier)).setUnlocalizedName("silver_sword").setTextureName("tesitems:silversword").setCreativeTab(CreativeTabs.tabCombat), "silver_sword");

        GameRegistry.registerItem(stalhrim_battleaxe =  new ItemSword(createToolMaterial("Stalhrim", 700, stalhrimDamage * waraxeDamageModifier)).setUnlocalizedName("stalhrim_battleaxe").setTextureName("tesitems:stalhrimbattleaxe").setCreativeTab(CreativeTabs.tabCombat), "stalhrim_battleaxe");

        GameRegistry.registerItem(stalhrim_sword =      new ItemSword(createToolMaterial("Stalhrim", 700, stalhrimDamage * swordDamageModifier)).setUnlocalizedName("stalhrim_sword").setTextureName("tesitems:stalhrimsword").setCreativeTab(CreativeTabs.tabCombat), "stalhrim_sword");

        GameRegistry.registerItem(steel_mace =          new ItemSword(createToolMaterial("Steel", 1000, steelDamage * maceDamageModifier)).setUnlocalizedName("steel_mace").setTextureName("tesitems:steelmace").setCreativeTab(CreativeTabs.tabCombat), "steel_mace");

        GameRegistry.registerItem(steel_sword =        new ItemSword(createToolMaterial("Steel", 1000, steelDamage * swordDamageModifier)).setUnlocalizedName("steel_sword").setTextureName("tesitems:steelsword").setCreativeTab(CreativeTabs.tabCombat), "steel_sword");

        GameRegistry.registerItem(steel_waraxe =        new ItemSword(createToolMaterial("Steel", 1000, steelDamage * waraxeDamageModifier)).setUnlocalizedName("steel_waraxe").setTextureName("tesitems:steelwaraxe").setCreativeTab(CreativeTabs.tabCombat), "steel_waraxe");

        GameRegistry.registerItem(wuuthrad =            new ItemSword(createToolMaterial("Wuutrad", 300, wuuthradDamage * waraxeDamageModifier)).setUnlocalizedName("wuuthrad").setTextureName("tesitems:wuuthrad").setCreativeTab(CreativeTabs.tabCombat), "wuuthrad");

 

 

        //Register dungeon generator

        dungeon_generator_item = new DungeonGeneratorItem();

        GameRegistry.registerItem(dungeon_generator_item, "dungeon_generator_item");

        GameRegistry.registerBlock(dungeon_generator_block = new GenericBlock(Material.iron, "dungeon_generator_block", "dungeon_generator_block", 1, Block.soundTypeMetal, CreativeTabs.tabMisc), dungeon_generator_block.getUnlocalizedName());

 

        //Register blocks

        GameRegistry.registerBlock(dwarven_door = new DwarvenDoor(dwarven_material), "dwarven_door");

        GameRegistry.registerBlock(dwarven_block_01 = new GenericBlock(Material.iron, "dwarven_block_01", "dwarven_block_01", 5, Block.soundTypeMetal, CreativeTabs.tabBlock), "dwarven_block_01");

        GameRegistry.registerBlock(dwarven_pipe = new dwarven_pipe_block(Material.iron), "dwarven_pipe");

        GameRegistry.registerBlock(dungeon_bricks_01 = new GenericBlock(Material.rock, "dungeon_bricks_01", "dungeon_bricks_01", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_01");

        GameRegistry.registerBlock(dungeon_bricks_02 = new GenericBlock(Material.rock, "dungeon_bricks_02", "dungeon_bricks_02", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_02");

        GameRegistry.registerBlock(dungeon_bricks_03 = new GenericBlock(Material.rock, "dungeon_bricks_03", "dungeon_bricks_03", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_03");

        GameRegistry.registerBlock(dungeon_bricks_04 = new GenericBlock(Material.rock, "dungeon_bricks_04", "dungeon_bricks_04", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_04");

        GameRegistry.registerBlock(dungeon_bricks_05 = new GenericBlock(Material.rock, "dungeon_bricks_05", "dungeon_bricks_05", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_05");

        GameRegistry.registerBlock(dungeon_bricks_06 = new GenericBlock(Material.rock, "dungeon_bricks_06", "dungeon_bricks_06", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_06");

        GameRegistry.registerBlock(dungeon_bricks_07 = new GenericBlock(Material.rock, "dungeon_bricks_07", "dungeon_bricks_07", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_07");

        GameRegistry.registerBlock(dungeon_bricks_07_lamp = (GenericBlock) new GenericBlock(Material.rock, "dungeon_bricks_07_lamp", "dungeon_bricks_07_lamp", 4, Block.soundTypeStone, CreativeTabs.tabBlock).setLightLevel(1), "dungeon_bricks_07_lamp");

        GameRegistry.registerBlock(dungeon_bricks_08 = new GenericBlock(Material.rock, "dungeon_bricks_08", "dungeon_bricks_08", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_08");

        GameRegistry.registerBlock(dungeon_bricks_09 = new GenericBlock(Material.rock, "dungeon_bricks_09", "dungeon_bricks_09", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "dungeon_bricks_09");

        GameRegistry.registerBlock(dungeon_bricks_09_lamp = (GenericBlock) new GenericBlock(Material.rock, "dungeon_bricks_09_lamp", "dungeon_bricks_09_lamp", 4, Block.soundTypeStone, CreativeTabs.tabBlock).setLightLevel(1), "dungeon_bricks_09_lamp");

        GameRegistry.registerBlock(bricks_block_01 = new GenericBlock(Material.rock, "bricks_block_01", "bricks_block_01", 4, Block.soundTypeStone, CreativeTabs.tabBlock), "bricks_block_01");

        GameRegistry.registerBlock(dirt_01 = new GenericBlock(Material.ground, "dirt_01", "dirt_01", 4, Block.soundTypeGravel, CreativeTabs.tabBlock), "dirt_01");

        GameRegistry.registerBlock(dirt_02 = new GenericBlock(Material.ground, "dirt_02", "dirt_02", 4, Block.soundTypeGravel, CreativeTabs.tabBlock), "dirt_02");

        GameRegistry.registerBlock(grass_01_top = new GenericBlock(Material.ground, "grass_01_top", "grass_01_top", 4, Block.soundTypeGrass, CreativeTabs.tabBlock), "grass_01_top");

        GameRegistry.registerBlock(planks_01 = new GenericBlock(Material.wood, "planks_01", "planks_01", 4, Block.soundTypeWood, CreativeTabs.tabBlock), "planks_01");

        GameRegistry.registerBlock(planks_02 = new GenericBlock(Material.wood, "planks_02", "planks_02", 4, Block.soundTypeWood, CreativeTabs.tabBlock), "planks_02");

        GameRegistry.registerBlock(bark_01 = new GenericBlock(Material.wood, "bark_01", "bark_01", 4, Block.soundTypeWood, CreativeTabs.tabBlock), "bark_01");

        GameRegistry.registerBlock(table_block = new TableBlock(Material.wood), "table_block");

        //GameRegistry.registerBlock(blacksmith_block = new BlacksmithBlock(Material.iron), "blacksmith_block");

 

        //Register items

        GameRegistry.registerItem(dwarven_door_item = new DwarvenDoorItem(dwarven_material), "dwarven_door_item");

        GameRegistry.registerItem(septim_coin = new Septim_coin(), "septim_coin");

 

 

        //Register clothes

        /*clothes01_helmet = new ClothesItemArmor("clothes_01", clothMaterial, "clothes_01", 0);

        GameRegistry.registerItem(clothes01_helmet, "clothes01_helmet");

        clothes01_chestplate = new ClothesItemArmor("clothes_01", clothMaterial, "clothes_01", 1);

        GameRegistry.registerItem(clothes01_chestplate, "clothes01_chestplate");

        clothes01_leggings = new ClothesItemArmor("clothes_01", clothMaterial, "clothes_01", 2);

        GameRegistry.registerItem(clothes01_leggings, "clothes01_leggings");

        clothes01_boots = new ClothesItemArmor("clothes_01", clothMaterial, "clothes_01", 3);

        GameRegistry.registerItem(clothes01_boots, "clothes01_boots");*/

 

        GameRegistry.registerItem(new ClothesItemArmor("clothes_helmet", clothMaterial, "clothes_01", 0), "clothes01_helmet");

        GameRegistry.registerItem(new ClothesItemArmor("clothes_chestplate", clothMaterial, "clothes_01", 1), "clothes01_chestplate");

        GameRegistry.registerItem(new ClothesItemArmor("clothes_leggings", clothMaterial, "clothes_01", 2), "clothes01_leggings");

        GameRegistry.registerItem(new ClothesItemArmor("clothes_boots", clothMaterial, "clothes_01", 3), "clothes01_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("daedric_helmet", daedricArmorMaterial, "daedric", 0), "daedric_helmet");

        GameRegistry.registerItem(new GenericItemArmor("daedric_chestplate", daedricArmorMaterial, "daedric", 1), "daedric_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("daedric_leggings", daedricArmorMaterial, "daedric", 2), "daedric_leggings");

        GameRegistry.registerItem(new GenericItemArmor("daedric_boots", daedricArmorMaterial, "daedric", 3), "daedric_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("dawnguard_helmet", dawnguardArmorMaterial, "dawnguard", 0), "dawnguard_helmet");

        GameRegistry.registerItem(new GenericItemArmor("dawnguard_chestplate", dawnguardArmorMaterial, "dawnguard", 1), "dawnguard_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("dawnguard_leggings", dawnguardArmorMaterial, "dawnguard", 2), "dawnguard_leggings");

        GameRegistry.registerItem(new GenericItemArmor("dawnguard_boots", dawnguardArmorMaterial, "dawnguard", 3), "dawnguard_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("dragon_helmet", dragonArmorMaterial, "dragon", 0), "dragon_helmet");

        GameRegistry.registerItem(new GenericItemArmor("dragon_chestplate", dragonArmorMaterial, "dragon", 1), "dragon_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("dragon_leggings", dragonArmorMaterial, "dragon", 2), "dragon_leggings");

        GameRegistry.registerItem(new GenericItemArmor("dragon_boots", dragonArmorMaterial, "dragon", 3), "dragon_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("dwarven_helmet", dwarvenArmorMaterial, "dwarven", 0), "dwarven_helmet");

        GameRegistry.registerItem(new GenericItemArmor("dwarven_chestplate", dwarvenArmorMaterial, "dwarven", 1), "dwarven_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("dwarven_leggings", dwarvenArmorMaterial, "dwarven", 2), "dwarven_leggings");

        GameRegistry.registerItem(new GenericItemArmor("dwarven_boots", dwarvenArmorMaterial, "dwarven", 3), "dwarven_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("elven_helmet", elvenArmorMaterial, "elven", 0), "elven_helmet");

        GameRegistry.registerItem(new GenericItemArmor("elven_chestplate", elvenArmorMaterial, "elven", 1), "elven_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("elven_leggings", elvenArmorMaterial, "elven", 2), "elven_leggings");

        GameRegistry.registerItem(new GenericItemArmor("elven_boots", elvenArmorMaterial, "elven", 3), "elven_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("hide_helmet", hideArmorMaterial, "hide", 0), "hide_helmet");

        GameRegistry.registerItem(new GenericItemArmor("hide_chestplate", hideArmorMaterial, "hide", 1), "hide_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("hide_leggings", hideArmorMaterial, "hide", 2), "hide_leggings");

        GameRegistry.registerItem(new GenericItemArmor("hide_boots", hideArmorMaterial, "hide", 3), "hide_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("iron_helmet", ironArmorMaterial, "iron", 0), "iron_helmet");

        GameRegistry.registerItem(new GenericItemArmor("iron_chestplate", ironArmorMaterial, "iron", 1), "iron_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("iron_leggings", ironArmorMaterial, "iron", 2), "iron_leggings");

        GameRegistry.registerItem(new GenericItemArmor("iron_boots", ironArmorMaterial, "iron", 3), "iron_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("glass_helmet", glassArmorMaterial, "glass", 0), "glass_helmet");

        GameRegistry.registerItem(new GenericItemArmor("glass_chestplate", glassArmorMaterial, "glass", 1), "glass_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("glass_leggings", glassArmorMaterial, "glass", 2), "glass_leggings");

        GameRegistry.registerItem(new GenericItemArmor("glass_boots", glassArmorMaterial, "glass", 3), "glass_boots");

 

        GameRegistry.registerItem(new GenericItemArmor("steel_helmet", steelArmorMaterial, "steel", 0), "steel_helmet");

        GameRegistry.registerItem(new GenericItemArmor("steel_chestplate", steelArmorMaterial, "steel", 1), "steel_chestplate");

        GameRegistry.registerItem(new GenericItemArmor("steel_leggings", steelArmorMaterial, "steel", 2), "steel_leggings");

        GameRegistry.registerItem(new GenericItemArmor("steel_boots", steelArmorMaterial, "steel", 3), "steel_boots");

    }

 

    @EventHandler

    @SideOnly(Side.CLIENT)

    public void Load(FMLInitializationEvent event) {

        ClientRegistry.bindTileEntitySpecialRenderer(dwarven_pipe_tileEntity.class, new dwarven_pipe_special_renderer());

        ClientRegistry.bindTileEntitySpecialRenderer(TableTileEntity.class, new TableSpecialRenderer());

        MinecraftForge.EVENT_BUS.register(new RenderHandler());

        FMLCommonHandler.instance().bus().register(new GUIEventHandler());

    }

 

    @EventHandler

    public void postInit(FMLInitializationEvent event) {

        Item.getItemFromBlock(Blocks.log).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.log2).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.stone).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.cobblestone).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.hardened_clay).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.clay).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.gravel).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.mossy_cobblestone).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.dirt).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.obsidian).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.sand).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.sandstone).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.brick_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.quartz_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.stonebrick).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.bookshelf).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.lapis_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.coal_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.diamond_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.gold_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.iron_block).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.netherrack).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.nether_brick).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.stone_slab).setMaxStackSize(2);

        Item.getItemFromBlock(Blocks.wooden_slab).setMaxStackSize(2);

        Item.getItemFromBlock(Blocks.stone_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.acacia_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.birch_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.brick_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.dark_oak_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.jungle_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.nether_brick_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.oak_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.quartz_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.sandstone_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.spruce_stairs).setMaxStackSize(1);

        Item.getItemFromBlock(Blocks.stone_brick_stairs).setMaxStackSize(1);

    }

}

 

 

Posted

Your mod instance is missing its annotation; it should be like this:

@Mod.Instance(TESItems.MODID,)
public static TESItems instance;

 

Also, you are handling the FMLInitializationEvent THREE times... you should only do so once. There are also FMLPreInitializationEvent and FMLPostInitializationEvent events which you can use.

 

Do NOT use @SideOnly in your Main class. Ever. Use the proxy system, which you do not have at all in your mod...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • should the changes apply only to the listed ores, or do you want a more comprehensive overhaul of resource progression?
    • The information provided isn’t quite enough to pinpoint the issue. It would be helpful to know more about your setup. For instance, what screen recording software are you using, and is it set to capture the game window, full screen, or your entire desktop?
    • I had the same issue, so I ended up registering through gmail
    • I am trying to make an attack animation works for this entity, I have followed tutorials on youtube, looked into Geckolib's documentation but I can't find why it isn't working. The walking animation works, the mob recognizes the player and attack them. The model and animations were made in Blockbench.   public class RedSlimeEntity extends TensuraTamableEntity implements IAnimatable { private final AnimationFactory factory = GeckoLibUtil.createFactory(this); private boolean swinging; private long lastAttackTime; public RedSlimeEntity(EntityType<? extends RedSlimeEntity> type, Level worldIn) { super(type, worldIn); this.xpReward = 20; } public static AttributeSupplier.Builder createAttributes() { AttributeSupplier.Builder builder = Mob.createMobAttributes(); builder = builder.add(Attributes.MOVEMENT_SPEED, 0.1); builder = builder.add(Attributes.MAX_HEALTH, 50); builder = builder.add(Attributes.ARMOR, 0); builder = builder.add(Attributes.ATTACK_DAMAGE, 25); builder = builder.add(Attributes.FOLLOW_RANGE, 16); return builder; } public static void init() { } @Override protected void registerGoals() { this.goalSelector.addGoal(3, new FloatGoal(this)); this.goalSelector.addGoal(1, new RedSlimeAttackGoal(this, 1.2D, false)); this.goalSelector.addGoal(4, new WaterAvoidingRandomStrollGoal(this, 1.0D)); this.goalSelector.addGoal(5, new RandomLookAroundGoal(this)); this.goalSelector.addGoal(2, new RedSlimeAttackGoal.StopNearPlayerGoal(this, 1)); this.targetSelector.addGoal(2, new NearestAttackableTargetGoal<>(this, Player.class, true)); } private <E extends IAnimatable> PlayState predicate(AnimationEvent<E> event) { if (event.isMoving()) { event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.model.walk", true)); return PlayState.CONTINUE; } event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.model.idle", true)); return PlayState.CONTINUE; } private <E extends IAnimatable> PlayState attackPredicate(AnimationEvent<E> event) { if (this.swinging && event.getController().getAnimationState() == AnimationState.Stopped) { event.getController().setAnimation(new AnimationBuilder().addAnimation("animation.model.attack", false)); this.swinging = false; return PlayState.CONTINUE; } return PlayState.STOP; } @Override public void swing(InteractionHand hand, boolean updateSelf) { super.swing(hand, updateSelf); this.swinging = true; } @Override public void registerControllers(AnimationData data) { data.addAnimationController(new AnimationController<>(this, "controller", 0, this::predicate)); data.addAnimationController(new AnimationController<>(this, "attackController", 0, this::attackPredicate)); } @Override public AnimationFactory getFactory() { return factory; } class RedSlimeAttackGoal extends MeleeAttackGoal { private final RedSlimeEntity entity; public RedSlimeAttackGoal(RedSlimeEntity entity, double speedModifier, boolean longMemory) { super(entity, speedModifier, longMemory); this.entity = entity; if (this.mob.getTarget() != null && this.mob.getTarget().isAlive()) { long currentTime = this.entity.level.getGameTime(); if (!this.entity.swinging && currentTime - this.entity.lastAttackTime > 20) { // 20 ticks = 1 second this.entity.swinging = true; this.entity.lastAttackTime = currentTime; } } } protected double getAttackReach(LivingEntity target) { return this.mob.getBbWidth() * 2.0F * this.mob.getBbWidth() * 2.0F + target.getBbWidth(); } @Override protected void checkAndPerformAttack(LivingEntity target, double distToEnt) { double reach = this.getAttackReach(target); if (distToEnt <= reach && this.getTicksUntilNextAttack() <= 0) { this.resetAttackCooldown(); this.entity.swinging = true; this.mob.doHurtTarget(target); } } public static class StopNearPlayerGoal extends Goal { private final Mob mob; private final double stopDistance; public StopNearPlayerGoal(Mob mob, double stopDistance) { this.mob = mob; this.stopDistance = stopDistance; } @Override public boolean canUse() { Player nearestPlayer = this.mob.level.getNearestPlayer(this.mob, stopDistance); if (nearestPlayer != null) { double distanceSquared = this.mob.distanceToSqr(nearestPlayer); return distanceSquared < (stopDistance * stopDistance); } return false; } @Override public void tick() { // Stop movement this.mob.getNavigation().stop(); } @Override public boolean canContinueToUse() { Player nearestPlayer = this.mob.level.getNearestPlayer(this.mob, stopDistance); if (nearestPlayer != null) { double distanceSquared = this.mob.distanceToSqr(nearestPlayer); return distanceSquared < (stopDistance * stopDistance); } return false; } } @Override public void tick() { super.tick(); if (this.mob.getTarget() != null && this.mob.getTarget().isAlive()) { if (!this.entity.swinging) { this.entity.swinging = true; } } } } @Override public @Nullable AgeableMob getBreedOffspring(ServerLevel serverLevel, AgeableMob ageableMob) { return null; } @Override public int getRemainingPersistentAngerTime() { return 0; } @Override public void setRemainingPersistentAngerTime(int i) { } @Override public @Nullable UUID getPersistentAngerTarget() { return null; } @Override public void setPersistentAngerTarget(@Nullable UUID uuid) { } @Override public void startPersistentAngerTimer() { } protected void playStepSound(BlockPos pos, BlockState blockIn) { this.playSound(SoundEvents.SLIME_SQUISH, 0.15F, 1.0F); } protected SoundEvent getAmbientSound() { return SoundEvents.SLIME_SQUISH; } protected SoundEvent getHurtSound(DamageSource damageSourceIn) { return SoundEvents.SLIME_HURT; } protected SoundEvent getDeathSound() { return SoundEvents.SLIME_DEATH; } protected float getSoundVolume() { return 0.2F; } }  
    • CAN ANYBODY HELP ME? JVM info: Oracle Corporation - 1.8.0_431 - 25.431-b10 java.net.preferIPv4Stack=true Current Time: 15/01/2025 17:45:17 Host: files.minecraftforge.net [104.21.58.163, 172.67.161.211] Host: maven.minecraftforge.net [172.67.161.211, 104.21.58.163] Host: libraries.minecraft.net [127.0.0.1] Host: launchermeta.mojang.com [127.0.0.1] Host: piston-meta.mojang.com [127.0.0.1] Host: sessionserver.mojang.com [127.0.0.1] Host: authserver.mojang.com [Unknown] Error checking https://launchermeta.mojang.com/: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target Data kindly mirrored by CreeperHost at https://www.creeperhost.net/ Considering minecraft server jar Downloading libraries Found 1 additional library directories Considering library cpw.mods:securejarhandler:2.1.10   Downloading library from https://maven.creeperhost.net/cpw/mods/securejarhandler/2.1.10/securejarhandler-2.1.10.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm:9.7.1   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm/9.7.1/asm-9.7.1.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-commons:9.7.1   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-commons/9.7.1/asm-commons-9.7.1.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-tree:9.7.1   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-tree/9.7.1/asm-tree-9.7.1.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-util:9.7.1   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-util/9.7.1/asm-util-9.7.1.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-analysis:9.7.1   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-analysis/9.7.1/asm-analysis-9.7.1.jar     Download completed: Checksum validated. Considering library net.minecraftforge:accesstransformers:8.0.4   Downloading library from https://maven.creeperhost.net/net/minecraftforge/accesstransformers/8.0.4/accesstransformers-8.0.4.jar     Download completed: Checksum validated. Considering library org.antlr:antlr4-runtime:4.9.1   Downloading library from https://maven.creeperhost.net/org/antlr/antlr4-runtime/4.9.1/antlr4-runtime-4.9.1.jar     Download completed: Checksum validated. Considering library net.minecraftforge:eventbus:6.0.5   Downloading library from https://maven.creeperhost.net/net/minecraftforge/eventbus/6.0.5/eventbus-6.0.5.jar     Download completed: Checksum validated. Considering library net.minecraftforge:forgespi:7.0.1   Downloading library from https://maven.creeperhost.net/net/minecraftforge/forgespi/7.0.1/forgespi-7.0.1.jar     Download completed: Checksum validated. Considering library net.minecraftforge:coremods:5.2.1   Downloading library from https://maven.creeperhost.net/net/minecraftforge/coremods/5.2.1/coremods-5.2.1.jar     Download completed: Checksum validated. Considering library cpw.mods:modlauncher:10.0.9   Downloading library from https://maven.creeperhost.net/cpw/mods/modlauncher/10.0.9/modlauncher-10.0.9.jar     Download completed: Checksum validated. Considering library net.minecraftforge:unsafe:0.2.0   Downloading library from https://maven.creeperhost.net/net/minecraftforge/unsafe/0.2.0/unsafe-0.2.0.jar     Download completed: Checksum validated. Considering library net.minecraftforge:mergetool:1.1.5:api   Downloading library from https://maven.creeperhost.net/net/minecraftforge/mergetool/1.1.5/mergetool-1.1.5-api.jar     Download completed: Checksum validated. Considering library com.electronwill.night-config:core:3.6.4   Downloading library from https://maven.creeperhost.net/com/electronwill/night-config/core/3.6.4/core-3.6.4.jar     Download completed: Checksum validated. Considering library com.electronwill.night-config:toml:3.6.4   Downloading library from https://maven.creeperhost.net/com/electronwill/night-config/toml/3.6.4/toml-3.6.4.jar     Download completed: Checksum validated. Considering library org.apache.maven:maven-artifact:3.8.5   Downloading library from https://maven.creeperhost.net/org/apache/maven/maven-artifact/3.8.5/maven-artifact-3.8.5.jar     Download completed: Checksum validated. Considering library net.jodah:typetools:0.6.3   Downloading library from https://maven.creeperhost.net/net/jodah/typetools/0.6.3/typetools-0.6.3.jar     Download completed: Checksum validated. Considering library net.minecrell:terminalconsoleappender:1.2.0   Downloading library from https://maven.creeperhost.net/net/minecrell/terminalconsoleappender/1.2.0/terminalconsoleappender-1.2.0.jar     Download completed: Checksum validated. Considering library org.jline:jline-reader:3.12.1   Downloading library from https://maven.creeperhost.net/org/jline/jline-reader/3.12.1/jline-reader-3.12.1.jar     Download completed: Checksum validated. Considering library org.jline:jline-terminal:3.12.1   Downloading library from https://maven.creeperhost.net/org/jline/jline-terminal/3.12.1/jline-terminal-3.12.1.jar     Download completed: Checksum validated. Considering library org.spongepowered:mixin:0.8.5   Downloading library from https://maven.creeperhost.net/org/spongepowered/mixin/0.8.5/mixin-0.8.5.jar     Download completed: Checksum validated. Considering library org.openjdk.nashorn:nashorn-core:15.4   Downloading library from https://maven.creeperhost.net/org/openjdk/nashorn/nashorn-core/15.4/nashorn-core-15.4.jar     Download completed: Checksum validated. Considering library net.minecraftforge:JarJarSelector:0.3.19   Downloading library from https://maven.creeperhost.net/net/minecraftforge/JarJarSelector/0.3.19/JarJarSelector-0.3.19.jar     Download completed: Checksum validated. Considering library net.minecraftforge:JarJarMetadata:0.3.19   Downloading library from https://maven.creeperhost.net/net/minecraftforge/JarJarMetadata/0.3.19/JarJarMetadata-0.3.19.jar     Download completed: Checksum validated. Considering library cpw.mods:bootstraplauncher:1.1.2   Downloading library from https://maven.creeperhost.net/cpw/mods/bootstraplauncher/1.1.2/bootstraplauncher-1.1.2.jar     Download completed: Checksum validated. Considering library net.minecraftforge:JarJarFileSystems:0.3.19   Downloading library from https://maven.creeperhost.net/net/minecraftforge/JarJarFileSystems/0.3.19/JarJarFileSystems-0.3.19.jar     Download completed: Checksum validated. Considering library net.minecraftforge:fmlloader:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/fmlloader/1.20.1-47.3.12/fmlloader-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library net.minecraftforge:fmlearlydisplay:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/fmlearlydisplay/1.20.1-47.3.12/fmlearlydisplay-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library com.github.jponge:lzma-java:1.3   Downloading library from https://maven.creeperhost.net/com/github/jponge/lzma-java/1.3/lzma-java-1.3.jar     Download completed: Checksum validated. Considering library com.google.code.findbugs:jsr305:3.0.2   Downloading library from https://libraries.minecraft.net/com/google/code/findbugs/jsr305/3.0.2/jsr305-3.0.2.jar Failed to establish connection to https://libraries.minecraft.net/com/google/code/findbugs/jsr305/3.0.2/jsr305-3.0.2.jar  Host: libraries.minecraft.net [127.0.0.1] javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.ssl.Alert.createSSLException(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(Unknown Source)     at sun.security.ssl.SSLHandshake.consume(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.TransportContext.dispatch(Unknown Source)     at sun.security.ssl.SSLTransport.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.readHandshakeRecord(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)     at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)     at java.net.HttpURLConnection.getResponseCode(Unknown Source)     at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown Source)     at net.minecraftforge.installer.DownloadUtils.getConnection(DownloadUtils.java:240)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:174)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:164)     at net.minecraftforge.installer.DownloadUtils.downloadLibrary(DownloadUtils.java:149)     at net.minecraftforge.installer.actions.Action.downloadLibraries(Action.java:73)     at net.minecraftforge.installer.actions.ServerInstall.run(ServerInstall.java:72)     at net.minecraftforge.installer.InstallerPanel.run(InstallerPanel.java:271)     at net.minecraftforge.installer.SimpleInstaller.launchGui(SimpleInstaller.java:182)     at net.minecraftforge.installer.SimpleInstaller.main(SimpleInstaller.java:154) Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.validator.PKIXValidator.doBuild(Unknown Source)     at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)     at sun.security.validator.Validator.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)     ... 27 more Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.provider.certpath.SunCertPathBuilder.build(Unknown Source)     at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown Source)     at java.security.cert.CertPathBuilder.build(Unknown Source)     ... 33 more Considering library com.google.code.gson:gson:2.10.1   Downloading library from https://libraries.minecraft.net/com/google/code/gson/gson/2.10.1/gson-2.10.1.jar Failed to establish connection to https://libraries.minecraft.net/com/google/code/gson/gson/2.10.1/gson-2.10.1.jar  Host: libraries.minecraft.net [127.0.0.1] javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.ssl.Alert.createSSLException(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(Unknown Source)     at sun.security.ssl.SSLHandshake.consume(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.TransportContext.dispatch(Unknown Source)     at sun.security.ssl.SSLTransport.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.readHandshakeRecord(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)     at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)     at java.net.HttpURLConnection.getResponseCode(Unknown Source)     at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown Source)     at net.minecraftforge.installer.DownloadUtils.getConnection(DownloadUtils.java:240)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:174)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:164)     at net.minecraftforge.installer.DownloadUtils.downloadLibrary(DownloadUtils.java:149)     at net.minecraftforge.installer.actions.Action.downloadLibraries(Action.java:73)     at net.minecraftforge.installer.actions.ServerInstall.run(ServerInstall.java:72)     at net.minecraftforge.installer.InstallerPanel.run(InstallerPanel.java:271)     at net.minecraftforge.installer.SimpleInstaller.launchGui(SimpleInstaller.java:182)     at net.minecraftforge.installer.SimpleInstaller.main(SimpleInstaller.java:154) Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.validator.PKIXValidator.doBuild(Unknown Source)     at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)     at sun.security.validator.Validator.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)     ... 27 more Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.provider.certpath.SunCertPathBuilder.build(Unknown Source)     at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown Source)     at java.security.cert.CertPathBuilder.build(Unknown Source)     ... 33 more Considering library com.google.errorprone:error_prone_annotations:2.1.3   Downloading library from https://maven.creeperhost.net/com/google/errorprone/error_prone_annotations/2.1.3/error_prone_annotations-2.1.3.jar     Download completed: Checksum validated. Considering library com.google.guava:guava:25.1-jre   Downloading library from https://maven.creeperhost.net/com/google/guava/guava/25.1-jre/guava-25.1-jre.jar     Download completed: Checksum validated. Considering library com.google.j2objc:j2objc-annotations:1.1   Downloading library from https://maven.creeperhost.net/com/google/j2objc/j2objc-annotations/1.1/j2objc-annotations-1.1.jar     Download completed: Checksum validated. Considering library com.nothome:javaxdelta:2.0.1   Downloading library from https://maven.creeperhost.net/com/nothome/javaxdelta/2.0.1/javaxdelta-2.0.1.jar     Download completed: Checksum validated. Considering library commons-io:commons-io:2.4   Downloading library from https://libraries.minecraft.net/commons-io/commons-io/2.4/commons-io-2.4.jar Failed to establish connection to https://libraries.minecraft.net/commons-io/commons-io/2.4/commons-io-2.4.jar  Host: libraries.minecraft.net [127.0.0.1] javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.ssl.Alert.createSSLException(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(Unknown Source)     at sun.security.ssl.SSLHandshake.consume(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.TransportContext.dispatch(Unknown Source)     at sun.security.ssl.SSLTransport.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.readHandshakeRecord(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)     at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)     at java.net.HttpURLConnection.getResponseCode(Unknown Source)     at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown Source)     at net.minecraftforge.installer.DownloadUtils.getConnection(DownloadUtils.java:240)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:174)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:164)     at net.minecraftforge.installer.DownloadUtils.downloadLibrary(DownloadUtils.java:149)     at net.minecraftforge.installer.actions.Action.downloadLibraries(Action.java:73)     at net.minecraftforge.installer.actions.ServerInstall.run(ServerInstall.java:72)     at net.minecraftforge.installer.InstallerPanel.run(InstallerPanel.java:271)     at net.minecraftforge.installer.SimpleInstaller.launchGui(SimpleInstaller.java:182)     at net.minecraftforge.installer.SimpleInstaller.main(SimpleInstaller.java:154) Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.validator.PKIXValidator.doBuild(Unknown Source)     at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)     at sun.security.validator.Validator.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)     ... 27 more Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.provider.certpath.SunCertPathBuilder.build(Unknown Source)     at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown Source)     at java.security.cert.CertPathBuilder.build(Unknown Source)     ... 33 more Considering library de.oceanlabs.mcp:mcp_config:1.20.1-20230612.114412@zip   Downloading library from https://maven.creeperhost.net/de/oceanlabs/mcp/mcp_config/1.20.1-20230612.114412/mcp_config-1.20.1-20230612.114412.zip     Download completed: Checksum validated. Considering library de.siegmar:fastcsv:2.2.2   Downloading library from https://maven.creeperhost.net/de/siegmar/fastcsv/2.2.2/fastcsv-2.2.2.jar     Download completed: Checksum validated. Considering library net.minecraftforge:ForgeAutoRenamingTool:0.1.22:all   Downloading library from https://maven.creeperhost.net/net/minecraftforge/ForgeAutoRenamingTool/0.1.22/ForgeAutoRenamingTool-0.1.22-all.jar     Download completed: Checksum validated. Considering library net.minecraftforge:binarypatcher:1.1.1   Downloading library from https://maven.creeperhost.net/net/minecraftforge/binarypatcher/1.1.1/binarypatcher-1.1.1.jar     Download completed: Checksum validated. Considering library net.minecraftforge:fmlcore:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/fmlcore/1.20.1-47.3.12/fmlcore-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library net.minecraftforge:fmlearlydisplay:1.20.1-47.3.12   File exists: Checksum validated. Considering library net.minecraftforge:fmlloader:1.20.1-47.3.12   File exists: Checksum validated. Considering library net.minecraftforge:forge:1.20.1-47.3.12:universal   Downloading library from https://maven.creeperhost.net/net/minecraftforge/forge/1.20.1-47.3.12/forge-1.20.1-47.3.12-universal.jar     Download completed: Checksum validated. Considering library net.minecraftforge:installertools:1.4.1   Downloading library from https://maven.creeperhost.net/net/minecraftforge/installertools/1.4.1/installertools-1.4.1.jar     Download completed: Checksum validated. Considering library net.minecraftforge:jarsplitter:1.1.4   Downloading library from https://maven.creeperhost.net/net/minecraftforge/jarsplitter/1.1.4/jarsplitter-1.1.4.jar     Download completed: Checksum validated. Considering library net.minecraftforge:javafmllanguage:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/javafmllanguage/1.20.1-47.3.12/javafmllanguage-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library net.minecraftforge:lowcodelanguage:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/lowcodelanguage/1.20.1-47.3.12/lowcodelanguage-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library net.minecraftforge:mclanguage:1.20.1-47.3.12   Downloading library from https://maven.creeperhost.net/net/minecraftforge/mclanguage/1.20.1-47.3.12/mclanguage-1.20.1-47.3.12.jar     Download completed: Checksum validated. Considering library net.minecraftforge:srgutils:0.4.3   Downloading library from https://maven.creeperhost.net/net/minecraftforge/srgutils/0.4.3/srgutils-0.4.3.jar     Download completed: Checksum validated. Considering library net.minecraftforge:srgutils:0.4.9   Downloading library from https://maven.creeperhost.net/net/minecraftforge/srgutils/0.4.9/srgutils-0.4.9.jar     Download completed: Checksum validated. Considering library net.minecraftforge:srgutils:0.5.6   Downloading library from https://maven.creeperhost.net/net/minecraftforge/srgutils/0.5.6/srgutils-0.5.6.jar     Download completed: Checksum validated. Considering library net.sf.jopt-simple:jopt-simple:5.0.4   Downloading library from https://libraries.minecraft.net/net/sf/jopt-simple/jopt-simple/5.0.4/jopt-simple-5.0.4.jar Failed to establish connection to https://libraries.minecraft.net/net/sf/jopt-simple/jopt-simple/5.0.4/jopt-simple-5.0.4.jar  Host: libraries.minecraft.net [127.0.0.1] javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.ssl.Alert.createSSLException(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.TransportContext.fatal(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(Unknown Source)     at sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(Unknown Source)     at sun.security.ssl.SSLHandshake.consume(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.HandshakeContext.dispatch(Unknown Source)     at sun.security.ssl.TransportContext.dispatch(Unknown Source)     at sun.security.ssl.SSLTransport.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.decode(Unknown Source)     at sun.security.ssl.SSLSocketImpl.readHandshakeRecord(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)     at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)     at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)     at java.net.HttpURLConnection.getResponseCode(Unknown Source)     at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown Source)     at net.minecraftforge.installer.DownloadUtils.getConnection(DownloadUtils.java:240)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:174)     at net.minecraftforge.installer.DownloadUtils.download(DownloadUtils.java:164)     at net.minecraftforge.installer.DownloadUtils.downloadLibrary(DownloadUtils.java:149)     at net.minecraftforge.installer.actions.Action.downloadLibraries(Action.java:73)     at net.minecraftforge.installer.actions.ServerInstall.run(ServerInstall.java:72)     at net.minecraftforge.installer.InstallerPanel.run(InstallerPanel.java:271)     at net.minecraftforge.installer.SimpleInstaller.launchGui(SimpleInstaller.java:182)     at net.minecraftforge.installer.SimpleInstaller.main(SimpleInstaller.java:154) Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.validator.PKIXValidator.doBuild(Unknown Source)     at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)     at sun.security.validator.Validator.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)     at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)     ... 27 more Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target     at sun.security.provider.certpath.SunCertPathBuilder.build(Unknown Source)     at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown Source)     at java.security.cert.CertPathBuilder.build(Unknown Source)     ... 33 more Considering library net.sf.jopt-simple:jopt-simple:6.0-alpha-3   Downloading library from https://maven.creeperhost.net/net/sf/jopt-simple/jopt-simple/6.0-alpha-3/jopt-simple-6.0-alpha-3.jar     Download completed: Checksum validated. Considering library org.checkerframework:checker-qual:2.0.0   Downloading library from https://maven.creeperhost.net/org/checkerframework/checker-qual/2.0.0/checker-qual-2.0.0.jar     Download completed: Checksum validated. Considering library org.codehaus.mojo:animal-sniffer-annotations:1.14   Downloading library from https://maven.creeperhost.net/org/codehaus/mojo/animal-sniffer-annotations/1.14/animal-sniffer-annotations-1.14.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-analysis:9.2   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-analysis/9.2/asm-analysis-9.2.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-commons:9.2   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-commons/9.2/asm-commons-9.2.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-commons:9.6   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-commons/9.6/asm-commons-9.6.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-tree:9.2   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-tree/9.2/asm-tree-9.2.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm-tree:9.6   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm-tree/9.6/asm-tree-9.6.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm:9.2   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm/9.2/asm-9.2.jar     Download completed: Checksum validated. Considering library org.ow2.asm:asm:9.6   Downloading library from https://maven.creeperhost.net/org/ow2/asm/asm/9.6/asm-9.6.jar     Download completed: Checksum validated. Considering library trove:trove:1.0.2   Downloading library from https://maven.creeperhost.net/trove/trove/1.0.2/trove-1.0.2.jar     Download completed: Checksum validated. These libraries failed to download. Try again. com.google.code.findbugs:jsr305:3.0.2 com.google.code.gson:gson:2.10.1 commons-io:commons-io:2.4 net.sf.jopt-simple:jopt-simple:5.0.4 There was an error during installation  
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.