Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

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

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.

  • Author

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

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.

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.

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.