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'm planning to make a mod in 1.15.2 so i've followed a tutorial to know how to make a tileEntity with a functional GUI, it worked but somehow it stopped and after copy/paste all the code and adapting it, it still don't work.

Here is the GitHub repo :https://github.com/RelativeCommand/chemistrymod/tree/main/OneDrive/Documents/MinecraftModding/ChemistryMod

I've noticed that the name i've set for the gui isn't rendering too so maybe it's something from the class where i've set this ?

I really don't know what to do right know after "rewriting" the all thing.

Here is a pic of the problem

image.png.a4c46fddbffaccc3dafa5461b2daf3f3.png

Thanks

Edited by RelativeCommand

  • Author

Wow, i've just seen your message thank you !

I fixed the "Inventory" and the name that were missing for the GUI and now slots are aligned with the GUI yaay.

but i can't figure out how to draw my hotbar ^^'

private void drawHotbar(int startPlayerInvX, int slotSizePlus2, int hotbarY, final IItemHandler playerInventoryHandler){
        //hotbar
        //int hotbarY = 170;
        for(int collumn = 0; collumn < 9 ; ++collumn){
            addSlot(playerInventoryHandler, collumn, startPlayerInvX + (collumn* slotSizePlus2), hotbarY);
        }

    }

Here is what i tried in my "container" class with playerInventoryHandler = new InvWrapper(playerInventory) but still it doesn't work

Could you please explain me what's wrong ? 

Thanks 

  • Author

Nevermind i figured it out, it's just that in my TestTubeRackScreen, this.guiLeft top xSize and Ysize weren't set ^^

Sorry for disturbing you

have a good night

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.