Jump to content

The problem at the container transfer from the server to the client


JRE8

Recommended Posts

Hi guys , I'm writing network modification , I have a problem , there is a container with a slot into which you can lay down > 64 pieces , in a single all normally passes , but when you come to the server and put slot > 255 sign is negative , I thought , then saw pattern , went to read the code and saw that the recording and receiving slots on the server comes to the size of one byte , and I need four bytes , help solve the problem .

Link to comment
Share on other sites

This is due to the way ItemStacks are designed. They are not designed to hold more than 64 elements. If you need more, you need to make your own system.

How to do it if the sending server container tightly written EntityPlayerMP, and catch the event transmission I do not know how.

Link to comment
Share on other sites

This is due to the way ItemStacks are designed. They are not designed to hold more than 64 elements. If you need more, you need to make your own system.

 

 

Everything works well tolerated stacks , I threw 10 stacks of 64 , and took them safely , though the client had information that there -130

Link to comment
Share on other sites

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



×
×
  • Create New...

Important Information

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