oωo (owo-lib)

oωo (owo-lib)

17M Downloads

Cannot access net.minecraft.client.gui.Element

timasshoff opened this issue · 4 comments

commented

Hello, I tried to create a screen in owo-ui. I followed the tutorial in the official wiki and created my screen class, but I cannot create the UI adapter. When trying to create the adapter, it says "Cannot access net.minecraft.client.gui.Element". What can I do to fix this?
image

commented

Ah ! You get same error has me....
I get stuck for severals months and I decided to abandoned.

commented

Ok I just found the problem: I created my project using the Fabric Template Generator. The error only occurs, when you split the client and common sources (its an option at the bottom of the generator). When you use a project that has been created without this option selected, the error is no longer present.

commented

Did you place your screen in the common sourceset? If so it makes sense that you would not have access to client-only resources, like the GUI code.

commented

Since the original problem appears resolved, I'll go ahead and close the issue. If there's any futher need for discussion feel free to drop another comment

Cheers