Jump to content

Recommended Posts

Posted (edited)

Today I was trying to get a simple string to the server using packets when a player joins a server, but the server-side handler never fires.

 

Here is the code I used to try to get it working:

Code:

Spoiler

PacketHandler.java:


package com.ultratechx.moddl;

import net.minecraftforge.fml.common.network.NetworkRegistry;
import net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper;
import net.minecraftforge.fml.relauncher.Side;

public class PacketHandler {
	private static int packetId = 0;

    public static SimpleNetworkWrapper INSTANCE = null;

    public PacketHandler() {
    }

    public static int nextID() {
        return packetId++;
    }

    public static void registerMessages(String channelName) {
        INSTANCE = NetworkRegistry.INSTANCE.newSimpleChannel(channelName);
        registerMessages();
    }

    public static void registerMessages() {
        // Register messages which are sent from the client to the server here:
        INSTANCE.registerMessage(PacketGetModList.Handler.class, PacketGetModList.class, nextID(), Side.SERVER);
    }
}

 

PacketGetModList.java:


package com.ultratechx.moddl;

import io.netty.buffer.ByteBuf;
import net.minecraft.client.Minecraft;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.server.MinecraftServer;
import net.minecraft.util.IThreadListener;
import net.minecraftforge.fml.common.network.ByteBufUtils;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
import net.minecraftforge.fml.relauncher.Side;

public class PacketGetModList implements IMessage{
	private String data;

    @Override
    public void fromBytes(ByteBuf buf) {
        data = ByteBufUtils.readUTF8String(buf);
    }

    @Override
    public void toBytes(ByteBuf buf) {
        ByteBufUtils.writeUTF8String(buf, data);
    }

    public PacketGetModList() {
        data = "REQ_MODLINK";
    }
    
    public PacketGetModList(String string) {
        data = string;
    }

    public static class Handler implements IMessageHandler<PacketGetModList, IMessage> {
        @Override
        public IMessage onMessage(final PacketGetModList message, final MessageContext ctx) {
        	if (ctx.side != Side.SERVER) {
                System.err.println("PACKET XDDD received on wrong side:" + ctx.side);
                return null;
            }
        	final EntityPlayerMP player = ctx.getServerHandler().playerEntity;
        	Minecraft.getMinecraft().addScheduledTask(new Runnable(){
        		public void run(){
        			handle(message, ctx, player);
        		}
        	});
            return null;
        }

        private void handle(PacketGetModList message, MessageContext ctx, EntityPlayerMP player) {
            // This code is run on the server side. So you can do server-side calculations here
            EntityPlayerMP playerEntity = ctx.getServerHandler().playerEntity;
           System.out.println("GOT STRING FROM CLIENT: " + message.data);
        }
    }
}

 

EventHandler.java:


package com.ultratechx.moddl;

import net.minecraft.network.INetHandler;
import net.minecraft.network.NetworkManager;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.PlayerEvent;
import net.minecraftforge.fml.common.network.FMLNetworkEvent;
import net.minecraftforge.fml.common.network.FMLNetworkEvent.ClientConnectedToServerEvent;

public class ModDLEventHandler {
	@SubscribeEvent
	public void onJoin(PlayerEvent.PlayerLoggedInEvent event){
		//if(!event.isLocal()) {
			PacketHandler.INSTANCE.sendToServer(new PacketGetModList("REQ_MODLIST"));
		//}
	}
}

 

CommonProxy.java:


package com.ultratechx.moddl.proxy;

import com.ultratechx.moddl.ModDL;
import com.ultratechx.moddl.ModDLEventHandler;
import com.ultratechx.moddl.PacketHandler;
import com.ultratechx.moddl.Ref;

import net.minecraft.entity.player.EntityPlayer;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fml.common.network.NetworkRegistry;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
import net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper;
import net.minecraftforge.fml.relauncher.Side;

public class CommonProxy implements IProxy{
	@Override
	public void preInit() {
		MinecraftForge.EVENT_BUS.register(new ModDLEventHandler());
		PacketHandler.registerMessages("ModDL");
	}

	@Override
	public void init() {
		
	}

	@Override
	public void postInit() {
		
	}
	
	public EntityPlayer getPlayerEntity(MessageContext ctx) {
		 return ctx.getServerHandler().playerEntity;
	}
}

 

 

Any ideas? There are no errors in both the server and client side consoles in eclipse.  Any help is appreciated!

 

UPDATE: A new error just started occurring, i do not know why, but maybe it has something to do with the packet issue? Below are the logs

Spoiler

Server Log:


