Solved Getting last used kit

Discussion in 'Plugin Development' started by xepisolonxx, May 3, 2014.

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

    xepisolonxx

    I have been trying to get a last used kit by a player can any1 tell me how i can go about doing this?
     
  2. Offline

    Drkmaster83

    This is a very ambiguous request and we cannot help you until you let us know what you mean by "kit". Are you talking about Essentials kits, Custom-coded kits, or something else?
     
  3. Offline

    xepisolonxx

    Custom coded kits i need a method or atleast a way of wich i can be able to get the last kit a player uses like to save the command he does as a string? Or save it as a hashmap.
     
  4. Offline

    coasterman10

    xepisolonxx A HashMap would be the way to go. You can save the name of the kit a player last used to the map under their username or UUID and then check the name of kit they last used by accessing the map.
     
  5. Offline

    xepisolonxx

  6. Offline

    xTigerRebornx

    coasterman10 An alternative to HashMaps could be the use of Bukkit's Metadata system, simply attaching a MetadataValue with a permanent/global key and some kind of value determine which kit was used (String, int, Enum, etc) to the Player (and persist as needed)
     
Thread Status:
Not open for further replies.

Share This Page