pocketmine\level\Level::stopTime PHP Method

stopTime() public method

Stops the time for the level, will not save the lock state to disk
public stopTime ( )
    public function stopTime()
    {
        $this->stopTime = true;
        $this->sendTime();
    }

Usage Example

Ejemplo n.º 1
-1
 function __construct(Level $Level, BedWars $plugin)
 {
     $this->Level = $Level;
     $this->plugin = $plugin;
     $this->LevelData = (new Config($plugin->getDataFolder() . "levels/" . $Level->getFolderName() . ".yml"))->getAll();
     $this->level_name = $Level->getFolderName();
     $this->PopupInfo = new PopupInfo($this->plugin, $Level, 1);
     $this->PopupInfo->Rows = array();
     foreach ($this->LevelData["teams"] as $name => $team) {
         /*$this->PopupInfo->Rows[$name] = "[".$this->plugin->teamColorName($name)."] = 0";*/
     }
     $this->PopupInfo2 = new PopupInfo($this->plugin, $Level, 0);
     $this->PopupInfo2->PlayersData = array();
     $Level->setAutoSave(false);
     $Level->setTime(6000);
     $Level->stopTime();
     $this->initBlocks();
 }
Level