Solved Healing 1 heart

Discussion in 'Plugin Development' started by Wingas, Aug 5, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    Wingas

    How to make code witch healing player by 1 heart?
     
  2. Offline

    KaitouKidFTW

    > Get the amount of heart player has.
    > Add 1 heart
     
  3. Offline

    irfantogluk

    Player player = e.getPlayer();
    Damageable dplayer = (Damageable)player;
    double health = dplayer.getHealth();
    dplayer.setHealth(health + 2);
     
    djyee and Wingas like this.
Thread Status:
Not open for further replies.

Share This Page