battles/classes/ShopItem.php
Igor Barkov [iwork] 65a39f42af make class greater
2019-01-14 17:49:31 +02:00

32 lines
929 B
PHP

<?php
class ShopItem extends Item
{
public $count;
public $razdel;
public $ecost;
public $zeton;
public $onlyone;
public $shshop;
public function printInfo()
{
parent::printBaseInfo();
echo "<br>Цена" . $this->wrap($this->cost) . " пымпочек";
if ($this->count > 0) echo "<br><small>(Осталось: {$this->count} штук)</small>";
parent::printRequirements();
parent::printBonuses();
parent::printMagic();
}
/**
* Для кнопок управления под картинкой прелмета в зависимости от ситуации.
*/
public function printControls()
{
echo <<<BTN
<p><input type="button" style="background: darkgrey; border: 1px solid grey; border-radius: 2px;" value="Купить"
onclick="location='/admin.php'">
BTN;
}
}