:compileJava fails when I create a mob

Started by yellowtangerine on

Topic category: Help with Minecraft modding (Java Edition)

Joined May 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
:compileJava fails when I create a mob
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:77: error: cannot find symbol 
   public static class CustomEntity extends MonsterEntity implements IAnimatedEntity { 
                                                                     ^ 
  symbol:   class IAnimatedEntity 
  location: class ImpostorEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:78: error: cannot find symbol 
      EntityAnimationManager manager = new EntityAnimationManager(); 
      ^ 
  symbol:   class EntityAnimationManager 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:79: error: cannot find symbol 
      EntityAnimationController controller = new EntityAnimationController(this, "controller", 1, this::animationPredicate); 
      ^ 
  symbol:   class EntityAnimationController 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:80: error: cannot find symbol 
      private <E extends Entity> boolean animationPredicate(AnimationTestEvent<E> event) { 
                                                            ^ 
  symbol:   class AnimationTestEvent 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:87: error: cannot find symbol 
      public EntityAnimationManager getAnimationManager() { 
             ^ 
  symbol:   class EntityAnimationManager 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:78: error: cannot find symbol 
      EntityAnimationManager manager = new EntityAnimationManager(); 
                                           ^ 
  symbol:   class EntityAnimationManager 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:79: error: cannot find symbol 
      EntityAnimationController controller = new EntityAnimationController(this, "controller", 1, this::animationPredicate); 
                                                 ^ 
  symbol:   class EntityAnimationController 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:86: error: method does not override or implement a method from a supertype 
      @Override 
      ^ 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:146: error: registerAttributes() in CustomEntity cannot override registerAttributes() in LivingEntity 
      protected void registerAttributes() { 
                     ^ 
  overridden method is static 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:145: error: method does not override or implement a method from a supertype 
      @Override 
      ^ 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:148: error: cannot find symbol 
         if (this.getAttribute(SharedMonsterAttributes.MOVEMENT_SPEED) != null) 
                               ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:149: error: cannot find symbol 
            this.getAttribute(SharedMonsterAttributes.MOVEMENT_SPEED).setBaseValue(0.4); 
                              ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:150: error: cannot find symbol 
         if (this.getAttribute(SharedMonsterAttributes.MAX_HEALTH) != null) 
                               ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:151: error: cannot find symbol 
            this.getAttribute(SharedMonsterAttributes.MAX_HEALTH).setBaseValue(25); 
                              ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:152: error: cannot find symbol 
         if (this.getAttribute(SharedMonsterAttributes.ARMOR) != null) 
                               ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:153: error: cannot find symbol 
            this.getAttribute(SharedMonsterAttributes.ARMOR).setBaseValue(3); 
                              ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:154: error: cannot find symbol 
         if (this.getAttribute(SharedMonsterAttributes.ATTACK_DAMAGE) == null) 
                               ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:155: error: cannot find symbol 
            this.getAttributes().registerAttribute(SharedMonsterAttributes.ATTACK_DAMAGE); 
                                                   ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:155: error: cannot find symbol 
            this.getAttributes().registerAttribute(SharedMonsterAttributes.ATTACK_DAMAGE); 
                ^ 
  symbol: method getAttributes() 
C:\Users\user\MCreatorWorkspaces\sussy_mod\src\main\java\net\mcreator\sussymod\entity\ImpostorEntity.java:156: error: cannot find symbol 
         this.getAttribute(SharedMonsterAttributes.ATTACK_DAMAGE).setBaseValue(10); 
                           ^ 
  symbol:   variable SharedMonsterAttributes 
  location: class CustomEntity 
20 errors 
FAILURE: Build failed with an exception. 
* What went wrong: 
Execution failed for task ':compileJava'. 
> Compilation failed; see the compiler error output for details. 
* Try: 
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. 
* Get more help at https://help.gradle.org 
BUILD FAILED in 1s 
1 actionable task: 1 executed 
BUILD FAILED

Hello, so I was trying to create a mob with a custom model into my mod and it's not compiling correctly. When I checked the build log there were multiple occurrences of an "error: cannot find symbol", and the listed failure was "execution failed for task ':compileJava.'" Attached here is the full build log, so if anyone could help me out on this it would be greatly appreciated. Thank you!