Use GENERIC_MAX_HEALTH attribute when setting mount health.
getMaxHealth() is deprecated. Partial fix for #406
This commit is contained in:
@@ -960,7 +960,7 @@ public class ArenaImpl implements Arena
|
||||
mount.setTamed(true);
|
||||
mount.setOwner(p);
|
||||
mount.addPassenger(p);
|
||||
mount.setHealth(mount.getMaxHealth());
|
||||
mount.setHealth(mount.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue());
|
||||
|
||||
// Add saddle
|
||||
mount.getInventory().addItem(new ItemStack(Material.SADDLE));
|
||||
|
||||
Reference in New Issue
Block a user