Solved "Aditional hearts" in the bukkit 1.7.5

Discussion in 'Plugin Development' started by gabrielhowat, May 23, 2014.

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

    gabrielhowat

    Hell, guys. I updated my server to 1.7.5, for fix some bugs in my plugin, and now, the player's life have a 4,5 aditional hearts, but these hearts are locked at this. If you take a damage, your health comes back to that, and the players have an "infinity health". Is there any way to fix that?

    [​IMG]
     
  2. You might want to post the code regarding this situation. gabrielhowat
     
  3. Offline

    gabrielhowat

    RAFA_GATO_FOFO
    Well... My plugin haves 70 classes :p
    How I will found where is the problem?
     
  4. gabrielhowat
    If you coded it you should know where the problem is.
    If you don't know where the problem is, well... keep searching :)
     
  5. Offline

    gabrielhowat

    RAFA_GATO_FOFO
    But I didn't coded this, that appeared before I updated my server from 1.7.2 to 1.7.5...
     
  6. gabrielhowat
    First of all English is appreciated. Throwing random words at the screen won't make me understand what you're looking for. If you didn't code the plugin how do you know it has 70 classes? If you didn't code it why and how do you want to change it?
     
  7. Offline

    gabrielhowat

    First, I'm sorry if I'm Brazilian. I think you guys should have more patience with people who do not have much fluency with English, remember that not English is the only language in the world;)
    Second, I made this plugin, I said I did not do anything to make this change happen, not in my plugin, just the server that was updated
     
  8. gabrielhowat
    I'm from Portugal and you don't see me whining about not knowing English. It's a necessity in the world we live in.
    It may not be the only language in the world but it's obviously the most important.
    And I already said, if you coded the plugin you obviously have some Bukkit API knowledge. And if you do you should probably figure out where the problem is. When you do you can post some code so we can help you.
     
  9. Offline

    rsod

    try to search for "absorption" string in your plugin
     
  10. Offline

    gabrielhowat

    rsod
    My plugin has coded in 1.7.2, so the plugin don't have any function of 1.7.5 or higher.
    I belive its only a bug, but I need to fix that
     
  11. Offline

    Gater12

    gabrielhowat
    You should know where it is happening. Look into the code involving player's health.
     
  12. Offline

    gabrielhowat

    Well, I founded that, is in here:

    Code:java
    1. @EventHandler
    2. public void onHeal(EntityRegainHealthEvent event) {
    3. // event.setCancelled(true);
    4. }


    That prevents the player to be auto healed by the game, is there other way to do that without this event?
     
  13. Offline

    Plo124

    gabrielhowat
    It appears your plugin, or another, is giving out the absorbtion potion effect. This is why the additional hearts are yellow.
     
  14. Offline

    gabrielhowat

    Plo124
    The problem are in here:
    Code:java
    1. @EventHandler
    2. public void onHeal(EntityRegainHealthEvent event) {
    3. // event.setCancelled(true);
    4. }


    But I fixed that! I only deleted the setCancalled and called the event.setAmount(0)
    :D
    Thx for everybody
     
Thread Status:
Not open for further replies.

Share This Page