2017-04-30 11:37:00,785 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
2017-04-30 11:37:00,786 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
[11:37:00] [main/INFO] [GradleStart]: Extra: []
[11:37:00] [main/INFO] [GradleStart]: Running with arguments: [--tweakClass, net.minecraftforge.fml.common.launcher.FMLServerTweaker, --tweakClass, net.minecraftforge.gradle.tweakers.CoremodTweaker]
[11:37:00] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Using primary tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.CoremodTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLServerTweaker
2017-04-30 11:37:02,337 WARN Disabling terminal, you're running in an unsupported environment.
[11:37:02] [main/INFO] [FML]: Forge Mod Loader version 13.19.1.2189 for Minecraft 1.11 loading
[11:37:02] [main/INFO] [FML]: Java is Java HotSpot(TM) 64-Bit Server VM, version 1.8.0_131, running on Windows 10:amd64:10.0, installed at U:\Program Files\Java\jre1.8.0_131
[11:37:02] [main/INFO] [FML]: Managed to load a deobfuscated Minecraft name- we are in a deobfuscated environment. Skipping runtime deobfuscation
[11:37:02] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.CoremodTweaker
[11:37:02] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.fml.relauncher.FMLCorePlugin
[11:37:02] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.classloading.FMLForgePlugin
[11:37:02] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:37:02] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[11:37:02] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[11:37:02] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:37:02] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:37:02] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[11:37:02] [main/ERROR] [FML]: The binary patch set is missing. Either you are in a development environment, or things are not going to work!
[11:37:04] [main/ERROR] [FML]: FML appears to be missing any signature data. This is not a good thing
[11:37:04] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[11:37:04] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[11:37:05] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[11:37:05] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.TerminalTweaker
[11:37:05] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.TerminalTweaker
[11:37:07] [main/INFO] [LaunchWrapper]: Launching wrapped minecraft {net.minecraft.server.MinecraftServer}
[11:37:14] [Server thread/INFO]: Starting minecraft server version 1.11
[11:37:14] [Server thread/INFO] [FML]: MinecraftForge v13.19.1.2189 Initialized
[11:37:14] [Server thread/INFO] [FML]: Replaced 232 ore recipes
[11:37:14] [Server thread/INFO] [FML]: Found 0 mods from the command line. Injecting into mod discoverer
[11:37:14] [Server thread/INFO] [FML]: Searching U:\Users\UltraTechX\Desktop\ModDL\run\mods for mods
[11:37:15] [Server thread/INFO] [FML]: Forge Mod Loader has identified 4 mods to load
[11:37:16] [Server thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at CLIENT
[11:37:16] [Server thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at SERVER
[11:37:17] [Server thread/INFO] [FML]: Processing ObjectHolder annotations
[11:37:17] [Server thread/INFO] [FML]: Found 443 ObjectHolder annotations
[11:37:17] [Server thread/INFO] [FML]: Identifying ItemStackHolder annotations
[11:37:17] [Server thread/INFO] [FML]: Found 0 ItemStackHolder annotations
[11:37:17] [Server thread/INFO] [FML]: Applying holder lookups
[11:37:17] [Server thread/INFO] [FML]: Holder lookups applied
[11:37:17] [Server thread/INFO] [FML]: Applying holder lookups
[11:37:17] [Server thread/INFO] [FML]: Holder lookups applied
[11:37:17] [Server thread/INFO] [FML]: Applying holder lookups
[11:37:17] [Server thread/INFO] [FML]: Holder lookups applied
[11:37:17] [Server thread/INFO] [FML]: Configured a dormant chunk cache size of 0
[11:37:17] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Starting version check at http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions_slim.json
[11:37:17] [Server thread/INFO] [FML]: Applying holder lookups
[11:37:17] [Server thread/INFO] [FML]: Holder lookups applied
[11:37:17] [Server thread/INFO] [FML]: Injecting itemstacks
[11:37:17] [Server thread/INFO] [FML]: Itemstack injection complete
[11:37:17] [Server thread/INFO]: Loading properties
[11:37:17] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Found status: UP_TO_DATE Target: null
[11:37:17] [Server thread/INFO]: Default game type: SURVIVAL
[11:37:17] [Server thread/INFO]: Generating keypair
[11:37:17] [Server thread/INFO]: Starting Minecraft server on 192.168.1.5:25565
[11:37:17] [Server thread/INFO]: Using default channel type
[11:37:18] [Server thread/WARN]: **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
[11:37:18] [Server thread/WARN]: The server will make no attempt to authenticate usernames. Beware.
[11:37:18] [Server thread/WARN]: While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.
[11:37:18] [Server thread/WARN]: To change this, set "online-mode" to "true" in the server.properties file.
[11:37:18] [Server thread/INFO] [FML]: Injecting itemstacks
[11:37:18] [Server thread/INFO] [FML]: Itemstack injection complete
[11:37:18] [Server thread/INFO] [FML]: Forge Mod Loader has successfully loaded 4 mods
[11:37:18] [Server thread/INFO]: Preparing level "world"
[11:37:18] [Server thread/INFO] [FML]: Injecting existing block and item data into this server instance
[11:37:18] [Server thread/INFO] [FML]: Applying holder lookups
[11:37:18] [Server thread/INFO] [FML]: Holder lookups applied
[11:37:18] [Server thread/INFO] [FML]: Loading dimension 0 (world) (net.minecraft.server.dedicated.DedicatedServer@a5dc5eb)
[11:37:18] [Server thread/INFO] [FML]: Loading dimension 1 (world) (net.minecraft.server.dedicated.DedicatedServer@a5dc5eb)
[11:37:18] [Server thread/INFO] [FML]: Loading dimension -1 (world) (net.minecraft.server.dedicated.DedicatedServer@a5dc5eb)
[11:37:18] [Server thread/INFO]: Preparing start region for level 0
[11:37:19] [Server thread/INFO]: Preparing spawn area: 21%
[11:37:20] [Server thread/INFO]: Done (2.669s)! For help, type "help" or "?"
[11:37:33] [Netty Server IO #2/INFO] [FML]: Client protocol version 2
[11:37:33] [Netty Server IO #2/INFO] [FML]: Client attempting to join with 4 mods : [email protected],[email protected],moddl@A1,[email protected]
[11:37:33] [Server thread/INFO] [FML]: [Server thread] Server side modded connection established
[11:37:33] [Server thread/INFO]: Player640[/192.168.1.5:62895] logged in with entity id 423 at (225.5, 68.0, 214.5)
[11:37:33] [Server thread/INFO]: Player640 joined the game
[11:37:33] [Server thread/ERROR] [FML]: FMLIndexedMessageCodec exception caught
java.lang.RuntimeException: Missing
	at net.minecraftforge.fml.server.FMLServerHandler.getClientToServerNetworkManager(FMLServerHandler.java:289) ~[FMLServerHandler.class:?]
	at net.minecraftforge.fml.common.FMLCommonHandler.getClientToServerNetworkManager(FMLCommonHandler.java:546) ~[FMLCommonHandler.class:?]
	at net.minecraftforge.fml.common.network.FMLOutboundHandler$OutboundTarget$8.selectNetworks(FMLOutboundHandler.java:245) ~[FMLOutboundHandler$OutboundTarget$8.class:?]
	at net.minecraftforge.fml.common.network.FMLOutboundHandler.write(FMLOutboundHandler.java:293) ~[FMLOutboundHandler.class:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:658) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:716) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:651) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:112) ~[MessageToMessageEncoder.class:4.0.23.Final]
	at io.netty.handler.codec.MessageToMessageCodec.write(MessageToMessageCodec.java:116) ~[MessageToMessageCodec.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:658) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:716) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:706) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:741) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:895) ~[DefaultChannelPipeline.class:4.0.23.Final]
	at io.netty.channel.AbstractChannel.writeAndFlush(AbstractChannel.java:240) ~[AbstractChannel.class:4.0.23.Final]
	at net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper.sendToServer(SimpleNetworkWrapper.java:294) [SimpleNetworkWrapper.class:?]
	at com.ultratechx.moddl.ModDLEventHandler.onJoin(ModDLEventHandler.java:14) [ModDLEventHandler.class:?]
	at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_6_ModDLEventHandler_onJoin_PlayerLoggedInEvent.invoke(.dynamic) [?:?]
	at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) [ASMEventHandler.class:?]
	at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:185) [EventBus.class:?]
	at net.minecraftforge.fml.common.FMLCommonHandler.firePlayerLoggedIn(FMLCommonHandler.java:566) [FMLCommonHandler.class:?]
	at net.minecraft.server.management.PlayerList.initializeConnectionToPlayer(PlayerList.java:236) [PlayerList.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher.completeServerSideConnection(NetworkDispatcher.java:265) [NetworkDispatcher.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher.access$100(NetworkDispatcher.java:73) [NetworkDispatcher.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher$1.update(NetworkDispatcher.java:214) [NetworkDispatcher$1.class:?]
	at net.minecraft.network.NetworkManager.processReceivedPackets(NetworkManager.java:309) [NetworkManager.class:?]
	at net.minecraft.network.NetworkSystem.networkTick(NetworkSystem.java:197) [NetworkSystem.class:?]
	at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:818) [MinecraftServer.class:?]
	at net.minecraft.server.dedicated.DedicatedServer.updateTimeLightAndEntities(DedicatedServer.java:402) [DedicatedServer.class:?]
	at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:699) [MinecraftServer.class:?]
	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:548) [MinecraftServer.class:?]
	at java.lang.Thread.run(Unknown Source) [?:1.8.0_131]
