Solved NMS not spawn wolf

Discussion in 'Spigot Plugin Development' started by iO_5, Jan 11, 2020.

  1. But can spawn Zombie

    This error
    Code (Text):
    [18:15:49 WARN]: java.lang.NoSuchMethodException: cn.mcres.imiPet.AggressiveBat.<init>(net.minecraft.server.v1_12_R1.World)
    [18:15:49 WARN]:        at java.lang.Class.getConstructor0(Unknown Source)
    [18:15:49 WARN]:        at java.lang.Class.getConstructor(Unknown Source)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.EntityTypes.a(SourceFile:155)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.EntityTypes.a(SourceFile:169)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.EntityTypes.a(SourceFile:176)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.ChunkRegionLoader.a(ChunkRegionLoader.java:532)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.ChunkRegionLoader.a(ChunkRegionLoader.java:473)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.ChunkRegionLoader.loadEntities(ChunkRegionLoader.java:432)
    [18:15:49 WARN]:        at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOProvider.callStage2(ChunkIOProvider.java:42)
    [18:15:49 WARN]:        at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOProvider.callStage2(ChunkIOProvider.java:1)
    [18:15:49 WARN]:        at org.bukkit.craftbukkit.v1_12_R1.util.AsynchronousExecutor$Task.finish(AsynchronousExecutor.java:188)
    [18:15:49 WARN]:        at org.bukkit.craftbukkit.v1_12_R1.util.AsynchronousExecutor.finishActive(AsynchronousExecutor.java:347)
    [18:15:49 WARN]:        at org.bukkit.craftbukkit.v1_12_R1.chunkio.ChunkIOExecutor.tick(ChunkIOExecutor.java:34)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.MinecraftServer.D(MinecraftServer.java:763)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.DedicatedServer.D(DedicatedServer.java:406)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.MinecraftServer.C(MinecraftServer.java:679)
    [18:15:49 WARN]:        at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:577)
    [18:15:49 WARN]:        at java.lang.Thread.run(Unknown Source)
    [18:15:49 WARN]: Skipping Entity with id minecraft:wolf
    This code
    upload_2020-1-11_18-24-53.png

    upload_2020-1-11_18-25-32.png

    This tutorial
    https://www.spigotmc.org/threads/1-...override-existing-entities-and-to-not.194459/
     
  2. For tldr; you need a constructor present with the net.minecraft.World as only parameter.