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

I want to ask a question.,

Comments in 'Plugin Development' started by zmdd, Jun 5, 2015.

  1. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    I want to ask a question.,
    I use /hl after using /list and /help, how can this be solved?


    For example
    when case "hl":
    use /list and /help


    I do not know what function can be this, please answer it, thank!
  2. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
  3. BalAnce
    Offline

    BalAnce Active Member

    Joined:
    Mar 10, 2015
    Posts:
    125
    Minecraft User:
    BalAnce
    Can you restate what happening cause i dont understand what you are asking or what your problem is so i cant help.
  4. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    ...sorry, I may not express what I mean.
    When I use /hl , I can use/list and /help .
    What should I do?
  5. BalAnce
    Offline

    BalAnce Active Member

    Joined:
    Mar 10, 2015
    Posts:
    125
    Minecraft User:
    BalAnce
    do you have any plugins installed? Also are you saying when you do /hl you cant do /list and /help? or it tell you to do /help and /list. Screenshots may help too. :)
  6. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    My English is not good... I want to express it.,when i use /hl then
    When I use /hl, I want to show the results of the /list and /help commands.,

    for example
    when i use:
    /hl
    The result of the input is:

    There are 0/20 players online:

    and

    --- Showing help page 1 of 1 (/help <page>) ---
    ........
  7. PixelGuy75
    Offline

    PixelGuy75 Notable Member Plugin Developer

    Joined:
    Feb 9, 2014
    Posts:
    316
    Plugins:
    2
    Minecraft User:
    PixelGuy75
    So are you wanting to make a plugin to do this?
    PEMapModder likes this.
  8. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    yes!!
  9. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    No plugins, go into your pocketmine.yml And look in the aliases section.
    LDX likes this.
  10. Legoboy0215
    Offline

    Legoboy0215 Notable Member

    Joined:
    Nov 1, 2014
    Posts:
    1,747
    Minecraft User:
    Legoboy0215
    I have about 20 aliases for my server already XD
  11. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    PHP:
    // handler of /hl
    // $issuer is the CommandSender of the command
    $this->getServer()->getCommandMap()->getCommand("help")->execute($issuer"help", []);
    $this->getServer()->getCommandMap()->getCommand("list")->execute($issuer"list", []);
    Last edited: Jun 6, 2015
  12. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Guys, this is in the plugin development forum. It is obvious.
  13. 64FF00
    Offline

    64FF00 Active Member Plugin Developer

    Joined:
    May 11, 2014
    Posts:
    298
    Plugins:
    2
    Minecraft User:
    64FF00
    Typos found in your code snippet. Hehehe
    PEMapModder likes this.
  14. Legoboy0215
    Offline

    Legoboy0215 Notable Member

    Joined:
    Nov 1, 2014
    Posts:
    1,747
    Minecraft User:
    Legoboy0215
    Yep... getComamnd("help")
    Command
  15. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    i want not "aliases",
    i want "When I use a command, the background can use another command”
    :(
  16. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Yes, this is what we are doing here.
    The first line sends the help message to the issuer.
    The second line sends the list message to the issuer.
    Unless you want to implement your own help/list code, this is the best way.
  17. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    thanks
    thanks
  18. zmdd
    Offline

    zmdd New Member

    Joined:
    Apr 26, 2014
    Posts:
    24
    Minecraft User:
    zmdd
    but...what is "$issuer"?
  19. BalAnce
    Offline

    BalAnce Active Member

    Joined:
    Mar 10, 2015
    Posts:
    125
    Minecraft User:
    BalAnce
    Thats the person that executed the command
  20. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    64FF00 likes this.

Share This Page

Advertisement