setVillager is not supported
TheLorv opened this issue ยท 9 comments
Hi there! I'm Lorv and I have recently started a Minecraft Server with a co-worker of mine. We changed our server to 1.11.2, hoping that ExtraHardMode is compatible with further versions of Spigot. However, here are the following errors that we have:
EntityExplodeEvent:
Could not pass event EntityExplodeEvent to ExtraHardMode v3.8.9
org.bukkit.event.EventException
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:306) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:502) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:487) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.Explosion.a(Explosion.java:194) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.createExplosion(World.java:1875) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.WorldServer.createExplosion(WorldServer.java:1176) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.EntityLargeFireball.a(EntityLargeFireball.java:32) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.EntityFireball.A_(EntityFireball.java:74) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.entityJoinedWorld(World.java:1629) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.h(World.java:1604) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.tickEntities(World.java:1430) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.WorldServer.tickEntities(WorldServer.java:617) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.D(MinecraftServer.java:806) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.DedicatedServer.D(DedicatedServer.java:399) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.C(MinecraftServer.java:675) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.run(MinecraftServer.java:574) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]
Caused by: java.lang.UnsupportedOperationException: Not supported.
at org.bukkit.craftbukkit.v1_11_R1.entity.CraftZombie.setVillager(CraftZombie.java:45) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at com.extrahardmode.features.monsters.Glydia.onExplosion(Glydia.java:478) ~[ExtraHardMode.jar:?]
at sun.reflect.GeneratedMethodAccessor584.invoke(Unknown Source) ~[?:?]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_111]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_111]
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
PotionSplashEvent:
Could not pass event PotionSplashEvent to ExtraHardMode
org.bukkit.event.EventException
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:306) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:502) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:487) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at org.bukkit.craftbukkit.v1_11_R1.event.CraftEventFactory.callPotionSplashEvent(CraftEventFactory.java:345) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.EntityPotion.a(EntityPotion.java:158) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.EntityPotion.a(EntityPotion.java:100) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.EntityProjectile.A_(EntityProjectile.java:167) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.entityJoinedWorld(World.java:1629) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.h(World.java:1604) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.World.tickEntities(World.java:1430) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.WorldServer.tickEntities(WorldServer.java:617) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.D(MinecraftServer.java:806) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.DedicatedServer.D(DedicatedServer.java:399) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.C(MinecraftServer.java:675) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at net.minecraft.server.v1_11_R1.MinecraftServer.run(MinecraftServer.java:574) [Spigot.jar:git-Spigot-7d78b81-775f1e1]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]
Caused by: java.lang.UnsupportedOperationException: Not supported.
at org.bukkit.craftbukkit.v1_11_R1.entity.CraftZombie.setVillager(CraftZombie.java:45) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
at com.extrahardmode.features.monsters.Witches.onPotionSplash(Witches.java:145) ~[ExtraHardMode.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_111]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_111]
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ~[Spigot.jar:git-Spigot-7d78b81-775f1e1]
If possible, are you able to update the plugin to v1.11.2? We really need this plugin because it enhances our play-style and makes Minecraft a lot more difficult. Thank You.
Yea, these are known bugs. The rest of the plugin should be functioning fine, it's just failing to turn villagers into zombie villagers due to an API change. While there is a PR to fix this, it's unfortunately mixed in with other additions that I need to review more carefully. If you guys can, you can look over that PR and send in a new PR which fixes just this issue, and that'd be far faster for me to review and merge.
Is it possible to make zombies stop targeting villagers to fix this issue?
Also, even though this is not related to the "Events," how can we disable the tutorial, notification, and broadcast messages completely? I just want it to show the notifications and nothing else, but it still shows the broadcast and tutorial messages.
Sorry. We're new to GitHub, but how do we do pull requests?
https://github.com/MLG-Fortress/ExtraHardMode/compare
Is it possible to make zombies stop targeting villagers to fix this issue?
Hmm?
Also, even though this is not related to the "Events," how can we disable the tutorial, notification, and broadcast messages completely? I just want it to show the notifications and nothing else, but it still shows the broadcast and tutorial messages.
Messages.yml. Set desired messages with type DISABLED
Messages.yml. Set desired messages with type DISABLED
Here is what I currently have in my "messages.yml" file. I'm not sure what you mean by "type.":
Messages:
Display Messages In Scoreboard:
Enable: false
Scoreboard Title: '&cExtraHardMode'
Remove All Color Codes: true
Notification:
Enable: true
Displaytime In Ticks: 600
Textcolor: YELLOW
Tutorial:
Enable: false
Displaytime In Ticks: 1800
Textcolor: RED
Broadcast:
Enable: false
Displaytime In Ticks: 1200
Textcolor: GREEN
NoTorchesHere:
Mode: notification
Msg: Cannot Place Torches Here - Insufficient Air
StoneMiningHelp:
Mode: notification
Msg: Cannot Mine Stone - Use An Iron/Diamond Pickaxe
NoPlacingOreAgainstStone:
Mode: notification
Msg: Cannot Place Ore - Next To Stone
RealisticBuilding:
Mode: notification
Msg: Cannot Build Here - In The Air
RealisticBuildingBeneath:
Mode: notification
Msg: Cannot Build Here - Directly Below Air
LimitedTorchPlacements:
Mode: notification
Msg: Cannot Place Torches Here - Block Too Soft
NoCraftingMelonSeeds:
Mode: notification
Msg: That appears to be seedless!
LimitedEndBuilding:
Mode: notification
Msg: Cannot Build Here - End
DragonFountainTip:
Mode: notification
Msg: You Defeated The Dragon - Use An Enderpearl If You Can't Reach The Portal
NoSwimmingInArmor:
Mode: notification
Msg: Cannot Swim - Too Much Weight In Inventory
DragonDefeated:
Mode: broadcast
Msg: 'The dragon has been defeated! ( By: $PLAYERS )'
PlayerKilledByDragon:
Mode: broadcast
Msg: $PLAYER was killed while fighting the dragon!
PlayerChallengingDragon:
Mode: broadcast
Msg: $PLAYER is challenging the dragon!
HorseFeedLow:
Mode: notification
Msg: Horse Is Still Hungry
HorseFeedMiddle:
Mode: notification
Msg: Your Horse Is Moderately Satiated
HorseFeedHigh:
Mode: notification
Msg: Your Horse Is Satiated
HorseStarveLow:
Mode: notification
Msg: Your Horse Is Feeling Hungry
HorseStarveMiddle:
Mode: notification
Msg: Your Horse Is Hungry
HorseStarveHigh:
Mode: notification
Msg: Your Horse Is Starving
ChargedCreeper:
Mode: tutorial
Msg: Charged Creepers explode instantly when hit. Run!
BlazeOverworld:
Mode: tutorial
Msg: Blazes spawn near lava and their fiery breath causes a big explosion on death!
BlazeNether:
Mode: tutorial
Msg: Blazes spawn everywhere in the Nether and may split on death!
Magmacube:
Mode: tutorial
Msg: These small buggers actually are just disguised blazes!
Ghast:
Mode: tutorial
Msg: These fearsome Ghasts wear invisible arrow deflective armor! Ghasts drop a lot more loot as well.
PigZombieAlwaysAngry:
Mode: tutorial
Msg: RUN! Pig Zombies are always angry and hungry!
PigZombieDropNetherwart:
Mode: tutorial
Msg: You can get netherwart from slaying Pig Zombies
ZombieRespawn:
Mode: tutorial
Msg: Zombies might resurrect if not on fire!
ZombieSlowPlayer:
Mode: tutorial
Msg: Zombies slow you down when hit!
SkeletonDeflectArrows:
Mode: tutorial
Msg: Arrows just pass through Skeletons, you gotta go close combat!
EndermanGeneral:
Mode: tutorial
Msg: Enderman can teleport you too!
CreeperDropTnt:
Mode: tutorial
Msg: Creepers may drop activated tnt on death!
ExtinguishFire:
Mode: tutorial
Msg: Putting out fire with your hand will catch you on fire.
ListLostItemsOnDeath:
Mode: notification
Msg: You managed to lose $ITEMS
InformPlayerOnLostItems:
Mode: tutorial
Msg: On death there is a a chance you might lose some of your items!
BucketFill:
Mode: tutorial
Msg: You can pick up water, but once you place it, it evaporates. Get some ice if you want to farm!
AntifarmingUnwatered:
Mode: tutorial
Msg: Your crops need sufficient water, otherwise they'll dry out!
AntifarmingNotEnoughLight:
Mode: tutorial
Msg: Your crops require natural light to grow!
AntifarmingDesert:
Mode: tutorial
Msg: Deserts are really dry and nothing grows here!
AnimalOverCrowd:
Mode: notification
Msg: Some Animals Killed - Need More Space
NetherWarning:
Mode: tutorial
Msg: This is a dangerous place. Make sure you come prepared with arrows and good gear.
FYI setting it to disable won't work on the current version on spigot since it has not been updated with the latest changes. #64
Robo maybe you could fix those setvillagers instead of waiting for pullrequests, its an easy fix and it takes you a lot less time since you can push it directly.
Thanks
Ok, so the right way to spawn a zombie villager is to spawn a ZombieVillager. Guessing that 1.11, along with Horses, has given these a new entity class.
Fixed in 2739264