Bug in GUI Code

Published by NOYB on Mon, 05/18/2020 - 15:40
Status
Resolved
Type
Product/platform
Not applicable
Priority
Normal
Issue description

Whenever I create a GUI or regenerate the project code. The GUI code turns to this

        @Override /* failed to load code for net.minecraft.inventory.container.Container */
        @Override
        public void onContainerClosed(PlayerEntity playerIn) {
            super.onContainerClosed(playerIn);
            if ...

I just delete the second one everytime. I think it is just because it is EAP Snapshot, but I wanted to report anyways.

Issue comments

/* failed to load code for net.minecraft.inventory.container.Container */

In some cases, Gradle caches that make sure the build process does not take too long can get corrupted. In such a case, go to:

<your user home folder>/.mcreator/gradle

In this folder, there is a folder called caches. Delete this folder and open MCreator again. Next build will take a bit longer as caches need to be rebuilt. If you can not delete all files in this folder (which is necessary), reboot the computer first to remove any potential file locks.

If this is not enough to make things work, delete the entire gradle folder, not just caches, and try again.

If even this fails, try to delete the entire <your user home folder>/.mcreator/gradle folder, create a new workspace with the same generator version as the version of the workspace failing, after the setup of this new workspace is done, open your current workspace, and click Build & run -> Build workspace, then Build & run -> Reload gradle project and then Build & run -> Regenerate code and build.



Donate to MCreator

By donating to developers you can speed up development, as with more resources, we can dedicate more time to MCreator. It is a free project made by developers working on it in their free time.