[11:40:26] [Server thread/INFO]: Stopping server
[11:40:26] [Server thread/INFO]: Saving players
[11:40:26] [Server thread/INFO]: Saving worlds
[11:40:26] [Server thread/INFO]: Saving chunks for level 'world'/Overworld
[11:40:26] [Server thread/INFO]: Saving chunks for level 'world'/Nether
[11:40:26] [Server thread/INFO]: Saving chunks for level 'world'/The End
[11:40:26] [Server thread/INFO] [FML]: Unloading dimension 0
[11:40:26] [Server thread/INFO] [FML]: Unloading dimension -1
[11:40:26] [Server thread/INFO] [FML]: Unloading dimension 1
[11:40:26] [Server thread/INFO] [FML]: Applying holder lookups
[11:40:26] [Server thread/INFO] [FML]: Holder lookups applied
Exception in thread "AWT-EventQueue-0" Java HotSpot(TM) 64-Bit Server VM warning: Using incremental CMS is deprecated and will likely be removed in a future release

 

Client Log:


2017-04-30 11:36:59,103 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
2017-04-30 11:36:59,104 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
[11:36:59] [main/INFO] [GradleStart]: Extra: []
[11:36:59] [main/INFO] [GradleStart]: Running with arguments: [--userProperties, {}, --assetsDir, C:/Users/UltraTechX/.gradle/caches/minecraft/assets, --assetIndex, 1.11, --accessToken{REDACTED}, --version, 1.11, --tweakClass, net.minecraftforge.fml.common.launcher.FMLTweaker, --tweakClass, net.minecraftforge.gradle.tweakers.CoremodTweaker]
[11:36:59] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Using primary tweak class name net.minecraftforge.fml.common.launcher.FMLTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.CoremodTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLTweaker
[11:36:59] [main/INFO] [FML]: Forge Mod Loader version 13.19.1.2189 for Minecraft 1.11 loading
[11:36:59] [main/INFO] [FML]: Java is Java HotSpot(TM) 64-Bit Server VM, version 1.8.0_131, running on Windows 10:amd64:10.0, installed at U:\Program Files\Java\jre1.8.0_131
[11:36:59] [main/INFO] [FML]: Managed to load a deobfuscated Minecraft name- we are in a deobfuscated environment. Skipping runtime deobfuscation
[11:36:59] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.CoremodTweaker
[11:36:59] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.fml.relauncher.FMLCorePlugin
[11:36:59] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.classloading.FMLForgePlugin
[11:36:59] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[11:36:59] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[11:36:59] [main/ERROR] [FML]: The binary patch set is missing. Either you are in a development environment, or things are not going to work!
[11:37:00] [main/ERROR] [FML]: FML appears to be missing any signature data. This is not a good thing
[11:37:00] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[11:37:00] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.TerminalTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.TerminalTweaker
[11:37:00] [main/INFO] [LaunchWrapper]: Launching wrapped minecraft {net.minecraft.client.main.Main}
2017-04-30 11:37:01,540 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
2017-04-30 11:37:01,559 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
2017-04-30 11:37:01,560 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
[11:37:01] [Client thread/INFO]: Setting user: Player640
[11:37:07] [Client thread/WARN]: Skipping bad option: lastServer:
[11:37:07] [Client thread/INFO]: LWJGL Version: 2.9.4
[11:37:10] [Client thread/INFO]: [STDOUT]: ---- Minecraft Crash Report ----
// You should try our sister game, Minceraft!

