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 Im just wondering how do I make my code for the server side as I'm tiny bit confused how the new forge universal works :P

 

Ive decompiled my minecraft single/server using forge and when it gets to the decompiling of server says skipping this is normal I'm just wondering is this normal if I want to make an smp mod?

 

Also when i recompile my mod and add it to servers I get this error

"Caused by: java.lang.ClassNotFoundException: bbz" which it can't find the TileEntitySpecialRender as this file is on the client just wondering do i need to do something to stop certain class files running on the server?

Look into the forge proxy system, but the major rule is, classes that address server side need to go in Common package and can NOT reference classes from the client package. Packages in the client package are client side only and can reference classes from both packages.

There are 2 threads that run through the mod, client and server, server needs to stay contained in the common package, and client can go wherever, but should not modify the server directly.

 

There is a proxy system in place that allows you to call a class in the common package, that is extended in the client package, and depending on if the thread is server or client, that is the class that it will use. This is the heart of combining the two.

This is very simple, where you register your TESR, do it in the ClientProxy, like so:

ClientRegistry.registerTileEntity(TileEntityCable.class, "Cable", new TileEntitySpecialCableRenderer());

and in the server proxy, just do

GameRegistry.registerTileEntity(TileEntityCable.class, "Cable");

 

hope it helps :)

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...

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.