Add API to manipulate boss bar of entities and those created by commands

By: Yannick Lamprecht <yannicklamprecht@live.de>
This commit is contained in:
CraftBukkit/Spigot
2018-11-10 20:22:39 +11:00
parent 6f6c96bd33
commit 3433c5e374
8 changed files with 227 additions and 25 deletions

View File

@@ -13,6 +13,15 @@
public class EntityWither extends EntityMonster implements IRangedEntity {
private static final DataWatcherObject<Integer> a = DataWatcher.a(EntityWither.class, DataWatcherRegistry.b);
@@ -19,7 +25,7 @@
private final int[] bI = new int[2];
private final int[] bJ = new int[2];
private int bK;
- private final BossBattleServer bL;
+ public final BossBattleServer bL; // PAIL private -> public, rename bossBattleServer
private static final Predicate<Entity> bM = (entity) -> {
return entity instanceof EntityLiving && ((EntityLiving) entity).getMonsterType() != EnumMonsterType.UNDEAD && ((EntityLiving) entity).df();
};
@@ -181,13 +187,38 @@
if (this.dz() > 0) {
i = this.dz() - 1;