3 #################################################################################
4 ## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
5 ## --------------------------------------------------------------------------- ##
6 ## Filename celebration.php ##
7 ## Developed by: Dzoki ##
8 ## License: TravianX Project ##
9 ## Copyright: TravianX (c) 2010-2011. All rights reserved. ##
11 #################################################################################
14 include("GameEngine/Village.php");
16 if(isset($_GET['newdid'])) {
17 $_SESSION['wid'] = $_GET['newdid'];
18 header("Location: ".$_SERVER['PHP_SELF']);
35 $town = $database->getVillageField($village->wid
, 'wref');
36 $vil = $database->getResourceLevel($village->wid
);
37 $woodold = $database->getVillageField($village->wid
, 'wood');
38 $clayold = $database->getVillageField($village->wid
, 'clay');
39 $ironold = $database->getVillageField($village->wid
, 'iron');
40 $cropold = $database->getVillageField($village->wid
, 'crop');
44 $feld = $vil['f'.$id.'t'];
45 $level = $vil['f'.$id];
51 if(6400 < $woodold||
6650 < $clayold ||
5940 < $ironold ||
1340 < $cropold) {
52 $endtime = ($sc[$level]/ SPEED
) +
$time;
58 $database->modifyResource($town,$wood,$clay,$iron,$crop,$mode);
59 $database->addCel($town,$endtime,$type);
65 if(29700 < $woodold ||
33250 < $clayold ||
32000 < $ironold ||
6700 < $cropold) {
67 $endtime = ($gc[$level]/ SPEED
) +
$time;
72 $database->modifyResource($town,$wood,$clay,$iron,$crop,$mode);
73 $database->addCel($town,$endtime,$type);
80 <!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
83 <title
><?php
echo SERVER_NAME ?
></title
>
84 <link REL
="shortcut icon" HREF
="favicon.ico"/>
85 <meta http
-equiv
="cache-control" content
="max-age=0" />
86 <meta http
-equiv
="pragma" content
="no-cache" />
87 <meta http
-equiv
="expires" content
="0" />
88 <meta http
-equiv
="imagetoolbar" content
="no" />
89 <meta http
-equiv
="content-type" content
="text/html; charset=UTF-8" />
90 <meta http
-equiv
="refresh" content
="0; URL=dorf2.php">
91 <script src
="mt-full.js?ebe79" type
="text/javascript"></script
>
92 <script src
="unx.js?ebe79" type
="text/javascript"></script
>
93 <script src
="new.js?ebe79" type
="text/javascript"></script
>
94 <link href
="<?php echo GP_LOCATE; ?>lang/en/lang.css?f4b7c" rel
="stylesheet" type
="text/css" />
95 <link href
="<?php echo GP_LOCATE; ?>lang/en/compact.css?f4b7c" rel
="stylesheet" type
="text/css" />
97 if($session->gpack
== null || GP_ENABLE
== false) {
99 <link href='".GP_LOCATE
."travian.css?e21d2' rel='stylesheet' type='text/css' />
100 <link href='".GP_LOCATE
."lang/en/lang.css?e21d2' rel='stylesheet' type='text/css' />";
103 <link href='".$session->gpack
."travian.css?e21d2' rel='stylesheet' type='text/css' />
104 <link href='".$session->gpack
."lang/en/lang.css?e21d2' rel='stylesheet' type='text/css' />";
107 <script type
="text/javascript">
109 window
.addEvent('domready', start
);