Time: 4/30/17 11:37 AM
Description: Loading screen debug info

This is just a prompt for computer specs to be printed. THIS IS NOT A ERROR


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- System Details --
Details:
	Minecraft Version: 1.11
	Operating System: Windows 10 (amd64) version 10.0
	Java Version: 1.8.0_131, Oracle Corporation
	Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
	Memory: 710573248 bytes (677 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 MB)
	JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M
	IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
	FML: 
	Loaded coremods (and transformers): 
	GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.5.0 NVIDIA 381.65' Renderer: 'GeForce GTX 1070/PCIe/SSE2'
[11:37:10] [Client thread/INFO] [FML]: MinecraftForge v13.19.1.2189 Initialized
[11:37:10] [Client thread/INFO] [FML]: Replaced 232 ore recipes
[11:37:11] [Client thread/INFO] [FML]: Found 0 mods from the command line. Injecting into mod discoverer
[11:37:11] [Client thread/INFO] [FML]: Searching U:\Users\UltraTechX\Desktop\ModDL\run\mods for mods
[11:37:12] [Client thread/INFO] [FML]: Forge Mod Loader has identified 4 mods to load
[11:37:13] [Client thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at CLIENT
[11:37:13] [Client thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at SERVER
[11:37:13] [Client thread/INFO]: Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:ModDL
[11:37:13] [Client thread/INFO] [FML]: Processing ObjectHolder annotations
[11:37:13] [Client thread/INFO] [FML]: Found 443 ObjectHolder annotations
[11:37:13] [Client thread/INFO] [FML]: Identifying ItemStackHolder annotations
[11:37:13] [Client thread/INFO] [FML]: Found 0 ItemStackHolder annotations
[11:37:13] [Client thread/INFO] [FML]: Applying holder lookups
[11:37:13] [Client thread/INFO] [FML]: Holder lookups applied
[11:37:13] [Client thread/INFO] [FML]: Applying holder lookups
[11:37:13] [Client thread/INFO] [FML]: Holder lookups applied
[11:37:13] [Client thread/INFO] [FML]: Applying holder lookups
[11:37:13] [Client thread/INFO] [FML]: Holder lookups applied
[11:37:13] [Client thread/INFO] [FML]: Configured a dormant chunk cache size of 0
[11:37:13] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Starting version check at http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions_slim.json
[11:37:13] [Client thread/INFO] [FML]: Applying holder lookups
[11:37:13] [Client thread/INFO] [FML]: Holder lookups applied
[11:37:13] [Client thread/INFO] [FML]: Injecting itemstacks
[11:37:13] [Client thread/INFO] [FML]: Itemstack injection complete
[11:37:14] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Found status: UP_TO_DATE Target: null
[11:37:16] [Sound Library Loader/INFO]: Starting up SoundSystem...
[11:37:16] [Thread-7/INFO]: Initializing LWJGL OpenAL
[11:37:16] [Thread-7/INFO]: (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)
[11:37:16] [Thread-7/INFO]: OpenAL initialized.
[11:37:17] [Sound Library Loader/INFO]: Sound engine started
[11:37:20] [Client thread/INFO] [FML]: Max texture size: 16384
[11:37:20] [Client thread/INFO]: Created: 16x16 textures-atlas
[11:37:22] [Client thread/INFO] [FML]: Injecting itemstacks
[11:37:22] [Client thread/INFO] [FML]: Itemstack injection complete
[11:37:22] [Client thread/INFO] [FML]: Forge Mod Loader has successfully loaded 4 mods
[11:37:22] [Client thread/INFO]: Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:ModDL
[11:37:24] [Client thread/INFO]: SoundSystem shutting down...
[11:37:24] [Client thread/WARN]: Author: Paul Lamb, www.paulscode.com
[11:37:24] [Sound Library Loader/INFO]: Starting up SoundSystem...
[11:37:24] [Thread-9/INFO]: Initializing LWJGL OpenAL
[11:37:24] [Thread-9/INFO]: (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)
[11:37:24] [Thread-9/INFO]: OpenAL initialized.
[11:37:24] [Sound Library Loader/INFO]: Sound engine started
[11:37:26] [Client thread/INFO] [FML]: Max texture size: 16384
[11:37:26] [Client thread/INFO]: Created: 512x512 textures-atlas
[11:37:27] [Client thread/WARN]: Skipping bad option: lastServer:
[11:37:27] [Realms Notification Availability checker #1/INFO]: Could not authorize you against Realms server: Invalid session id
[11:37:33] [Client thread/INFO]: Connecting to 192.168.1.5, 25565
[11:37:33] [Netty Client IO #1/INFO] [FML]: Server protocol version 2
[11:37:33] [Netty Client IO #1/INFO] [FML]: Injecting existing block and item data into this client instance
[11:37:33] [Netty Client IO #1/INFO] [FML]: Applying holder lookups
[11:37:33] [Netty Client IO #1/INFO] [FML]: Holder lookups applied
[11:37:33] [Netty Client IO #1/INFO] [FML]: [Netty Client IO #1] Client side modded connection established
[11:40:26] [Client thread/INFO] [FML]: Applying holder lookups
[11:40:26] [Client thread/INFO] [FML]: Holder lookups applied
[11:40:28] [Client thread/INFO]: Stopping!
[11:40:28] [Client thread/INFO]: SoundSystem shutting down...
[11:40:29] [Client thread/WARN]: Author: Paul Lamb, www.paulscode.com
Java HotSpot(TM) 64-Bit Server VM warning: Using incremental CMS is deprecated and will likely be removed in a future release

 

 

Edited by UltraTechX

I'm working on something big!  As long as there arent alot of big issues... [D

Posted
Minecraft.getMinecraft().addScheduledTask(new Runnable(){
  	public void run(){
		handle(message, ctx, player);
	}
});

You are sending the packet to the server, while the Minecraft is a client-only class. This doesn't work.

 

Use the WorldServer of the player to schedule a task:

((WorldServer) ctx.getServerHandler().playerEntity.worldObj).addScheduledTask(...);

 

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Posted (edited)

PlayerEvent.PlayerLoggedInEvent is only fired on the logical server. Sending a packet from the logical server to the logical server makes no sense and will only work if the logical server is running in the same process as the logical client (i.e. single player or LAN host). In addition to this, the event is fired too early for a client-to-server packet to be sent. Because of these two issues, it fails silently on the physical client or with an error on the physical server.

 

Why does the client need to send a request packet to the server for something the server can detect itself (i.e. a player logging in)?

Edited by Choonster

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted
2 minutes ago, larsgerrits said:

Minecraft.getMinecraft().addScheduledTask(new Runnable(){
  	public void run(){
		handle(message, ctx, player);
	}
});

You are sending the packet to the server, while the Minecraft is a client-only class. This doesn't work.

 

Use the WorldServer of the player to schedule a task:


((WorldServer) ctx.getServerHandler().playerEntity.worldObj).addScheduledTask(...);

 

No longer getting the error client-side, but still getting it server side after changing that line of code

server log:

2017-04-30 12:07:33,162 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
2017-04-30 12:07:33,163 WARN Unable to instantiate org.fusesource.jansi.WindowsAnsiOutputStream
[12:07:33] [main/INFO] [GradleStart]: Extra: []
[12:07:33] [main/INFO] [GradleStart]: Running with arguments: [--tweakClass, net.minecraftforge.fml.common.launcher.FMLServerTweaker, --tweakClass, net.minecraftforge.gradle.tweakers.CoremodTweaker]
[12:07:33] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[12:07:33] [main/INFO] [LaunchWrapper]: Using primary tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[12:07:33] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.CoremodTweaker
[12:07:33] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLServerTweaker
2017-04-30 12:07:34,247 WARN Disabling terminal, you're running in an unsupported environment.
[12:07:34] [main/INFO] [FML]: Forge Mod Loader version 13.19.1.2189 for Minecraft 1.11 loading
[12:07:34] [main/INFO] [FML]: Java is Java HotSpot(TM) 64-Bit Server VM, version 1.8.0_131, running on Windows 10:amd64:10.0, installed at U:\Program Files\Java\jre1.8.0_131
[12:07:34] [main/INFO] [FML]: Managed to load a deobfuscated Minecraft name- we are in a deobfuscated environment. Skipping runtime deobfuscation
[12:07:34] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.CoremodTweaker
[12:07:34] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.fml.relauncher.FMLCorePlugin
[12:07:34] [main/INFO] [GradleStart]: Injecting location in coremod net.minecraftforge.classloading.FMLForgePlugin
[12:07:34] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[12:07:34] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[12:07:34] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[12:07:34] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[12:07:34] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLInjectionAndSortingTweaker
[12:07:34] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[12:07:34] [main/ERROR] [FML]: The binary patch set is missing. Either you are in a development environment, or things are not going to work!
[12:07:36] [main/ERROR] [FML]: FML appears to be missing any signature data. This is not a good thing
[12:07:36] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.relauncher.CoreModManager$FMLPluginWrapper
[12:07:36] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLDeobfTweaker
[12:07:39] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.gradle.tweakers.AccessTransformerTweaker
[12:07:39] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.TerminalTweaker
[12:07:39] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.TerminalTweaker
[12:07:41] [main/INFO] [LaunchWrapper]: Launching wrapped minecraft {net.minecraft.server.MinecraftServer}
[12:07:50] [Server thread/INFO]: Starting minecraft server version 1.11
[12:07:50] [Server thread/INFO] [FML]: MinecraftForge v13.19.1.2189 Initialized
[12:07:50] [Server thread/INFO] [FML]: Replaced 232 ore recipes
[12:07:51] [Server thread/INFO] [FML]: Found 0 mods from the command line. Injecting into mod discoverer
[12:07:51] [Server thread/INFO] [FML]: Searching U:\Users\UltraTechX\Desktop\ModDL\run\mods for mods
[12:07:53] [Server thread/INFO] [FML]: Forge Mod Loader has identified 4 mods to load
[12:07:53] [Server thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at CLIENT
[12:07:53] [Server thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, forge, moddl] at SERVER
[12:07:54] [Server thread/INFO] [FML]: Processing ObjectHolder annotations
[12:07:54] [Server thread/INFO] [FML]: Found 443 ObjectHolder annotations
[12:07:54] [Server thread/INFO] [FML]: Identifying ItemStackHolder annotations
[12:07:54] [Server thread/INFO] [FML]: Found 0 ItemStackHolder annotations
[12:07:54] [Server thread/INFO] [FML]: Applying holder lookups
[12:07:54] [Server thread/INFO] [FML]: Holder lookups applied
[12:07:54] [Server thread/INFO] [FML]: Applying holder lookups
[12:07:54] [Server thread/INFO] [FML]: Holder lookups applied
[12:07:54] [Server thread/INFO] [FML]: Applying holder lookups
[12:07:54] [Server thread/INFO] [FML]: Holder lookups applied
[12:07:55] [Server thread/INFO] [FML]: Configured a dormant chunk cache size of 0
[12:07:55] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Starting version check at http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions_slim.json
[12:07:55] [Server thread/INFO] [FML]: Applying holder lookups
[12:07:55] [Server thread/INFO] [FML]: Holder lookups applied
[12:07:55] [Server thread/INFO] [FML]: Injecting itemstacks
[12:07:55] [Server thread/INFO] [FML]: Itemstack injection complete
[12:07:55] [Server thread/INFO]: Loading properties
[12:07:55] [Server thread/INFO]: Default game type: SURVIVAL
[12:07:55] [Server thread/INFO]: Generating keypair
[12:07:55] [Forge Version Check/INFO] [ForgeVersionCheck]: [forge] Found status: UP_TO_DATE Target: null
[12:07:55] [Server thread/INFO]: Starting Minecraft server on 192.168.1.5:25565
[12:07:55] [Server thread/INFO]: Using default channel type
[12:07:55] [Server thread/WARN]: **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
[12:07:55] [Server thread/WARN]: The server will make no attempt to authenticate usernames. Beware.
[12:07:55] [Server thread/WARN]: While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.
[12:07:55] [Server thread/WARN]: To change this, set "online-mode" to "true" in the server.properties file.
[12:07:55] [Server thread/INFO] [FML]: Injecting itemstacks
[12:07:55] [Server thread/INFO] [FML]: Itemstack injection complete
[12:07:55] [Server thread/INFO] [FML]: Forge Mod Loader has successfully loaded 4 mods
[12:07:55] [Server thread/INFO]: Preparing level "world"
[12:07:55] [Server thread/INFO] [FML]: Injecting existing block and item data into this server instance
[12:07:56] [Server thread/INFO] [FML]: Applying holder lookups
[12:07:56] [Server thread/INFO] [FML]: Holder lookups applied
[12:07:56] [Server thread/INFO] [FML]: Loading dimension 0 (world) (net.minecraft.server.dedicated.DedicatedServer@bd6ed05)
[12:07:56] [Server thread/INFO] [FML]: Loading dimension 1 (world) (net.minecraft.server.dedicated.DedicatedServer@bd6ed05)
[12:07:56] [Server thread/INFO] [FML]: Loading dimension -1 (world) (net.minecraft.server.dedicated.DedicatedServer@bd6ed05)
[12:07:56] [Server thread/INFO]: Preparing start region for level 0
[12:07:57] [Server thread/INFO]: Preparing spawn area: 20%
[12:07:58] [Server thread/INFO]: Done (2.999s)! For help, type "help" or "?"
[12:08:13] [Netty Server IO #2/INFO] [FML]: Client protocol version 2
[12:08:13] [Netty Server IO #2/INFO] [FML]: Client attempting to join with 4 mods : [email protected],[email protected],moddl@A1,[email protected]
[12:08:13] [Server thread/INFO] [FML]: [Server thread] Server side modded connection established
[12:08:13] [Server thread/INFO]: Player908[/192.168.1.5:63679] logged in with entity id 428 at (226.5, 68.0, 213.5)
[12:08:13] [Server thread/INFO]: Player908 joined the game
[12:08:13] [Server thread/ERROR] [FML]: FMLIndexedMessageCodec exception caught
java.lang.RuntimeException: Missing
	at net.minecraftforge.fml.server.FMLServerHandler.getClientToServerNetworkManager(FMLServerHandler.java:289) ~[FMLServerHandler.class:?]
	at net.minecraftforge.fml.common.FMLCommonHandler.getClientToServerNetworkManager(FMLCommonHandler.java:546) ~[FMLCommonHandler.class:?]
	at net.minecraftforge.fml.common.network.FMLOutboundHandler$OutboundTarget$8.selectNetworks(FMLOutboundHandler.java:245) ~[FMLOutboundHandler$OutboundTarget$8.class:?]
	at net.minecraftforge.fml.common.network.FMLOutboundHandler.write(FMLOutboundHandler.java:293) ~[FMLOutboundHandler.class:?]
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:658) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:716) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:651) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:112) ~[MessageToMessageEncoder.class:4.0.23.Final]
	at io.netty.handler.codec.MessageToMessageCodec.write(MessageToMessageCodec.java:116) ~[MessageToMessageCodec.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:658) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:716) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:706) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:741) ~[AbstractChannelHandlerContext.class:4.0.23.Final]
	at io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:895) ~[DefaultChannelPipeline.class:4.0.23.Final]
	at io.netty.channel.AbstractChannel.writeAndFlush(AbstractChannel.java:240) ~[AbstractChannel.class:4.0.23.Final]
	at net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper.sendToServer(SimpleNetworkWrapper.java:294) [SimpleNetworkWrapper.class:?]
	at com.ultratechx.moddl.ModDLEventHandler.onJoin(ModDLEventHandler.java:14) [ModDLEventHandler.class:?]
	at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_6_ModDLEventHandler_onJoin_PlayerLoggedInEvent.invoke(.dynamic) [?:?]
	at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) [ASMEventHandler.class:?]
	at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:185) [EventBus.class:?]
	at net.minecraftforge.fml.common.FMLCommonHandler.firePlayerLoggedIn(FMLCommonHandler.java:566) [FMLCommonHandler.class:?]
	at net.minecraft.server.management.PlayerList.initializeConnectionToPlayer(PlayerList.java:236) [PlayerList.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher.completeServerSideConnection(NetworkDispatcher.java:265) [NetworkDispatcher.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher.access$100(NetworkDispatcher.java:73) [NetworkDispatcher.class:?]
	at net.minecraftforge.fml.common.network.handshake.NetworkDispatcher$1.update(NetworkDispatcher.java:214) [NetworkDispatcher$1.class:?]
	at net.minecraft.network.NetworkManager.processReceivedPackets(NetworkManager.java:309) [NetworkManager.class:?]
	at net.minecraft.network.NetworkSystem.networkTick(NetworkSystem.java:197) [NetworkSystem.class:?]
	at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:818) [MinecraftServer.class:?]
	at net.minecraft.server.dedicated.DedicatedServer.updateTimeLightAndEntities(DedicatedServer.java:402) [DedicatedServer.class:?]
	at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:699) [MinecraftServer.class:?]
	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:548) [MinecraftServer.class:?]
	at java.lang.Thread.run(Unknown Source) [?:1.8.0_131]

 

