1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Need Samples

Discussion in 'Facepalm' started by PianoRalph04, Feb 14, 2017.

  1. PianoRalph04

    PianoRalph04 Witch

    Messages:
    60
    GitHub:
    MechRalph04
    Hey guys, I tried to make a plugin, but I kept failing. I want to have a sample codes for commands.
    I would like to make sure at plugin.yml, this is right:


    name: RalphCraft
    author: PianoRalph04
    api: [3.0.0-ALPHA2]
    version: 1.0
    main: RalphCool/1stpl

    command:
    ralphcpe:
    description: PR04's 1st cmd
    usage: /ralphcpe

    permissions:
    ralph.cmd.ralphcpe:
    default: true




    Tell me if there is something wrong, and also, show me atleast a sample. Thank you.
    I need some sample for commands. I made this plugin for test. and to make sure if it works
    and the next time I make plugins.
     
  2. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    Spacing is important in YAML
    Code:
    name: RalphCraft
    author: PianoRalph04
    api: [3.0.0-ALPHA2]
    version: 1.0
    main: RalphCool\1stpl
    
    commands:
      ralphcpe:
        description: PR04's 1st cmd
        usage: /ralphcpe
    
    permissions:
      ralph.cmd.ralphcpe:
        default: true
    
     
    Last edited: Feb 17, 2017
    PianoRalph04 likes this.
  3. ZakousseMC

    ZakousseMC Spider Jockey

    Messages:
    46
    GitHub:
    ZakousseMC
    Do not forget, slashs are very important

    Code:
    main: example\example
    
    Instead of
    Code:
    main: example/example
    
    Also, check "Resources" forum before posting, there is very useful things such as " https://forums.pmmp.io/threads/plugin-tutorial-for-future-developers.25/ "
    EDIT : Made a mistake, should be good now.
    EDIT 2 : Please use
    Code:
     [CODE] 
    for your codes and
    PHP:
     [PHP
    for php.
     
    Last edited: Feb 14, 2017
    PianoRalph04 and Jack Noordhuis like this.
  4. PianoRalph04

    PianoRalph04 Witch

    Messages:
    60
    GitHub:
    MechRalph04
    Thx
     
  5. PianoRalph04

    PianoRalph04 Witch

    Messages:
    60
    GitHub:
    MechRalph04
    Thx
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.