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

player sendPopup

Comments in 'Plugin Development' started by Svile, Mar 19, 2016.

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

    Svile Active Member

    Joined:
    Mar 30, 2015
    Posts:
    239
    Minecraft User:
    svile
    Can someone please send me an example of the player->sendPopup() subtitle ? i haven't got time to try it and i want to know how it looks :(

    Thanks!
  2. Skullex
    Offline

    Skullex Active Member

    Joined:
    Nov 14, 2015
    Posts:
    212
    Minecraft User:
    Skullex
    PHP:
    <?php

    namespace example;

    use 
    pocketmine\plugin\PluginBase;
    use 
    pocketmine\utils\TextFormat;
    use 
    pocketmine\event\player\PlayerJoinEvent;
    use 
    pocketmine\event\Listener;

    class 
    Example extends PluginBase implements Listener{

    public function 
    onEnable(){

        public function 
    onJoin(PlayerJoinEvent $event){
        
    $player $event->getPlayer();
        
    $event->getPlayer()->sendPopup(TextFormat::BLUE ."Welcome!");
        }
    }
    TxnneriOS likes this.
  3. Intyre
    Offline

    Intyre Staff Member PocketMine Team

    Joined:
    Aug 24, 2013
    Posts:
    118
    Minecraft User:
    Intyre
    [​IMG]
    xiaoq, KubixQ, PEMapModder and 3 others like this.
Thread Status:
Not open for further replies.

Share This Page

Advertisement