Solved Adding player information?

Discussion in 'Plugin Development' started by thapengwin, May 13, 2013.

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

    thapengwin

    I need to set a string/boolean to a player (isWither), but I don't know how to do it. Any help would be appreciated!
     
  2. You can't set information directly in the Player object, you need to save stuff like that separately in your plugin by using Maps or Sets or Lists...

    For your purpose, a boolean, best way would be to use a Set, see here for examples as I really don't want to repeat myself in such a short time: http://forums.bukkit.org/threads/how-to-create-player-isjailed.147107/#post-1669535

    If you want the information to be persistent you need to save them to file, easiest way would be in a YML file.
    You should search about saving data to file because it has been discussed ALOT.
     
  3. Offline

    thapengwin

    Thanks! Will test it now!
     
Thread Status:
Not open for further replies.

Share This Page