jukebox desc
This commit is contained in:
parent
b3ce20819e
commit
bf942409fb
@ -257,20 +257,29 @@ class MapList implements ManialinkPageAnswerListener, CallbackListener {
|
||||
$mapFrame->setY($y);
|
||||
|
||||
|
||||
//Jukebox Description Label
|
||||
$descriptionLabel = new Label();
|
||||
$frame->add($descriptionLabel);
|
||||
$descriptionLabel->setAlign(Control::LEFT, Control::TOP);
|
||||
$descriptionLabel->setPosition($x + 10, -$this->height / 2 + 5);
|
||||
$descriptionLabel->setSize($this->width * 0.7, 4);
|
||||
$descriptionLabel->setTextSize(2);
|
||||
$descriptionLabel->setVisible(false);
|
||||
|
||||
//Juke-Map-Label
|
||||
if(isset($jukedMaps[$map->uid])){
|
||||
echo "yes";
|
||||
var_dump($jukedMaps[$map->uid]);
|
||||
$jukeLabel = new Label_Text();
|
||||
$mapFrame->add($jukeLabel);
|
||||
$jukeLabel->setX($this->width/2 - 25);
|
||||
$jukeLabel->setX($this->width/2 - 15);
|
||||
$jukeLabel->setAlign(Control::CENTER,Control::CENTER);
|
||||
$jukeLabel->setZ(0.2);
|
||||
$jukeLabel->setTextSize(1.5);
|
||||
$jukeLabel->setText($jukedMaps[$map->uid]);
|
||||
$jukeLabel->setTextColor("FFF");
|
||||
}
|
||||
|
||||
$descriptionLabel->setText("{$map->name} \$zis on Jukebox Position: {$jukedMaps[$map->uid]}");
|
||||
$tooltips->add($jukeLabel, $descriptionLabel);
|
||||
}else{
|
||||
//Juke-Map-Button
|
||||
$jukeQuad = new Quad_Icons128x128_1();
|
||||
$mapFrame->add($jukeQuad);
|
||||
@ -280,16 +289,9 @@ class MapList implements ManialinkPageAnswerListener, CallbackListener {
|
||||
$jukeQuad->setSubStyle($jukeQuad::SUBSTYLE_Load);
|
||||
$jukeQuad->setAction(self::ACTION_JUKE_MAP . "." . $map->uid);
|
||||
|
||||
//Description Label
|
||||
$descriptionLabel = new Label();
|
||||
$frame->add($descriptionLabel);
|
||||
$descriptionLabel->setAlign(Control::LEFT, Control::TOP);
|
||||
$descriptionLabel->setPosition($x + 10, -$this->height / 2 + 5);
|
||||
$descriptionLabel->setSize($this->width * 0.7, 4);
|
||||
$descriptionLabel->setTextSize(2);
|
||||
$descriptionLabel->setVisible(false);
|
||||
$descriptionLabel->setText("Add Map to Jukebox: {$map->name}");
|
||||
$tooltips->add($jukeQuad, $descriptionLabel);
|
||||
}
|
||||
|
||||
if($this->maniaControl->authenticationManager->checkRight($player, AuthenticationManager::AUTH_LEVEL_ADMIN)){ //TODO SET as setting who can add maps
|
||||
//erase map quad
|
||||
|
Loading…
Reference in New Issue
Block a user