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

Scrolling Popups

Comments in 'Plugin Development' started by TheLucyClub, Apr 19, 2015.

  1. TheLucyClub
    Offline

    TheLucyClub Banned

    Joined:
    Jan 31, 2015
    Posts:
    53
    Minecraft User:
    iCreepyKid
    I want a plugin that makes Popups Scroll forvever. I don't want a config, I just want code. Also it scroll to all the players in my lobby world only. I would also like to modify simpleauth so it will spam a popup YOU NEED TO AUTHENTICATE! until you authenticate. Please someone help. Thanks!
  2. Falk
    Offline

    Falk Staff Member Global Moderator

    Joined:
    Sep 2, 2013
    Posts:
    1,710
    Plugins:
    22
    Minecraft User:
    Falkirknh
  3. TheLucyClub
    Offline

    TheLucyClub Banned

    Joined:
    Jan 31, 2015
    Posts:
    53
    Minecraft User:
    iCreepyKid
  4. TheLucyClub
    Offline

    TheLucyClub Banned

    Joined:
    Jan 31, 2015
    Posts:
    53
    Minecraft User:
    iCreepyKid
    OK. So, I made the plugin, but it doesn't do anything.
    PHP:
    namespace TimedPopup;

    use 
    pocketmine;

    //Main.php
    if(blah blah){
      
    $this->getServer()->getScheduler()->scheduleDelayedTask(new Task($this$player), 40); //show for 2 seconds
    }
    PHP:
    namespace TimedPopup\Task;

    use 
    pocketmine;

    //Task.php
    public function onRun($tick){
      switch(
    $tick){
        case 
    1:
          
    $this->player->sendPopup(TextFormat::RED "Welcome to SCPE!");
        case 
    1:
          
    $this->player->sendPopup(TextFormat::GOLD "elcome to SCPE! W");
        case 
    2:
          
    $this->player->sendPopup(TextFormat::YELLOW "lcome to SCPE! We");
        case 
    3:
          
    $this->player->sendPopup(TextFormat::GREEN "come to SCPE! Wel");
        case 
    4:
          
    $this->player->sendPopup(TextFormat::BLUE "ome to SCPE! Welc");
        case 
    5:
          
    $this->player->sendPopup(TextFormat::LIGHT_PURPLE "me to SCPE! Welco");
        case 
    6:
          
    $this->player->sendPopup(TextFormat::RED "e to SCPE! Welcom");
        case 
    7:
          
    $this->player->sendPopup(TextFormat::GOLD "to SCPE! Welcome");
        case 
    8:
          
    $this->player->sendPopup(TextFormat::YELLOW "o SCPE! Welcome t");
        case 
    9:
          
    $this->player->sendPopup(TextFormat::GREEN " SCPE! Welcome to");
        case 
    1:
          
    $this->player->sendPopup(TextFormat::BLUE "SCPE! Welcome to ");
        case 
    11:
          
    $this->player->sendPopup(TextFormat::LIGHT_PURPLE "CPE! Welcome to S");
        case 
    12:
          
    $this->player->sendPopup(TextFormat::RED "PE! Welcome to SC");
        case 
    13:
          
    $this->player->sendPopup(TextFormat::GOLD "E! Welcome to SCP");
        case 
    14:
          
    $this->player->sendPopup(TextFormat::YELLOW "! Welcome to SCPE");
        case 
    15:
          
    $this->player->sendPopup(TextFormat::GREEN " Welcome to SCPE!");
        case 
    16:
          
    $this->player->sendPopup("");
        case 
    17:
          
    $this->player->sendPopup("");

      }
    }
  5. TheLucyClub
    Offline

    TheLucyClub Banned

    Joined:
    Jan 31, 2015
    Posts:
    53
    Minecraft User:
    iCreepyKid
    Oh yeah
    PHP:
    use pocketmine;
    just means use everything pocketmine has.
  6. aliuly
    Offline

    aliuly Notable Member Plugin Developer

    Joined:
    Feb 8, 2014
    Posts:
    1,086
    Plugins:
    17
    That is great. My first version of my plugins usually instead of not doing anything usually generate a lot of errors.
  7. Gamecrafter
    Offline

    Gamecrafter Notable Member Plugin Developer

    Joined:
    Nov 20, 2014
    Posts:
    981
    Plugins:
    9
    Sounds possible to do, I was working on ServerPopups earlier.
  8. Artide
    Offline

    Artide Active Member

    Joined:
    Apr 20, 2015
    Posts:
    214
    Minecraft User:
    Artide5
    namespace TimePopup\Task;
    use pocketmine;

    //Task.php

    public function __construct(Player $player){
    $this->player = $player;
    }

    public function onRun($tick){
    if(!$this->player->isConnected());
    switch($tick){
    case 1:
    $this->player->sendPopup(TextFormat::RED . "Welcome to SCPE!");
    case 1:
    $this->player->sendPopup(TextFormat::GOLD . "elcome to SCPE! W");
    case 2:
    $this->player->sendPopup(TextFormat::YELLOW . "lcome to SCPE! We");
    case 3:
    $this->player->sendPopup(TextFormat::GREEN . "come to SCPE! Wel");
    case 4:
    $this->player->sendPopup(TextFormat::BLUE . "ome to SCPE! Welc");
    case 5:
    $this->player->sendPopup(TextFormat::LIGHT_PURPLE . "me to SCPE! Welco");
    case 6:
    $this->player->sendPopup(TextFormat::RED . "e to SCPE! Welcom");
    case 7:
    $this->player->sendPopup(TextFormat::GOLD . "to SCPE! Welcome");
    case 8:
    $this->player->sendPopup(TextFormat::YELLOW . "o SCPE! Welcome t");
    case 9:
    $this->player->sendPopup(TextFormat::GREEN . " SCPE! Welcome to");
    case 10:
    $this->player->sendPopup(TextFormat::BLUE . "SCPE! Welcome to ");
    case 11:
    $this->player->sendPopup(TextFormat::LIGHT_PURPLE . "CPE! Welcome to S");
    case 12:
    $this->player->sendPopup(TextFormat::RED . "PE! Welcome to SC");
    case 13:
    $this->player->sendPopup(TextFormat::GOLD . "E! Welcome to SCP");
    case 14:
    $this->player->sendPopup(TextFormat::YELLOW . "! Welcome to SCPE");
    case 15:
    $this->player->sendPopup(TextFormat::GREEN . " Welcome to SCPE!");
    case 16:
    $this->player->sendPopup("");
    case 17:
    $this->player->sendPopup("");

    }
    }
    return;
    }
  9. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,325
    Plugins:
    11
    Minecraft User:
    PEMapModder
    PHP doesn't have that thing.
    andre_the_gamer and Tethered_ like this.
  10. BorbingoBoy
    Offline

    BorbingoBoy New Member

    Joined:
    Apr 10, 2015
    Posts:
    5
    Minecraft User:
    BorbingoBoy
    Can you make me a plugin like that with transitions that look like: "Welcome to Minin' Some Fire Creative Server!" ASAP? Thank you!
  11. Samueljh1
    Offline

    Samueljh1 Active Member Plugin Developer

    Joined:
    Jan 9, 2015
    Posts:
    316
    Plugins:
    5
    Minecraft User:
    Samueljh1_
    Lol just use substr to cut off letters. Check it out on my skywars server (sw.samueljh1. Net:19133)

    Even the motd has it lel

Share This Page

Advertisement