I'm working on something big!  As long as there arent alot of big issues... [D

Posted (edited)
5 minutes ago, Choonster said:

PlayerEvent.PlayerLoggedInEvent is only fired on the logical server. Sending a packet from the logical server to the logical server makes no sense and will only work if the logical server is running in the same process as the logical client (i.e. single player or LAN host). In addition to this, the event is fired too early for a client-to-server packet to be sent. Because of these two issues, it fails silently.

 

Why does the client need to send a request packet to the server for something the server can detect itself (i.e. a player logging in)?

Well, I was actually trying to get the client to send the packet to the server before when it joins the game, is there a better event to use for that?  I am trying to make it so that when the client connects, it asks the server for a string, and then the server returns the string that will be inside a config file on the dedicated server.

 

UPDATE: I will try again with the event FMLNetworkEvent.ClientConnectedToServerEvent and will update again if anything changes

 

UPDATE 2: I tried again with the new event, now both errors are gone! But the main issue is still not fixed

Edited by UltraTechX

I'm working on something big!  As long as there arent alot of big issues... [D

Posted (edited)
3 minutes ago, UltraTechX said:

Well, I was actually trying to get the client to send the packet to the server before when it joins the game, is there a better event to use for that?  I am trying to make it so that when the client connects, it asks the server for a string, and then the server returns the string that will be inside a config file on the dedicated server.

 

