Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Solved make a plugin support both apis

Comments in 'Plugin Development' started by amiremad, Mar 2, 2016.

  1. amiremad
    Offline

    amiremad Active Member

    Joined:
    Sep 8, 2015
    Posts:
    192
    Minecraft User:
    amir107
    how to make my plugin support 2 apis 1.0.0 and 2.0.0

    thats my plugin.yml file

    Code:
    name: Op-Manager
    main: mcrafters\OpManager
    version: 3.0.2
    api: 1.0.0
    load: STARTUP
    author: MCrafters
    description: Soon Number #1 Op-Protection Plugin
    
    permissions:
    
      opmanager.nokick:
        default: false
        description: "Protects op from being kicked"
    
      opmanager.noban:
        default: false
        description: "Protects op from being banned"
    
      opmanager.disablestop.command:
        default: false
        description: "Disables stop command"
    
      opmanager.disabletime.command:
        default: false
        description: "Disables time command"
    
      opmanager.disablewhitelist.command:
        default: false
        description: "Disables whitelist command"
    
      opmanager.disablekill.command:
        default: false
        description: "Disables kill command"
    
      opmanager.disablesay.command:
        default: false
        description: "Disables say command"
    
      opmanager.disableban.command:
        default: false
        description: "Disables ban command"
    
      opmanager.disablebanip.command:
        default: false
        description: "Disables ban-ip command"
    
      opmanager.disabletp.command:
        default: false
        description: "Disables tp command"
    
      opmanager.disableop.command:
        default: false
        description: "Disables op command"
    
      opmanager.disableme.command:
        default: false
        description: "Disables me command"
    
      opmanager.disabledeop.command:
        default: false
        description: "Disables deop command"
    
  2. CraftYourBukkit
    Offline

    CraftYourBukkit Notable Member Plugin Developer

    Joined:
    Jan 20, 2015
    Posts:
    1,022
    Plugins:
    2
    Minecraft User:
    CraftYourBukkit
    Using an array.
    Code:
    api: []
    But them in there
  3. XxD7omGamer
    Offline

    XxD7omGamer New Member

    Joined:
    Jun 28, 2015
    Posts:
    38
    Minecraft User:
    XxD7omGamer
    Use this
    Code:
    api:
    - 1.0.0
    - 2.0.0
    - #Api
    Last edited: Mar 3, 2016
    applqpak and PEMapModder like this.
  4. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,294
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Comments in YAML should start with # not //
  5. amiremad
    Offline

    amiremad Active Member

    Joined:
    Sep 8, 2015
    Posts:
    192
    Minecraft User:
    amir107
    thx alot
    XxD7omGamer likes this.

Share This Page

Advertisement