How to use ProtocolLib for Individual Scoreboards?

Discussion in 'Plugin Development' started by Ambamore2000, Dec 24, 2014.

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

    Ambamore2000

    Hello, so, I am wondering how I would use ProtocolLib for scoreboards to send differently towards invidivual players. Why, my reason of not using the getNewScoreboard() method, is because I am trying to make my plugin Health Bar compatible, which doesn't seem to be compatible with getNewScoreboard(). Please tell me, as, I am not experienced with the ProtocolLib API. Thanks in advanced.

    bump

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 10, 2016
  2. Offline

    Konato_K

    @Ambamore2000 Have you tried getting the scorebord that this plugin sets to the player?
     
  3. Offline

    Ambamore2000

    Why would I do that exactlyM
     
  4. Offline

    Konato_K

    @Ambamore2000 Player#getScoreboard will give you the scoreboard the player has set, if you get this after HealthBar does it's stuff, then you'll get that scoreboard
     
  5. Offline

    Fabricio20

    What is not compatible? For me it is.
    Just create a new scoreboard with a method and call it every time someones hit,join the server etc..
     
  6. Offline

    Ambamore2000

    @Konato_K Healthbar does it's stuff randomly?

    @Fabricio20 The healthbar under the players username doesn't show when I tried this, which is also the problem from before.
     
    Last edited by a moderator: Dec 25, 2014
  7. Offline

    Konato_K

    @Ambamore2000 What do you mean? I haven't used HealthBar plugin in a while, but I guess it does player.setScoreboard somewhere putting the scoreboard for the health bar, later in your plugin you can use player.getScoreboard to get the same scoreboard as the plugin and do whatever you wanna do with it.
     
  8. Offline

    Ambamore2000

    @Konato_K I'll try this out when I can. :D It seems reasonable to work.
    EDIT: The HealthBar plugin makes the scoreboard under the players username, but I want the scoreboard to be set at the sidebar. Got any ideas?
     
  9. Offline

    Konato_K

    @Ambamore2000 As far I know the sidebar and nameplate stuff are bound to the objective, not the scoreboard itself.
     
  10. Offline

    Ambamore2000

Thread Status:
Not open for further replies.

Share This Page