• Recently Browsing

    No registered users viewing this page.

  • Posts

    • Okay, so I've been trying to install Forge to mod my minecraft game for a while, but every time I try, the installer doesn't install it and prompts me with this error   "Unable to Install Java   there are errors in the following switches: "C:\User\*****\AppData\roaming\.minecraft\forge-1.14.4-28. 2.23-installer.jar";.   Check that the commands are valid and try again."   I have Java istalled, but I don't think that it has anything to do with it. I need help fixing this, please.
    • I created now. public MyEntity(EntityType<? extends MyEntity> type, World worldIn) { super(type, worldIn); handler = getHandler(); optional = create(this); } do i need this? public <T> LazyOptional<T> create(LivingEntity entity) { LazyOptional<IItemHandlerModifiable>[] ret = new LazyOptional[2]; ret[0] = LazyOptional.of(() -> getHandler()); ret[1] = LazyOptional.of(() -> new EntityArmorInvWrapper(entity)); return LazyOptional.of(() -> (T)new CombinedInvWrapper(ret[0].orElse(null), ret[1].orElse(null))); }   here i got default handler    public <T> LazyOptional<T> getCapability(@Nonnull Capability<T> cap, @Nullable Direction side) { if(cap == CapabilityItemHandler.ITEM_HANDLER_CAPABILITY) { defHandler = (ItemStackHandler) super.getCapability(cap,side).orElse(null); return create(this); } return super.getCapability(cap, side); } public ItemStack func_213803_dV() { return this.getItemStackFromSlot(EquipmentSlotType.CHEST); } Am i going right?
    • The following is my packet registry. The Client->Server packets work just fine, it's just the Server->Client ones that complain about "Unknown custom packet identifier" so I'm certain I'm just missing something stupid:   public final class PacketRegistry { /** * The ID for the next packet registration. */ private static final String PROTOCOL_VERSION = Integer.toString(1); private byte nextPacketID = 0; /** * The internal network wrapper. */ private static final SimpleChannel wrapper = NetworkRegistry.ChannelBuilder .named(new ResourceLocation(Withernauts.MODID, "main_channel")) .clientAcceptedVersions(PROTOCOL_VERSION::equals) .serverAcceptedVersions(PROTOCOL_VERSION::equals) .networkProtocolVersion(() -> PROTOCOL_VERSION) .simpleChannel(); public void registerPackets() { //register packets going to the client registerServerToClient(MotionPlayerPacket.class, MotionPlayerPacket::encode, MotionPlayerPacket::decode, MotionPlayerPacket::handle); registerServerToClient(PlayerLoadingPacket.class, PlayerLoadingPacket::encode, PlayerLoadingPacket::decode, PlayerLoadingPacket::handle); //register packets going to the server registerClientToServer(CrouchSyncPacket.class, CrouchSyncPacket::encode, CrouchSyncPacket::decode, CrouchSyncPacket::handle); registerClientToServer(RunSyncPacket.class, RunSyncPacket::encode, RunSyncPacket::decode, RunSyncPacket::handle); registerClientToServer(AttackSyncPacket.class, AttackSyncPacket::encode, AttackSyncPacket::decode, AttackSyncPacket::handle); registerClientToServer(CombatActionPacket.class, CombatActionPacket::encode, CombatActionPacket::decode, CombatActionPacket::handle); registerClientToServer(ManaSyncPacket.class, ManaSyncPacket::encode, ManaSyncPacket::decode, ManaSyncPacket::handle); registerClientToServer(StaminaSyncPacket.class, StaminaSyncPacket::encode, StaminaSyncPacket::decode, StaminaSyncPacket::handle); } @SuppressWarnings({"unchecked", "rawtypes"}) protected <MESSAGE> void registerServerToClient(Class<MESSAGE> type, BiConsumer<MESSAGE, PacketBuffer> encoder, Function<PacketBuffer, MESSAGE> decoder, BiConsumer<MESSAGE, Supplier<NetworkEvent.Context>> consumer) { this.wrapper.registerMessage(nextPacketID++, type, encoder, decoder, consumer, Optional.of(NetworkDirection.PLAY_TO_CLIENT)); } @SuppressWarnings({"unchecked", "rawtypes"}) protected <MESSAGE> void registerClientToServer(Class<MESSAGE> type, BiConsumer<MESSAGE, PacketBuffer> encoder, Function<PacketBuffer, MESSAGE> decoder, BiConsumer<MESSAGE, Supplier<NetworkEvent.Context>> consumer) { this.wrapper.registerMessage(nextPacketID++, type, encoder, decoder, consumer, Optional.of(NetworkDirection.PLAY_TO_SERVER)); } /** * Sends the given packet to every client. * * @param message the packet to send. */ public<MESSAGE> void sendToAll(MESSAGE message) { this.wrapper.send(PacketDistributor.ALL.noArg(), message); } /** * Sends the given packet to the given player. * * @param message the packet to send. * @param player the player to send the packet to. */ public<MESSAGE> void sendTo(MESSAGE message, ServerPlayerEntity player) { if (player.connection != null) this.wrapper.sendTo(message, player.connection.getNetworkManager(), NetworkDirection.PLAY_TO_CLIENT); } /** * Sends the given packet to all players around the given target point. * * @param message the packet to send. * @param point the target point. */ public<MESSAGE> void sendToAllAround(MESSAGE message, PacketDistributor.TargetPoint point) { this.wrapper.send(PacketDistributor.NEAR.with(()->point), message); } /** * Sends the given packet to the server. * * @param message the packet to send. */ public<MESSAGE> void sendToServer(MESSAGE message) { this.wrapper.sendToServer(message); } public<MESSAGE> void sendToAllTracking(MESSAGE message, Entity entity) { this.wrapper.send(PacketDistributor.TRACKING_ENTITY.with(() -> entity), message); } }   This class is called in the FMLCommonSetupEvent event hook within my main file.
    • Hi, im using crident networks with the dino.gg panel to host a server im downloading there latest 1.16.4 forge server build and every time i attepmt to launch the server i recieve the same attach crash log. Ive downloaded the actual latest 1.16.4 forge server files onto my pc from forge directly, made a working server and uploaded them to the server host but then i recieve the same issue. I contacted crident support but after talking to one of the devs they told me that forge support was the place to seek help as it was out of their hands. Any help is massively appreciated. 2021-01-21-1.log
    • but when i try this to set the weather to thunder ((ServerWorld) world).func_241113_a_(0, world.rand.nextInt(1000), true, true);   i get an error: java.lang.ClassCastException: class net.minecraft.client.world.ClientWorld cannot be cast to class net.minecraft.world.server.ServerWorld (net.minecraft.client.world.ClientWorld and net.minecraft.world.server.ServerWorld are in unnamed module of loader cpw.mods.modlauncher.TransformingClassLoader @4cc36c19) at net.luis.cave.events.entity.OnEntityAttack.EntityAttack(OnEntityAttack.java:78) ~[main/:?] {re:classloading} at net.minecraftforge.eventbus.ASMEventHandler_17_OnEntityAttack_EntityAttack_LivingAttackEvent.invoke(.dynamic) ~[?:?] {} at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:85) ~[eventbus-4.0.0.jar:?] {} at net.minecraftforge.eventbus.EventBus.post(EventBus.java:302) ~[eventbus-4.0.0.jar:?] {} at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) ~[eventbus-4.0.0.jar:?] {} at net.minecraftforge.common.ForgeHooks.onLivingAttack(ForgeHooks.java:325) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading} at net.minecraft.entity.LivingEntity.attackEntityFrom(LivingEntity.java:991) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading} at net.minecraft.entity.passive.AnimalEntity.attackEntityFrom(AnimalEntity.java:80) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading} at net.minecraft.entity.player.PlayerEntity.attackTargetEntityWithCurrentItem(PlayerEntity.java:1167) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B} at net.minecraft.client.multiplayer.PlayerController.attackEntity(PlayerController.java:373) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.clickMouse(Minecraft.java:1343) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.processKeyBinds(Minecraft.java:1688) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.runTick(Minecraft.java:1507) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:979) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.Minecraft.run(Minecraft.java:612) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.main.Main.main(Main.java:184) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {re:classloading,pl:runtimedistcleaner:A} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?] {} at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) ~[?:?] {} at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?] {} at java.lang.reflect.Method.invoke(Method.java:564) ~[?:?] {} at net.minecraftforge.userdev.FMLUserdevClientLaunchProvider.lambda$launchService$0(FMLUserdevClientLaunchProvider.java:52) ~[forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {} at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-8.0.9.jar:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-8.0.9.jar:?] {} at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-8.0.9.jar:?] {} at cpw.mods.modlauncher.Launcher.run(Launcher.java:82) [modlauncher-8.0.9.jar:?] {} at cpw.mods.modlauncher.Launcher.main(Launcher.java:66) [modlauncher-8.0.9.jar:?] {} at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105) [forge-1.16.5-36.0.1_mapped_snapshot_20201028-1.16.3-recomp.jar:?] {}  
  • Topics

  • Who's Online (See full list)