geforkt von Mirrors/Paper
SPIGOT-6820: VillagerCareerChangeEvent's ChangeReason is sometimes incorrect
By: Doc <nachito94@msn.com>
Dieser Commit ist enthalten in:
Ursprung
2492a39911
Commit
cc70f18bef
@ -19,7 +19,7 @@
|
||||
protected void start(WorldServer worldserver, EntityVillager entityvillager, long i) {
|
||||
- entityvillager.setVillagerData(entityvillager.getVillagerData().setProfession(VillagerProfession.NONE));
|
||||
+ // CraftBukkit start
|
||||
+ VillagerCareerChangeEvent event = CraftEventFactory.callVillagerCareerChangeEvent(entityvillager, CraftVillager.nmsToBukkitProfession(VillagerProfession.NONE), VillagerCareerChangeEvent.ChangeReason.EMPLOYED);
|
||||
+ VillagerCareerChangeEvent event = CraftEventFactory.callVillagerCareerChangeEvent(entityvillager, CraftVillager.nmsToBukkitProfession(VillagerProfession.NONE), VillagerCareerChangeEvent.ChangeReason.LOSING_JOB);
|
||||
+ if (event.isCancelled()) {
|
||||
+ return;
|
||||
+ }
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren