game/modules_data/1_panel.php

76 lines
2.7 KiB
PHP
Raw Normal View History

<?php
/**
2022-12-19 20:16:24 +00:00
* @var user $u
* @var array $c from _config.php
* @var array $vt
*/
use Insallah\Db;
if (!defined('GAME') || (int)$u->info['align'] !== 1) {
exit();
2022-06-06 21:30:34 +00:00
}
if ($u->error) {
echo '<b style="color: red">' . $u->error . '</b><br>';
2022-06-06 21:30:34 +00:00
}
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> $item_light
$item_light = [
[5048, 1, 0, 0, 0, 'usefromfile=1|nohaos=1|musor=2|noremont=1|tr_align=1|srok=86400|nosale=1|sudba=1', 1],
];
$vi = [];
$vnr = [0 => '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>', 1 => ' <20><><EFBFBD><EFBFBD><EFBFBD>'];
$seet = '';
foreach ($item_light as $item) {
if (!$item[1]) {
continue;
}
$itm = Db::getRow('select * from items_main where id = ?', [$item[0]]);
if (!$itm['id']) {
continue;
}
$vix = 0;
if ($item[4] === 0) {
$vix = $u->testAction('`uid` = "' . $u->info['id'] . '" AND `time`>=' . strtotime('now 00:00:00') . ' AND `vars` = "dark_itm' . $itm['id'] . '"',
2);
} else {
$vix = $u->testAction('`uid` = "' . $u->info['id'] . '" AND `time`>=' . $vt['timeUse'] . ' AND `vars` = "dark_itm' . $itm['id'] . '" ',
2);
}
$vix = $vix[0];
if ($item[1] - $vix > 0 && $_GET['take_item_light_panel'] == $itm['id']) {
$nitm = $u->addItem($itm['id'], $u->info['id'], $item[5]);
$u->addAction(time(), 'dark_itm' . $itm['id'], '');
echo '<span style="color: red"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> &quot;<b>' . $itm['name'] . '</b>&quot; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>!</span><br><br>';
}
2022-06-06 21:30:34 +00:00
//<2F><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$seet0 = '<img ' . $vix . ' title="' . $itm['name'] . '
(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ' . $vnr[$item[4]] . ': ' . ($item[1] - $vix) . ' <EFBFBD><EFBFBD>.)" src="https://' . $c['img'] . '/i/items/' . $itm['img'] . '"> ';
if ($item[1] - $vix > 0) {
$seet0 = '<a href="main.php?1_panel=1&take_item_light_panel=' . $itm['id'] . '">' . $seet0 . '</a>';
} else {
$seet0 = '<span style="filter: alpha(opacity=20); -moz-opacity: 0.20; opacity: 0.20;">' . $seet0 . '</span>';
}
$seet .= $seet0;
2022-06-06 21:30:34 +00:00
}
?>
<link href="https://img.new-combats.com/css/main.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" type="text/css" href="css/clu0b.css"/>
<link rel="stylesheet" type="text/css" href="css/windows.css"/>
<script>
let elem = document.getElementById('se-pre-con');
elem.parentNode.removeChild(elem);
</script>
<h3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <?= $u->microLogin($u->info['id'], 1) ?></h3>
<div style="text-align: right;">
<input type="button" class="btn" value="<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>" onclick="location='main.php?1_panel=1';">
<input type="button" class="btn" value="<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>" onclick="location='main.php';">
</div>
<div style="text-align: center;">
<div><strong><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:</strong><br/><sup>(<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)</sup></div>
<div><?= $seet ?></div>
</div>