FileConfiguration

Discussion in 'Plugin Development' started by Batman500, Jun 3, 2014.

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

    Batman500

    How do I get all "command"?
    example:
    Code:java
    1. for(String s : getConfig().getString("Commands") {
    2. getConfig().getList("Commands." + "s");
    3. }



    Config.yml
    Code:
    Commands:
      commnand1:
          - say 1
          - say 2
      commnand2:
          - say a
          - say b
      commnand3:
          - say 11
          - say  11
      commnand4:
          - say bb
          - say bb
     
    
     
  2. Offline

    THEREDBARON24

    use getConfigurrationSection("Commands").getKeys(false) this will return command1 through command4 (if this is what you are looking for)
     
Thread Status:
Not open for further replies.

Share This Page