1.12.2 A Problem About Damage Resistance

Discussion in 'Spigot Plugin Development' started by ManagerBoss, Feb 21, 2020.

  1. I want to get a player's remaining damage resistance amount(The gold hearts)?
  2. but I can't find a proper function to get the answer
  3. Damagable#gerAbsorptionMount() maybe?
  4. Golden hearts, or absorption hearts, are not accessible in your current spigot version 1.12.2.

    The getter/setter were added in this commit.

    As they are simply wrapping calls against the EntityPlayer instance, you could try to use NMS. This way you could access the values in spigot 1.12.2.