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

[HELP] Gamemode plugin don't work

Comments in 'Plugin Development' started by Aljaz5513, Jul 23, 2014.

  1. Aljaz5513
    Offline

    Aljaz5513 New Member

    Joined:
    Jul 23, 2014
    Posts:
    3
    Hello,
    I have problem with Plugin so Im making EasyGMchange plugin for pocketmine but it just dont work so I need help. soo its for API 12 and im running api 12 on my android pocketmine,everything works good heres. Plugin is running and everything but when i type /help or command /gm which is used to do nothing happens is there any resolution? thanks
    nice day!
    LDX likes this.
  2. Renzo
    Offline

    Renzo Active Member

    Joined:
    Mar 12, 2014
    Posts:
    96
    Minecraft User:
    Renzo_4
    Why are you developing it for API 12/ 1.3.12? PocketMine 1.4 is coming soon!
    PEMapModder and Hiddenfootball like this.
  3. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Mr. Doctor, my leg hurts. But I won't tell you which part of my leg hurts, nor am I going to let you touch my leg.
  4. swagboy47
    Offline

    swagboy47 Active Member

    Joined:
    Jun 10, 2014
    Posts:
    445
    Minecraft User:
    swagking
    LOOOL
  5. PluginMastered
    Offline

    PluginMastered Active Member

    Joined:
    Mar 1, 2014
    Posts:
    161
    Minecraft User:
    Flexa33
    • Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe.
    This refers to nobody i just like this quote by Albert Einstein
    PEMapModder likes this.
  6. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Einstein believes that the universe is neither infinite nor with boundary.
  7. swagboy47
    Offline

    swagboy47 Active Member

    Joined:
    Jun 10, 2014
    Posts:
    445
    Minecraft User:
    swagking
    the universe is not infinite according to big bang because it's an explosion from nothingness and it gets bigger and bigger but its not infinite and after about 2*10 billion by the 6 billion power times 100000000 gooogol light years the universe well run out of matter and eventually collapse on it self , and if you are able to watch it out side of the universe you well see it as flash back from the big bang ( i didn't get this info from google i realized that by my self and then asked google for confirmation)
    Last edited: Jul 24, 2014
    PEMapModder likes this.
  8. PluginMastered
    Offline

    PluginMastered Active Member

    Joined:
    Mar 1, 2014
    Posts:
    161
    Minecraft User:
    Flexa33
    I know all of this "and im not sure about the universe"
    PEMapModder likes this.
  9. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Configuration?

    I remember it's kind of a 4D circle-like thing, like when you go to the "boundary" you in fact are like traveled round Earth.
    PluginMastered likes this.
  10. PluginMastered
    Offline

    PluginMastered Active Member

    Joined:
    Mar 1, 2014
    Posts:
    161
    Minecraft User:
    Flexa33
    With some quotes you can realise that you can get really smart these days :D .
    PEMapModder likes this.
  11. swagboy47
    Offline

    swagboy47 Active Member

    Joined:
    Jun 10, 2014
    Posts:
    445
    Minecraft User:
    swagking
    confirmation sorry
  12. Aljaz5513
    Offline

    Aljaz5513 New Member

    Joined:
    Jul 23, 2014
    Posts:
    3
    thats how you help people? thanks!
  13. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    How do you expect Mr. Doctor to help you if you don't tell him what hurts and don't let him even look at you?
  14. Aljaz5513
    Offline

    Aljaz5513 New Member

    Joined:
    Jul 23, 2014
    Posts:
    3
    PHP:
    <?php

    /*
    __PocketMine Plugin__
    name=Easy Gamemode Changer
    description=Plugin created by Aljaz5513
    version=1.0
    author=Aljaz5513
    class=nbLfMvWx
    apiversion=12
    */

        
    class nbLfMvWx implements plugin{

        private 
    $api;

        public function 
    __construct(ServerAPI $api$server false){

            
    $this->api $api;

        }

        public function 
    init(){

        
    $this->api->addHandler("player.gamemode.change", array($this"eventHandler"), 100);

        }
       
        public function 
    eventHandler($data$event)
        {
        switch(
    $event)
        {
            case 
    'player.gamemode.change':
           
                
    $this->api->console->run("");
           
            break;
        }

        }

        public function 
    __destruct(){

        }

    }
  15. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    This plugin, obviously, is generated through a plugin generator. Also, you handle the event when a player changes his gamemode, and you didn't register the command at all. Moreover, the handler of the gamemode change event does nothing except runs a void command "" as console. This forum is for those who have questions in the plugins they made, not the plugins they generated using the online plugin generator. If you want support for the online plugin generator on this website, please reply to that thread or send a private message to the creator.
    Renzo and PluginMastered like this.

Share This Page

Advertisement