本文整理匯總了PHP中Shadowfunc::displayETA方法的典型用法代碼示例。如果您正苦於以下問題:PHP Shadowfunc::displayETA方法的具體用法?PHP Shadowfunc::displayETA怎麽用?PHP Shadowfunc::displayETA使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Shadowfunc
的用法示例。
在下文中一共展示了Shadowfunc::displayETA方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: onElevate
private function onElevate(SR_Player $player, $n = 0, $btn = 'up')
{
if (false === ($floor = $this->getElevatorFloorN($n))) {
$player->message('This floor does not exist.');
return false;
}
if (false === $this->hasElevatorPermN($player, $n)) {
$player->msg('1135');
// $player->message('Somehow the elevator is blocking this floor for you.');
return false;
}
if ($floor->getName() === $this->getName()) {
$player->msg('1136');
// $player->message('You push the button but you are on the very same floor already.');
return false;
}
$eta = $this->getElevatorTime();
$player->getParty()->ntice('5177', array($btn, Shadowfunc::displayETA($eta)));
if (false === $this->teleportInside($player, $floor->getName(), $eta)) {
$player->message('Error!');
return false;
}
// $message = 'Your party pushes the '.$btn.' button and the elevator starts to move. '.Shadowfunc::displayETA($eta);
// return $player->getParty()->notice($message);
return true;
}