mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-07-04 03:44:23 +00:00
fix update spieler.php and graphic.tpl + fix edit forum for player without forum access + fix send resouces + more updates for farmlist (still not 100%)
This commit is contained in:
@@ -1742,8 +1742,10 @@ private function loyaltyRegeneration() {
|
||||
if($data['t11'] > 0){
|
||||
if ($isoasis != 0) {
|
||||
if ($database->canConquerOasis($data['from'],$data['to'])) {
|
||||
if($unitssend_def[1] == '0,0,0,0,0,0,0,0,0,0' and $unitssend_def[2] == '0,0,0,0,0,0,0,0,0,0' and $unitssend_def[3] == '0,0,0,0,0,0,0,0,0,0' and $unitssend_def[4] == '0,0,0,0,0,0,0,0,0,0' and $unitssend_def[5] == '0,0,0,0,0,0,0,0,0,0'){
|
||||
$database->conquerOasis($data['from'],$data['to']);
|
||||
$info_chief = $hero_pic.",Your hero has conquered this oasis and gained ".$heroxp." XP";
|
||||
$info_chief = $hero_pic.",Your hero has conquered this oasis";
|
||||
}
|
||||
} else {
|
||||
$OasisInfo = $database->getOasisInfo($data['to']);
|
||||
if ($OasisInfo['conqured'] != 0) {
|
||||
|
||||
@@ -107,7 +107,7 @@ class Market {
|
||||
$timetaken = $generator->procDistanceTime($coor,$village->coor,$session->tribe,0);
|
||||
$reference = $database->sendResource($resource[0],$resource[1],$resource[2],$resource[3],$reqMerc,0);
|
||||
$database->modifyResource($village->wid,$resource[0],$resource[1],$resource[2],$resource[3],0);
|
||||
$database->addMovement(0,$village->wid,$id,$reference,time()+$timetaken);
|
||||
$database->addMovement(0,$village->wid,$id,$reference,time(),time()+$timetaken);
|
||||
$logging->addMarketLog($village->wid,1,array($resource[0],$resource[1],$resource[2],$resource[3],$id));
|
||||
}
|
||||
}
|
||||
@@ -169,8 +169,8 @@ class Market {
|
||||
$mytime = $generator->procDistanceTime($hiscoor,$village->coor,$session->tribe,0);
|
||||
$targettribe = $database->getUserField($database->getVillageField($infoarray['vref'],"owner"),"tribe",0);
|
||||
$histime = $generator->procDistanceTime($village->coor,$hiscoor,$targettribe,0);
|
||||
$database->addMovement(0,$village->wid,$infoarray['vref'],$mysendid,$mytime+time());
|
||||
$database->addMovement(0,$infoarray['vref'],$village->wid,$hissendid,$histime+time());
|
||||
$database->addMovement(0,$village->wid,$infoarray['vref'],$mysendid,time(),$mytime+time());
|
||||
$database->addMovement(0,$infoarray['vref'],$village->wid,$hissendid,time(),$histime+time());
|
||||
$resource = array(1=>0,0,0,0);
|
||||
$resource[$infoarray['wtype']] = $infoarray['wamt'];
|
||||
$database->modifyResource($village->wid,$resource[1],$resource[2],$resource[3],$resource[4],0);
|
||||
|
||||
@@ -76,6 +76,7 @@ if(!isset($_GET['admin'])) {
|
||||
$_GET['admin'] = null;
|
||||
}
|
||||
if($_GET['admin']== "switch_admin"){
|
||||
if($opt['opt5'] == 1){
|
||||
if($database->CheckResultEdit($aid) != 1){
|
||||
$database->CreatResultEdit($aid,1);
|
||||
}else{
|
||||
@@ -86,6 +87,7 @@ if($_GET['admin']== "switch_admin"){
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if($_GET['admin']== "pin"){
|
||||
$database->StickTopic($_GET[idt],1); // stick topic
|
||||
}
|
||||
|
||||
@@ -7,9 +7,10 @@
|
||||
<div id="textmenu">
|
||||
<a href="build.php?id=<?php echo $id; ?>">Overview</a> |
|
||||
<a href="a2b.php">Send troops</a> |
|
||||
<a href="warsim.php">Combat Simulator</a></div> <?php if($session->goldclub==1){ ?>|
|
||||
<a href="warsim.php">Combat Simulator</a> <?php if($session->goldclub==1){ ?>|
|
||||
<a href="build.php?id=<?php echo $id; ?>&t=99">Farmlist</a>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php
|
||||
$units_type = $database->getMovement("34",$village->wid,1);
|
||||
|
||||
|
||||
+18
-52
@@ -1,58 +1,24 @@
|
||||
<div id="build" class="gid16">
|
||||
<div class="build_desc">
|
||||
<a href="#" onClick="return Travian.Game.iPopup(16,4);" class="build_logo">
|
||||
<img class="g16 big white" src="img/x.gif" alt="Camp" title="Camp" /></a>
|
||||
<h1>Camp <span class="level">level <?php echo $village->resarray['f'.$id]; ?></span></h1>
|
||||
<p class="build_desc">Your village troops are gathered in this place. From here you can send them to plunder, raid, or conquer other villages are supported.</p>
|
||||
<?php
|
||||
if(!$session->goldclub) {
|
||||
include "Templates/Build/16.tpl";
|
||||
}else{
|
||||
?>
|
||||
<div id="build" class="gid16"><a href="#" onClick="return Popup(16,4);" class="build_logo">
|
||||
<img class="g16" src="img/x.gif" alt="Rally point" title="Rally point" />
|
||||
</a>
|
||||
<h1>Rally point <span class="level">level <?php echo $village->resarray['f'.$id]; ?></span></h1>
|
||||
<p class="build_desc">Your village's troops meet here. From here you can send them out to conquer, raid or reinforce other villages.</p>
|
||||
|
||||
<?php include("upgrade.tpl"); ?>
|
||||
<div class="contentNavi tabNavi">
|
||||
<div class="container normal">
|
||||
<div class="background-start"> </div>
|
||||
<div class="background-end"> </div>
|
||||
<div class="content"><a href="build.php?id=<?php echo $id; ?>"><span class="tabItem">Rally Point</span></a></div>
|
||||
</div>
|
||||
|
||||
<div class="container normal">
|
||||
<div class="background-start"> </div>
|
||||
<div class="background-end"> </div>
|
||||
<div class="content"><a href="a2b.php"><span class="tabItem">Send Troops</span></a></div>
|
||||
</div>
|
||||
|
||||
<div class="container normal">
|
||||
<div class="background-start"> </div>
|
||||
<div class="background-end"> </div>
|
||||
<div class="content"><a href="warsim.php"><span class="tabItem">Combat Simulator</span></a></div>
|
||||
</div>
|
||||
|
||||
<div class="container active">
|
||||
<div class="background-start"> </div>
|
||||
<div class="background-end"> </div>
|
||||
<div class="content"><a href="build.php?id=39&t=99"><span class="tabItem">Exhibition List </span></a></div>
|
||||
</div>
|
||||
<div id="textmenu">
|
||||
<a href="build.php?id=<?php echo $id; ?>">Overview</a> |
|
||||
<a href="a2b.php">Send troops</a> |
|
||||
<a href="warsim.php">Combat Simulator</a> <?php if($session->goldclub==1){ ?>|
|
||||
<a href="build.php?id=<?php echo $id; ?>&t=99">Farmlist</a>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<div id="raidList">
|
||||
<?php if(!$session->goldclub) { ?>
|
||||
<div class="options">
|
||||
<div id="spaceUsed">
|
||||
<div class="boxes boxesColor gray">
|
||||
<div class="boxes-tl"></div>
|
||||
<div class="boxes-tr"></div>
|
||||
<div class="boxes-tc"></div>
|
||||
<div class="boxes-ml"></div>
|
||||
<div class="boxes-mr"></div>
|
||||
<div class="boxes-mc"></div>
|
||||
<div class="boxes-bl"></div>
|
||||
<div class="boxes-br"></div>
|
||||
<div class="boxes-bc"></div>
|
||||
<div class="boxes-contents">Gold Club is one of our farm list and need to pay another fee to activate it.</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
<a class="arrow" href="plus.php?id=3#goldclub">Gets Gold Club members</a>
|
||||
</div>
|
||||
<?php }else{ include "Templates/goldClub/farmlist.tpl"; } ?>
|
||||
<?php include "Templates/goldClub/farmlist.tpl"; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
@@ -100,5 +100,7 @@ $database->updateUserField($session->uid,gpack,$_POST["custom_url"],1);
|
||||
</tbody>
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}else{
|
||||
header("Location: ".$_SERVER['PHP_SELF']."?uid=".$session->uid);
|
||||
}
|
||||
?>
|
||||
@@ -291,8 +291,9 @@ for($i=$start;$i<=$end;$i++){
|
||||
</div>
|
||||
</div>
|
||||
<?php } }?>
|
||||
</br>
|
||||
<div class="options">
|
||||
<a class="arrow" href="build.php?gid=16&t=99&action=addList">ایجاد لیست جدید</a>
|
||||
<a class="arrow" href="build.php?gid=16&t=99&action=addList">» create new list</a>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
|
||||
@@ -43,6 +43,26 @@ if(isset($_GET['id'])) {
|
||||
$technology->procTechno($_GET);
|
||||
}
|
||||
}
|
||||
if($session->goldclub){
|
||||
if(isset($_GET['t'])==99) {
|
||||
|
||||
if($_GET['action'] == 'addList') {
|
||||
include("Templates/goldClub/farmlist_add.tpl");
|
||||
}
|
||||
if($_GET['action'] == 'showSlot' && $_GET['lid']) {
|
||||
include("Templates/goldClub/farmlist_addraid.tpl");
|
||||
}elseif($_GET['action'] == 'showSlot' && $_GET['eid']) {
|
||||
include("Templates/goldClub/farmlist_editraid.tpl");
|
||||
}
|
||||
if($_GET['action'] == 'deleteList') {
|
||||
$database->delFarmList($_GET['lid'], $session->uid);
|
||||
header("Location: build.php?id=39&t=99");
|
||||
}elseif($_GET['action'] == 'deleteSlot') {
|
||||
$database->delSlotFarm($_GET['eid']);
|
||||
header("Location: build.php?id=39&t=99");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($_POST['a']) == 533374 && isset($_POST['id']) == 39){
|
||||
$units->Settlers($_POST);
|
||||
|
||||
+3
-2
@@ -146,8 +146,9 @@ else if (isset($_GET['s'])) {
|
||||
if($_GET['s'] == 4) {
|
||||
include("Templates/Profile/graphic.tpl");
|
||||
}
|
||||
}else{
|
||||
header("Location: ".$_SERVER['PHP_SELF']."?uid=".$session->uid);
|
||||
if($_GET['s'] > 4) {
|
||||
header("Location: ".$_SERVER['PHP_SELF']."?uid=".$session->uid);
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user