Just have the server send a packet to the player's client in PlayerEvent.PlayerLoggedInEvent. There shouldn't be any need for a request packet here.

Edited by Choonster
  • Like 1

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted (edited)
5 minutes ago, Choonster said:

 

Just have the server send a packet to the player's client in PlayerEvent.PlayerLoggedInEvent. There shouldn't be any need for a request packet here.

I will try doing this and get update this comment when i am done testing it.

 

UPDATE: It works! Thank you so much for helping me!

Edited by UltraTechX

I'm working on something big!  As long as there arent alot of big issues... [D

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

    • Reach Out To Rapid Digital: What sapp Info: +1 41 4 80 7 14 85 Email INFO: rap iddi gita lrecov ery @ exe cs. com Hello, my name is Jayson, and I’m 35 years old from the United Kingdom. My family and I recently endured an incredibly challenging experience that I wouldn’t wish on anyone. We became victims of a cryptocurrency investment fraud scheme that saw us lose a staggering $807,000 in USDT and Bitcoins. The fraudsters had created a convincing facade, and we were lured into investing, only to discover later that the platform was a complete scam. We were left devastated, not just financially, but emotionally, as we had trusted these people and believed in the legitimacy of the investment. After the initial shock wore off, we desperately searched for ways to recover the lost funds. It seemed like an impossible task, and we felt as though there was no hope. That’s when, by sheer luck, we stumbled across a post about Rapid Digital Recovery, a cryptocurrency and funds recovery organization with a proven track record in cybersecurity and fraud recovery. We decided to reach out to them, and from the first interaction, we were impressed with their professionalism and transparency. They explained the recovery process in detail and reassured us that they had the skills and expertise to track down the perpetrators and recover our funds. This gave us a renewed sense of hope, something we hadn’t felt in months. What truly stood out during our experience with Rapid Digital Recovery was their dedication to the recovery process. The team went above and beyond, using sophisticated tracking tools and cyber forensics to gather critical information. Within a matter of weeks, they had successfully located the funds and traced the scam back to the fraudsters responsible. They worked with the authorities to ensure the criminals were held accountable for their actions. To our relief, the team at Rapid Digital Recovery was able to recover every single penny we had lost. The funds were returned in full, and the sense of closure we felt was invaluable. We couldn’t have imagined such a positive outcome in the early stages of our recovery journey, and we are deeply grateful for the work they did. If you ever find yourself in a similar situation, I highly recommend contacting Rapid Digital Recovery. Their expertise, transparency, and dedication to their clients make them the go-to choice for anyone seeking to recover lost cryptocurrency or funds. They truly gave us back our financial future.  
    • This is my first time modding anything, so maybe just skill issue. I'm using Forge 54.0.12 and Temurin 21.0.5+11-LTS I wanted to create a custom keybind and to check whether it works I'd like to send a chat message. I tried using Minecraft.getInstance().player.sendSystemMessage(Component.literal("test")); but IntelliJ couldnt resolve sendSystemMessage(...). Since I saw people using it in earlier versions, I tried the same thing with 1.20.6(- 50.1.0), where it works fine, now I can't figure out if this is intentional and whether there are other options for sending chat messages. On that note, is there more documentation than https://docs.minecraftforge.net/en/1.21.x/? It seems very incomplete compared to something like the Oracle Java docs
    • Hi, i'm having this error and I wanna fix it. we try: -Reload drivers -Eliminate .minecraft -Eliminate Java -Restart launcher -Verify if minecraft is using gpu -Mods  in .minecraft is empty -Install the latest and recomended version of forge idk what i have to do, help me pls. the lastest log is: https://mclo.gs/WAMao8x  
    • Read the FAQ, Rule #2. (https://forums.minecraftforge.net/topic/125488-rules-and-frequently-asked-questions-faq/)  
  • Topics

×
×
  • Create New...

Important Information

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