Jump to content

Recommended Posts

Posted

hi

 

I need to send data from my Container to the TileEntity (only a signal to increment something) and then I want to send an Icon back to update the appearence of the GUI.

 

How can I do this? With Network Packages?

 

aligator123456

Posted

You could always just call a method.

 

I'm assuming your Container retains a reference to the TileEntity.

 

So put a public method incrementSomethingAndGetNewIcon (or something) in the TileEntity's class and call it from the Container when you need to send the data. Send the data you wish to send in the method call and use the return to get the Icon.

Posted

this doesn't work.

I think because one is serverside and the other one is clientside.

 

If I do it, it doesn't work, because if I later want to use the incremented value (for example saving it to nbt) it is not changed

Posted

Lol, ninjad AGAIN!!!

 

That does sound viable, but does the server know about it? That's the issue really. I remember when I was doing stuff client side and wondering why it wasn't working... Fun times :P

We all stuff up sometimes... But I seem to be at the bottom of that pot.

Posted

I suggest packets. I'm not sure hoe they work after moving to Netty though.. Someone lend a hand in that regard?

We all stuff up sometimes... But I seem to be at the bottom of that pot.

Guest
This topic is now closed to further replies.

Announcements



×
×
  • Create New...

Important Information

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