OnTablComplete with a config help

Discussion in 'Spigot Plugin Help' started by KoalaOnCaffeine6, Jul 21, 2018.

  1. I was making a plugin where you can tab complete an argument in /warn for reasons why. But when i make a list of reasons in the config like this:
    Code (Text):
    warn-reasons:
    - reason
    - reason2
    - reason3
    then it will come out when i tabcomplete as [reason, reason2, reason3]

    Anyone know how i can split these to be all seperate and when i press tab it cycles through them.

    Thanks <3
     
  2. Get config string list.
    Add to arraylist.
    Cycle through arraylist.
    Magic.
     
  3. Hello!
    i think you could check with a loop structure: for()
     
    • Optimistic Optimistic x 1
  4. do you need an example? ^-^'
     
  5. I was saying optimistic bc no fuckong shit