Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Content Count

  • Joined

  • Last visited

Community Reputation

1 Neutral

About Xaser

  • Rank
    Tree Puncher
  1. Ok, I think I got the basics of Minecraft's packet handling and forge's SimpleImpl extension down. I also understand that this will be hell to debug, as there don't appear to be any hooks I can use to link into the processing of other mods' packets. Even adding some statistical output to the forge SimpleImpl code seems difficult as it appears that it's not intended to modify the forge code itself. So if I got this right, my only way to go is to randomly intercept one packet at a time (which will inevitably crash the server due to timeouts and disconnect the players) and hope to get some i
  2. Hi @diesieben07, ok I just set up a fresh modding workspace for 1.16.4 (forge-36.1.13) and I'm slowly figuring out how to attach the "projects debugger" to the server process. I'm unsure however where I should intercept with the debugger. I browsed the code and googled for info on the packet handling pipeline, but I'm still a bit unsure at which point I can really see the contents of the packet as deserialized data objects. Perhaps you have a pointer on which function to start from? Thanks!
  3. Hi, I have issues on my modded server with high traffic to but primarily from players. It's sometimes greater than 1 Mbit/s and appears to be related to items in water. To debug which mod / forge code is responsible, I would like to inspect the packets, but all the proxy-based sniffers (e.g. pakkit) seem to only work with vanilla minecraft. Is there some equivalent solution for forge servers that I've not been able to find? If not, what other ways to I have to inspect the packets. Since the client only shows 1-5 pkt/s TX, they must be rather big and the main contributor of packet size sho
  4. Hi, yes I get that, but I'm unsure about the definition of a "server". does it only apply to the dedicated server or to the local server as well?
  5. Thanks. Another quick question. When using the local server, my mod won't work and the console says So perhaps I should set AcceptableRemoteVersions to * but not say ServerSideOnly?
  6. But the server will still say "[FML]: Attempting connection with missing mods [my_mod] at CLIENT" when doing so. Is this intended?
  7. I actually used the exact same tutorials, but I must have skipped over the PlayerLoggedInEvent part and forgot about it.. that what happens when you only get to work on this stuff over the weekends i guess. Thanks! Actually, if the capability is not only for players, you may consider the OnEntityJoinWorldEvent as well
  8. Well, right now like this: http://pastebin.com/kxwndA8z So the nbt storage read function will be called when the player logs in and is loaded by the server, this causes the capability value to be set server-side and in the setter function, a update packet is triggered. So should I just use PlayerLoggedInEvent for initializing all capabilities from server- to client-side?
  9. I created a capability which stores a property about the player (mana) in the nbt. When it is loaded during player connect and set in the Capability class, it also triggers a message to be sent to the player to notify him of the capability value. However it seems that this message is sent to early because I get a NullPointerException in "FMLOutboundHandler", because player.connection == null. So apparently the connection has not yet been fully established. What event or something else can I use to notify the player of his capability value, once the connection has been established?
  10. Yes it does have a container attached, it references 3 inventories (player inventory + 2 temporary ones) as well as two ints and a reference to the other player (only the name is required really). I know that I have to keep the two int values synced myself later (haven't looked into that yet) however the gui also displays the name of another player (hence the gui requires the name or the entity id).,
  11. Pretty straight forward question: I want to open a GUI for the player (from the server side using .openGui), however this GUI needs some data to work properly. I prepared a custom packet to send this data, and on the server side code request it to be send before calling .openGui but apparently it doesn't arrive in time and the Gui throws a NullPointerException. So what should I do? My current ideas are: ack the data before having the server call openGui or have the gui wait clientside for the data.
  12. ok, almost there.. it was a bit tricky but it's definitely taking shape. Last question (hopefully): this feature / capability is entirely non-persistent so has no need for a Storage implementation. I cannot pass null however, as this causes an exception. is there a dummy implementation that I can pass? also for IStorage, do writeNBt and readNBT have to return a non-null value? Edit: also, can the default implementation be skipped during registration? I have multiple capabilities that require arguments to be passed to the injector and cannot have a default constructor s
  13. Well i'm just trying to find a way to signal to the in-code user of the capability whether or not the player is currently in a trade interaction or not, i.e. hascapability would only return true if the player is in a trade and getCapability would then return an object containing references to both participating players. If however the player wasn't in a trade, hasCapability would return false and getCapability null. However there doesn't seem to be a way to achieve this directly, so I need another layer, i.e. instead of a Trade capability, I am now trying a "trader" capability
  14. Sorry, I'm stuck again, maybe I just don't get the capability system after all. So I register the CapabilityProvider. However I can only access its getCapability and setCapability functions via the EntityPlayer directly. I have no way of calling another function that the provider might have to set the "trading" state of the player. So I have no real way to externally control when the instance field for the actual Capability in the CapabilityProvider is set. So I cannot make the Provider assign a value to the instance when the trading start and set it to null again, when the interac
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.