Health max 1024

Discussion in 'Plugin Development' started by Zanction, Oct 13, 2017.

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

    Zanction

    Now before I sound dumb, I have been told this is a spigot issue it the spigot config.
    attribute:
    maxHealth:
    max: 50000.0

    Player and Mob health doesn't go over 1024
     
  2. Offline

    MightyOne

    What is the meaning of this?
    What did you try to do?
    Where did the the error appear?
    How may somebody help you?
    Read the HowTo before you post something
     
    Last edited: Oct 13, 2017
  3. Offline

    Zombie_Striker

    @Zanction
    You cannot set the health over 1024. This is a limitation for minecraft. The only way to get around this would be to scale down the damage the entity receives so it seems like it has 50k health.

    BTW: This has been covered on multiple threads. Please use google before making new posts.
     
  4. Offline

    Zanction

    @MightyOne
    I have an MMO RPG Server that I'm coding and the custom mobs that spawn and the players can have up to 50k health. I am trying to set the players health to what ever the health is on the lore of the chestplate
    i.e HP: +5603
    When the hp is set it caps at 1024

    @Zombie_Striker
    I have read multiple forum about this issue and they never come to a solution. I have seen that you can change it in the spigot.yml and when I do that it doesn't work
     
  5. Offline

    Zombie_Striker

    @Zanction
    That is because the packets support a byte value up to only 1024. Any more than that will overflow.

    The only way to "achieve" (more like simulate) higher values would be to reduce the damage for that entity. Just multiply the damage by 1024/MAX_HEALTH to get the same effect.
     
  6. Offline

    Zanction

    I changed the spigot settings in my server file. All works now - just a spigot issue
    @Zombie_Striker
     
Thread Status:
Not open for further replies.

Share This Page