How would I list information from a config file?

Discussion in 'Plugin Development' started by unrealdesign, Mar 20, 2013.

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

    unrealdesign

    What I want


    I want to be able to send a player a message after they type a command such that it calls from the config.yml file and then print it out to the player.
    What makes it hard to me:
    • The number of values after the first path may vary, so how do I get the length of config.yml file and do a for() statement that will work
    • Send the list of values in seperate lines
    Explanation


    Lets say I have a config file:

    Code:
    #Default Config FIle
    First:
      Second: 1
      Third: 22
    I want a player to be able to type a command (Ex: /test list) and then it sends them a message:


    Thanks in advance if you can give any help at all!
     
  2. Offline

    TnT

    Moved to the correct forum.
     
Thread Status:
Not open for further replies.

Share This Page