game/modules_data/location/cp1.php
2022-07-01 12:45:43 +00:00

280 lines
16 KiB
PHP

<?
if(!defined('GAME'))
{
die();
}
require_once('/home/newcom1/public_html/_incl_data/__config.php');
require_once('/home/newcom1/public_html/_incl_data/class/__db_connect.php');
if($u->room['file']=='cp1')
{
if(date("H")>=8 && date("H")<=23) {
$now = 'day';
$tattack = '<a style="color:#D8D8D8" style="cursor:pointer" onclick="top.useMagic(\'Íàïàäåíèå íà ïåðñîíàæà\',\'night_atack\',\'pal_button8.gif\',1,\'main.php?nightatack=1\');">Íàïàñòü íà èãðîêà</a> &nbsp; ';
}else{
$now = 'night';
$tattack = '';
}
?>
<script>
<?
if(date("H")<23 || date("H")>=6)
{
?>
function AtackNoWindow()
{
var dt = document.getElementById('atackDiv');
if(dt.style.display=='none')
{
dt.style.display = '';
}else{
dt.style.display = 'none';
}
}
<?
}
?>
</script>
<?
function timeOut($ttm) {
$out = '';
$time_still = $ttm;
$tmp = floor($time_still/2592000);
$id=0;
if ($tmp > 0)
{
$id++;
if ($id<3) {$out .= $tmp." ìåñ. ";}
$time_still = $time_still-$tmp*2592000;
}
/*
$tmp = floor($time_still/604800);
if ($tmp > 0)
{
$id++;
if ($id<3) {$out .= $tmp." íåä. ";}
$time_still = $time_still-$tmp*604800;
}
*/
$tmp = floor($time_still/86400);
if ($tmp > 0)
{
$id++;
if ($id<3) {$out .= $tmp." äí. ";}
$time_still = $time_still-$tmp*86400;
}
$tmp = floor($time_still/3600);
if ($tmp > 0)
{
$id++;
if ($id<3) {$out .= $tmp." ÷. ";}
$time_still = $time_still-$tmp*3600;
}
$tmp = floor($time_still/60);
if ($tmp > 0)
{
$id++;
if ($id<3) {$out .= $tmp." ìèí. ";}
}
if($out=='')
{
if($time_still<0)
{
$time_still = 0;
}
$out = $time_still.' ñåê.';
}
return $out;
}?>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="250" valign="top">
<? $usee = $u->getInfoPers($u->info['id'],0); if($usee!=false){ echo $usee[0]; }else{ echo 'information is lost.'; } ?>
</td>
<td width="230" valign="top" style="padding-top:19px;"><? require_once('modules_data/stats_loc.php'); ?></td>
<td width="230" valign="top" style="padding-top:19px;">
<span style="font-size:12px;">
<!--<span style="font-size:14px;color:red;">
<b > Ìîíñòðû ëîêàöèè:</b> </br>
</span>-->
<?/*
$wp = mysql_query('SELECT * FROM `users` WHERE `no_ip` = "trupojor" LIMIT 100 ');
$wp = mysql_query('SELECT * FROM `users` WHERE `no_ip` = "trupojor" ORDER BY `users`.`level` ASC ');
while( $pl = mysql_fetch_array($wp) )
{
$btc = mysql_fetch_array(mysql_query('SELECT * FROM `stats` WHERE `id` = "'.$pl['id'].'" LIMIT 1'));
if( isset($btc['id']) ) {
echo "<br /><b>".$pl['login']." </b><br />";
//echo "<a href='/inf.php?".$pl['id']." target='_blank'><img border='0' alt='info' src='https://img.new-combats.com/i/inf_capitalcity.gif'></a><br />"; //
if (timeOut($btc['res_x']-time()) =='0 ñåê.'){
echo "<span style='color:red;'>Ìîíñòð àòàêóåò çàùèòè ãîðîä!</span>";
}
else{
if ($btc['res_x']-time()<20*60)
{
echo "Àòàêà ÷åðåç: <span style='color:#ce4135;'><b>".timeOut($btc['res_x']-time())."</b></span>";
}elseif ($btc['res_x']-time()<45*60)
{
echo "Àòàêà: <span style='color:#ce6d35;'><b>Î÷åíü ñêîðî</b></span> ";
}elseif ($btc['res_x']-time()<1.2*60*60)
{
echo "Àòàêà: <span style='color:#cebe35;'><b>Ñêîðî</b></span> ";
}elseif ($btc['res_x']-time()<2.2*60*60)
{
echo "Àòàêà: <span style='color:#a2ce35;'><b>Íå ñêîðî</b></span> ";
}elseif ($btc['res_x']-time()<3*60*60)
{
echo "Àòàêà: <span style='color:#4cce35;'><b>Ñîâñåì íå ñêîðî</b></span> ";
}else
{echo "Àòàêà: <b>Íåâîçìîæíà!</b> ";}
//echo "Äî àòàêè îñòàëîñü: ".timeOut($btc['res_x']-time())."";
}
echo "<br />";
//echo '<a href="/inf.php?'.$pl['id'].'" target="_blank">'.$pl['login'].' ['.$pl['level'].']</a> ïîÿâèòñÿ ÷åðåç '.timeOut($btc['res_x']-time()).''.date('d.m.Y H:i',$btc['res_x']).'<br />';
}
}
*/?>
</span>
</td>
<td valign="top"><div align="right">
<table border="0" cellpadding="0" cellspacing="0">
<tr align="right" valign="top">
<td>
<? if($re!=''){ echo '<font color="red"><b>'.$re.'</b></font>'; } ?>
<table width="500" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<div style="position:relative; cursor: pointer;" id="ione">
<img src="https://img.new-combats.com/city/capitalcity/<? echo $now; ?>/city_capres1.jpg" alt="" name="img_ione" width="580" height="312" border="1" id="img_ione"/>
<div id="buttons_on_image" style="cursor:pointer; font-weight:bold; color:#D8D8D8; font-size:10px;">
<? echo $tattack; ?>
&nbsp;
<span onclick="window.open('https://new-combats.com/forum', 'location=yes,menubar=yes,status=yes,resizable=yes,toolbar=yes,scrollbars=yes,scrollbars=yes')">Ôîðóì ïðîåêòà</span> &nbsp;
</div>
<script language="javascript" type="text/javascript">
<!--
if(document.getElementById('ione'))
{
document.getElementById('ione').appendChild(document.getElementById('buttons_on_image'));
document.getElementById('buttons_on_image').style.position = 'absolute';
document.getElementById('buttons_on_image').style.bottom = '8px';
document.getElementById('buttons_on_image').style.right = '23px';
}else{
document.getElementById('buttons_on_image').style.display = 'none';
}
-->
</script>
<div style="position:absolute; left:150px; top:40px; width:236px; height:157px; z-index:90;"><img <? thisInfRm('1.180.0.3'); ?> src="https://img.new-combats.com/i/images/300x225/capital/2klub.gif" width="236" height="157" class="aFilter" /></div>
<div style="position: absolute; left: 459px; top: 155px; width: 79px; height: 88px; z-index: 91;"><img <? thisInfRm('1.180.0.371'); ?> src="https://img.new-combats.com/city/capitalcity/day/loto.gif" class="aFilter" width="86" height="63" /></div>
<div style="position: absolute; left: 190px; top: 157px; width: 73px; height: 47px; z-index: 91;"><img <? thisInfRm('1.180.0.10'); ?> src="https://img.new-combats.com/i/images/300x225/capital/2shop.gif" width="73" height="47" class="aFilter" /></div>
<div style="position: absolute; left: 32px; top: 177px; width: 48px; height: 36px; z-index: 91;"><img <? thisInfRm('1.180.0.272'); ?> src="https://img.new-combats.com/city/capitalcity/day/2comission.gif" width="48" height="36" class="aFilter" /></div>
<div style="position: absolute; left: 270px; top: 158px; width: 71px; height: 45px; z-index: 91;"><img <? thisInfRm('1.180.0.210'); ?> src="https://img.new-combats.com/i/images/300x225/capital/2remont.gif" width="71" height="45" class="aFilter" /></div>
<!-- <div style="position: absolute; left: 371px; top: 173px; width: 60px; height: 41px; z-index: 93;"><img <? thisInfRm('1.180.0.404'); ?> src="https://img.new-combats.com/city/priz2shop.gif" width="60" class="aFilter" height="40" /></div> -->
<!-- <div style="position: absolute; left: 167px; top: 147px; width: 27px; height: 55px; z-index: 93;"><img <? thisInfRm('1.180.0.x'); ?> src="https://img.new-combats.com/city/capitalcity/day/2pm.gif" class="aFilter" width="27" height="55" /></div> -->
<?
$btc = mysql_fetch_array(mysql_query('SELECT * FROM `stats` WHERE `id` = "89489" LIMIT 1'));
if( isset($btc['id']) ) {
if (timeOut($btc['res_x']-time()) =='0 ñåê.'){
?>
<div style="position:absolute; left:100px; top:175px; width:27px; height:55px; z-index:99;"><img onclick="location.href='main.php?atak_user=89489'" src="https://img.new-combats.com/i/images/300x225/capital/jora1.png" width="120" height="135" title="Íàïàñòü íà Ñëàáîãî Òðóïîæîðà" /></div>
<?}}?>
<?
$btc = mysql_fetch_array(mysql_query('SELECT * FROM `stats` WHERE `id` = "903093" LIMIT 1'));
if( isset($btc['id']) ) {
if (timeOut($btc['res_x']-time()) =='0 ñåê.'){
?>
<div style="position:absolute; left:300px; top:168px; width:27px; height:55px; z-index:99;"><img onclick="location.href='main.php?atak_user=903093'" src="https://img.new-combats.com/i/images/300x225/capital/jora2.png" width="120" height="150" title="Íàïàñòü íà Ñèëüíîãî Òðóïîæîðà" /></div>
<?}}?>
<? if( date('d.m') == '31.10' || (date('m') == 11 && date('d') < 7) ) { /* Õýëëîóèí */ ?>
<div style="position: absolute; left: 219px; top: 171px; width: 32px; height: 43px; z-index: 91;"><img onclick="location.href='main.php?talk=5'" title="Äèàëîã ñ Òûêâîãîëîâûì" src="https://img.new-combats.com/loca/cp11/sun_pmd.gif" width="32" height="43" class="aFilter" /></div>
<? }
if(date('m') == 12 || date('m') == 1 ){/*¨ëêà*/ ?>
<div style="position: absolute; left: 212px; top: 133px; width: 32px; height: 43px; z-index: 91;"><img <? thisInfRm('1.180.0.208'); ?> src="https://img.new-combats.com/newyear2014.png" width="60" height="90" title="" class="aFilter" /></div>
<? } ?>
<div style="position:absolute; left:360px; top:142px; width:111px; height:72px; z-index:92;"><img <? thisInfRm('1.180.0.226'); ?> src="https://img.new-combats.com/city/capitalcity/day/2pochta.gif" width="111" height="72" class="aFilter" /></div>
<div style="position:absolute; left:73px; top:150px; width:92px; height:62px; z-index:92;"><img <? thisInfRm('1.180.0.14'); ?> onclick="alert('Íå ðàáîòàåò. Íàõîäèòñÿ íà ðåêîíñòðóêöèè.')" onMouseOver="this.className='aFilterhover';" onMouseOut="this.className='aFilter';" src="https://img.new-combats.com/city/capitalcity/day/2vokzal.gif" width="92" height="62" class="aFilter" /></div>
<!-- <div style="position:absolute; left:166px; top:149px; width:27px; height:55px; z-index:99;"><img src="https://img.new-combats.com/i/images/300x225/capital/2pm.gif" width="27" height="55" title="Ïàìÿòíèê Ìèðîçäàòåëþ" /></div> -->
<!-- <div style="position:absolute; left:100px; top:146px; width:75px; height:90px; z-index:99;"><img src="https://img.new-combats.com/i/images/300x225/capital/stellav.gif" width="75" height="90" title="Ñòåëà âûáîðà" class="aFilter" /></div> -->
<div style="position:absolute; left:535px; top:225px; width:30px; height:54px; z-index:94;"><img <? thisInfRm('1.180.0.11'); ?> src="https://img.new-combats.com/i/images/300x225/capital/2strelka.gif" width="30" height="54" class="aFilter" /></div>
<div style="position:absolute; left:14px; top:225px; width:30px; height:54px; z-index:910;"><img src="https://img.new-combats.com/i/images/300x225/capital/3strelka.gif" width="30" height="53" <? thisInfRm('1.180.0.323'); ?> class="aFilter" /></div>
<div id="snow"></div>
<? echo $goline; ?>
</div>
</td>
</tr>
</table>
<?
if(date("H")<6 || date("H")>=22)
{
?>
<div align="center" id="atackDiv" style="display:none;">
<form method="post" action="main.php">
<table width="300" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><div style="width:300px; padding:3px; margin:7px; background-color:#CCCCCC; border:1px solid #575757;"> Ââåäèòå ëîãèí æåðòâû:<br />
<input name="atack" type="text" id="atack" size="35" maxlength="30" />
<input type="submit" name="button" id="button" class="btn" value="OK" />
</div></td>
</tr>
</table>
</form>
</div>
<?
}
?>
<!-- -->
<div style="width:580px; text-align:left; background-color:#D3D3D3;">
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" class="menutop" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.3&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.3',1); ?>">Áîéöîâñêèé Êëóá</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.323&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.323',1); ?>">Ïàðêîâàÿ Óëèöà</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.10&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.10',1); ?>">Ìàãàçèí</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.210&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.210',1); ?>">Ðåìîíòíàÿ Ìàñòåðñêàÿ</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.272&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.272',1); ?>">Êîìèññèîííûé Ìàãàçèí</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.11&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.11',1); ?>">Ñòðàøèëêèíà Óëèöà</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.14&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.14',1); ?>">Âîêçàë</a></span>
<span style="white-space:nowrap; padding-left:3px; padding-right:3px; height:10px"><img src="https://img.new-combats.com/i/move/links.gif" width="9" height="7" />&nbsp;<a href="#" id="greyText" class="menutop" onclick="location='main.php?loc=1.180.0.226&rnd=<? echo $code; ?>';" title="<? thisInfRm('1.180.0.226',1); ?>">Ïî÷òà</a></span>
</div>
<!-- -->
<div style="display:none; height:0px " id="moveto"></div>
</td>
<td>
<!-- <br /><span class="menutop"><nobr>Êîìíàòà äëÿ íîâè÷êîâ</nobr></span>-->
</td>
</tr>
</table>
<small>
<HR>
<strong>Âíèìàíèå!Ñìåíèòå ïàðîëü íà óíèêàëüíûé,êîòîðûé íå èñïîëüçîâàëñÿ ðàíåå â ïîäîáíûõ ïðîåêòàõ,ýòî îáåçîïàñèò âàøåãî ïåðñîíàæà îò âçëîìà.<BR>
<em>Àäìèíèñòðàöèÿ.</strong> </em></small> <BR>
<? echo $rowonmax; ?><BR>
</div></td>
</tr>
</table>
<?
}
?>