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

Solved Is there a way to block the command /me?

Comments in 'Plugin Development' started by TheBison_, Feb 10, 2016.

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

    TheBison_ New Member

    Joined:
    Mar 31, 2014
    Posts:
    46
    Minecraft User:
    TheBisonXD_
    Please read the title :D
  2. MichaelM04
    Offline

    MichaelM04 Active Member Plugin Developer

    Joined:
    Nov 12, 2015
    Posts:
    213
    Plugins:
    1
    Minecraft User:
    Michael
    yes use pureperms and type this under the group
    - -pocketmine.command.me
    TheBison_ likes this.
  3. TheBison_
    Offline

    TheBison_ New Member

    Joined:
    Mar 31, 2014
    Posts:
    46
    Minecraft User:
    TheBisonXD_
  4. cake23
    Offline

    cake23 Active Member

    Joined:
    Aug 10, 2015
    Posts:
    124
    Minecraft User:
    TheEnd
    Ist ganz einfach: :)
    PHP:
    public function PlayerCommandPreprocessEvent (PlayerCommandPreprocessEvent $event){
            
    $player $event->getPlayer();
            
    $com explode(" "$event->getMessage());
                if(
    $com[0] == "/me") {
                    
    $event->setCancelled(true);
                }
    }
    TheBison_ likes this.
  5. MichaelM04
    Offline

    MichaelM04 Active Member Plugin Developer

    Joined:
    Nov 12, 2015
    Posts:
    213
    Plugins:
    1
    Minecraft User:
    Michael
    Already solved again.... Please stop commenting on solved threads
  6. cake23
    Offline

    cake23 Active Member

    Joined:
    Aug 10, 2015
    Posts:
    124
    Minecraft User:
    TheEnd
    Sorry.. :(
  7. Bluplayz
    Offline

    Bluplayz Active Member

    Joined:
    Aug 20, 2015
    Posts:
    74
    Minecraft User:
    Bluplayz
    xD setCancelled() ist default auf True also unnötig :p

    Sorry for german and posting after solved
    cake23 likes this.
Thread Status:
Not open for further replies.

Share This Page

Advertisement