From 2f9d134ec9cf941f365ca0b011649295668caae3 Mon Sep 17 00:00:00 2001 From: Martin Ambrus Date: Wed, 22 Nov 2017 15:32:31 +0100 Subject: [PATCH] feat: indicator for fields under construction Also, all line separators are now Linux-style :-P Closes #321 --- Admin/Templates/Newmessage.tpl | 2 +- Admin/Templates/editVillage.tpl | 2 +- Admin/Templates/message.tpl | 2 +- Admin/Templates/msg.tpl | 2 +- Admin/Templates/report.tpl | 4 +- Admin/Templates/village.tpl | 14 ++-- Templates/Manual/433.tpl | 2 +- Templates/field.tpl | 18 ++++- a2b.php | 12 +-- a2b2.php | 2 +- activate.php | 2 +- allianz.php | 2 +- anmelden.php | 2 +- banned.php | 2 +- berichte.php | 2 +- build.php | 4 +- create_account.php | 2 +- crop_finder.php | 2 +- dorf1.php | 2 +- dorf2.php | 4 +- dorf3.php | 2 +- gpack/travian_default/img/g/s/glvlm.gif | Bin 1048 -> 1491 bytes .../img/g/s/lvl11_20_active.gif | Bin 0 -> 1498 bytes .../img/g/s/lvl1_10_active.gif | Bin 0 -> 1197 bytes .../img/g/s/lvl21_30_active.gif | Bin 0 -> 930 bytes gpack/travian_default/lang/en/b/zurueck.html | 14 ++-- gpack/travian_default/lang/en/compact.css | 33 +++++--- gpack/travian_default/lang/en/lang.css | 73 +++++++++++++++++- gpack/travian_t4/lang/en/b/zurueck.html | 14 ++-- gpack/travian_t4/lang/en/compact.css | 31 +++++--- img/admin/b/zurueck.html | 14 ++-- install/index.php | 2 +- karte.php | 2 +- karte2.php | 2 +- login.php | 2 +- logout.php | 2 +- manual.php | 2 +- massmessage.php | 6 +- nachrichten.php | 2 +- notification/index.php | 2 +- packages.php | 2 +- password.php | 2 +- plus.php | 12 +-- plus1.php | 14 ++-- rules.php | 2 +- spieler.php | 2 +- statistiken.php | 14 ++-- support.php | 2 +- sysmsg.php | 2 +- uncrypt.js | 2 +- version.php | 2 +- warsim.php | 10 +-- winner.php | 2 +- 53 files changed, 227 insertions(+), 128 deletions(-) create mode 100644 gpack/travian_default/img/g/s/lvl11_20_active.gif create mode 100644 gpack/travian_default/img/g/s/lvl1_10_active.gif create mode 100644 gpack/travian_default/img/g/s/lvl21_30_active.gif diff --git a/Admin/Templates/Newmessage.tpl b/Admin/Templates/Newmessage.tpl index 6dfc45a3..10c51082 100644 --- a/Admin/Templates/Newmessage.tpl +++ b/Admin/Templates/Newmessage.tpl @@ -18,7 +18,7 @@ if(isset($id)) $varray = $database->getProfileVillages($id); $varmedal = $database->getProfileMedal($id); ?> - + - + diff --git a/Admin/Templates/msg.tpl b/Admin/Templates/msg.tpl index 55a40342..7c01a081 100644 --- a/Admin/Templates/msg.tpl +++ b/Admin/Templates/msg.tpl @@ -13,7 +13,7 @@ $msg = $database->getMessage($_GET['nid'],3); if($msg) { ?> - + diff --git a/Admin/Templates/report.tpl b/Admin/Templates/report.tpl index e408217e..7186ee69 100644 --- a/Admin/Templates/report.tpl +++ b/Admin/Templates/report.tpl @@ -22,7 +22,7 @@ if($rep1) //$att = $database->getUserArray($rep1['uid'],1); ?> - +

Under Construction

@@ -36,7 +36,7 @@ if($rep1) if($rep) { ?> - + diff --git a/Admin/Templates/village.tpl b/Admin/Templates/village.tpl index 08f7f2ad..178c03fa 100644 --- a/Admin/Templates/village.tpl +++ b/Admin/Templates/village.tpl @@ -20,7 +20,7 @@ if(isset($id)) $type = $database->getVillageType($village['wref']); $fdata = $database->getResourceLevel($village['wref']); $units = $database->getUnit($village['wref']); - $abtech = $database->getABTech($id); // Armory/blacksmith level + $abtech = $database->getABTech($id); // Armory/blacksmith level if($type == 1){ $typ = array(3,3,3,9); } elseif($type == 2){ $typ = array(3,4,5,6); } elseif($type == 3){ $typ = array(4,4,4,6); } @@ -40,7 +40,7 @@ if(isset($id)) if(count($result) >0) { foreach($result as $row) - { + { $type = $row['type']; if($type==1) { $type = ' + 25%'; $wood+=1;} elseif($type==2) { $type = ' + 25%'; $wood+=1;} @@ -54,13 +54,13 @@ if(isset($id)) elseif($type==10){ $type = ' + 25%'; $crop+=1;} elseif($type==11){ $type = ' + 25%'; $crop+=1;} elseif($type==12){ $type = ' + 50%'; $crop+=2;} - } + } } $ocounter = array($wood,$clay,$iron,$crop); $production=$admin->calculateProduction($id,$user['id'],$user['b1'],$user['b2'],$user['b3'],$user['b4'],$fdata, $ocounter, $village['pop']); $refreshiconfrm = "../img/admin/refresh.png"; $refreshicon = ""; - + class MyGenerator { public function getMapCheck($wref) @@ -69,14 +69,14 @@ if(isset($id)) } }; $generator = new MyGenerator; - + if($village and $user) { include("search2.tpl"); ?> - +
@@ -249,7 +249,7 @@ if(isset($id)) "; - } + } } elseif($result ==0) { diff --git a/Templates/Manual/433.tpl b/Templates/Manual/433.tpl index 8b29bfbc..9143c221 100644 --- a/Templates/Manual/433.tpl +++ b/Templates/Manual/433.tpl @@ -1,6 +1,6 @@

Brewery

BreweryTasty mead is brewed in the brewery and later quaffed by the soldiers during the celebrations.

-These drinks make your soldiers braver and stronger in battles (1% per level). Unfortunately the chiefs power of persuasion is decreased and catapults can only do random hits. +These drinks make your soldiers braver and stronger in battles (1% per level). Unfortunately the chiefs� power of persuasion is decreased and catapults can only do random hits.

It can only be built by Teutons and only in their capital. It affects the whole empire.

Costs and construction time for level 1:
Lumber1460 | Clay930 | Iron1250 | Crop1740 | Crop consumption6 | duration2:13:20

Prerequisites
Granary Level 20, Rally Point Level 10

diff --git a/Templates/field.tpl b/Templates/field.tpl index 551dce63..45dedbde 100644 --- a/Templates/field.tpl +++ b/Templates/field.tpl @@ -1,4 +1,4 @@ -"101,33,28","165,32,28","224,46,28","46,63,28","138,74,28" $arrayVillage = $village->resarray; ?> -procResType($arrayVillage['f'.$i.'t'])." Level ".$arrayVillage['f'.$i]."\"/>\r\n"; } ?> @@ -23,7 +23,17 @@ for($i=1;$i<=18;$i++) {echo "
-getJobs($village->wid); +$activeFields = []; +if (count($jobs)) { + foreach ($jobs as $job) { + if ( $job['type'] <= 4 ) { + $activeFields[ $job['field'] ] = true; + } + } +} + for($i=1;$i<=18;$i++) { if($arrayVillage['f'.$i.'t'] != 0) { $text = ""; @@ -33,7 +43,7 @@ for($i=1;$i<=18;$i++) { case 3:$text = "Iron Mine Level";break; case 4:$text = "Cropland Level";break; } - echo "\"$text"; + echo "\"$text"; } } ?> diff --git a/a2b.php b/a2b.php index 9a833b81..a43d5638 100644 --- a/a2b.php +++ b/a2b.php @@ -106,7 +106,7 @@ echo GP_LOCATE; -?>lang/en/compact.css?f4b7g" rel="stylesheet" type="text/css" /> +?>lang/en/compact.css?f4b7h" rel="stylesheet" type="text/css" /> gpack == null || GP_ENABLE == false) { @@ -180,10 +180,10 @@ $p_ander = $database->getCoor($prisoner['from']); $p_to = array('x'=>$p_ander['x'], 'y'=>$p_ander['y']); $p_tribe = $database->getUserField($p_owner,"tribe",0); - + $p_speeds = array(); - - //find slowest unit. + + //find slowest unit. for($i=1;$i<=10;$i++){ if ($prisoner['t'.$i]){ if($prisoner['t'.$i] != '' && $prisoner['t'.$i] > 0){ @@ -193,7 +193,7 @@ } } } - + if ($prisoner['t11']>0){ $p_qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $p_owner." AND dead = 0"; $p_resulth = mysqli_query($GLOBALS['link'],$p_qh); @@ -201,7 +201,7 @@ $p_hero_unit=$p_hero_f['unit']; $p_speeds[] = $GLOBALS['u'.$p_hero_unit]['speed']; } - + $p_artefact = count($database->getOwnUniqueArtefactInfo2($p_owner,2,3,0)); $p_artefact1 = count($database->getOwnUniqueArtefactInfo2($prisoner['from'],2,1,1)); $p_artefact2 = count($database->getOwnUniqueArtefactInfo2($p_owner,2,2,0)); diff --git a/a2b2.php b/a2b2.php index 4f4da176..019be444 100644 --- a/a2b2.php +++ b/a2b2.php @@ -43,7 +43,7 @@ - + gpack == null || GP_ENABLE == false) { echo " diff --git a/activate.php b/activate.php index 0e0c5954..70780131 100644 --- a/activate.php +++ b/activate.php @@ -29,7 +29,7 @@ - + diff --git a/allianz.php b/allianz.php index d00ba1fa..803ade0f 100644 --- a/allianz.php +++ b/allianz.php @@ -120,7 +120,7 @@ echo GP_LOCATE; -?>lang/en/compact.css?f4b7g" rel="stylesheet" type="text/css" /> +?>lang/en/compact.css?f4b7h" rel="stylesheet" type="text/css" /> gpack == null || GP_ENABLE == false) { diff --git a/anmelden.php b/anmelden.php index 8d672ac1..1b714ff4 100644 --- a/anmelden.php +++ b/anmelden.php @@ -35,7 +35,7 @@ - + diff --git a/banned.php b/banned.php index 7ec31782..192f3ccc 100644 --- a/banned.php +++ b/banned.php @@ -31,7 +31,7 @@ - + gpack == null || GP_ENABLE == false) { diff --git a/berichte.php b/berichte.php index 46fcf6a5..855c0b7c 100644 --- a/berichte.php +++ b/berichte.php @@ -50,7 +50,7 @@ - + gpack == null || GP_ENABLE == false) { echo " diff --git a/build.php b/build.php index 29e19289..59bc0b9a 100644 --- a/build.php +++ b/build.php @@ -332,7 +332,7 @@ - + gpack == null || GP_ENABLE == false) { echo " @@ -402,7 +402,7 @@ $building->finishAll("build.php?gid=".$_GET['id']."&ty=".$_GET['ty']); exit; } - } + } } }else{ header("Location: ".$_SERVER['PHP_SELF']."?id=39"); diff --git a/create_account.php b/create_account.php index 598a30e9..a4879b3e 100644 --- a/create_account.php +++ b/create_account.php @@ -61,7 +61,7 @@ - + gpack == null || GP_ENABLE == false) { diff --git a/crop_finder.php b/crop_finder.php index e3a4fbc0..a755e077 100644 --- a/crop_finder.php +++ b/crop_finder.php @@ -58,7 +58,7 @@ echo GP_LOCATE; -?>lang/en/compact.css?f4b7g" rel="stylesheet" type="text/css" /> +?>lang/en/compact.css?f4b7h" rel="stylesheet" type="text/css" /> gpack == null || GP_ENABLE == false) { diff --git a/dorf1.php b/dorf1.php index c292b8a3..edf13c5c 100644 --- a/dorf1.php +++ b/dorf1.php @@ -41,7 +41,7 @@ - + gpack == null || GP_ENABLE == false) { diff --git a/dorf2.php b/dorf2.php index 99f9d3df..eac1fdff 100644 --- a/dorf2.php +++ b/dorf2.php @@ -18,7 +18,7 @@ if(isset($_GET['newdid'])) { $_SESSION['wid'] = $_GET['newdid']; - $database->query("UPDATE ".TB_PREFIX."users SET village_select=".$database->escape((int) $_GET['newdid'])." WHERE id=".$session->uid); + $database->query("UPDATE ".TB_PREFIX."users SET village_select=".$database->escape((int) $_GET['newdid'])." WHERE id=".$session->uid); header("Location: ".$_SERVER['PHP_SELF']); exit; }else{ @@ -42,7 +42,7 @@ - + gpack == null || GP_ENABLE == false) { echo " diff --git a/dorf3.php b/dorf3.php index f84b3d44..40a7b781 100644 --- a/dorf3.php +++ b/dorf3.php @@ -45,7 +45,7 @@ - + gpack == null || GP_ENABLE == false) { echo " diff --git a/gpack/travian_default/img/g/s/glvlm.gif b/gpack/travian_default/img/g/s/glvlm.gif index 6dec584226b06bc246ed6e3738262365945541cc..e8ef604d237d913687a33731c96f81d331360840 100644 GIT binary patch literal 1491 zcmW;HYgChU9KiAao?Y1XY;)kC34+h&7!Pd4E7&y($^g_{ zg%<`vbqUhHg|~izjPGH42p0SdFOC8A8|ZI<={A^eLH-}G|@Z@Wl{sE>(;86e``r&~erhIUJ0H*q3Dgb}^Anb$5ui*D{aN`U3?HpV?2g9cz zcp5IB0`F-6K>sIs#GoPcB2xaR|DF&Fs1`%XD!wUjBXWIg+R`Hj3kR#UZOcpU52hVI zp-@h8cP$+l__4UBy6F|wgN=*Uo^3Rn#H}Oso#lBIxhu)#sfl>@T1WlbSLE6FT5`Tv zil^V$Z@ywaY{NZ|D3OGv(w$ZnR9a z*)cw(<3~I(Oq!iE9fsSMgd9TCHGHO27*^>9FVMLKD|CjCm&S}6yKv1VW(MA6$zsif zdcx1Io6mm!rN?HxU)sj~_>^QiE6F2+k{$R4^RKEXcaX0?uR z)r~SLZ2dcI*Qr`YTuY6`s0|1hj8;!(IEyaoAd7Yw!rDu}o{lxN%rl|8dP(Yv@KS@% z&yC}vZcj}`0P`DSWM>Xb^XLhB>1#h4uJ5@MotR-R@#(jH$2T46H<*x*uO}BJ1yN!p zFB%ixQu(!dyC9{|xR|KL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nhK9|IGmb@sN_Jv$CQB9r^qC#Q*%n{`tcH{>T6S z%l-JlEC2ui0IC2C000L6z@Jdq01SV{+Qpj{deX8lNdVKgET0m2Hh4QB2 zVc{xOt{RQsyGEx2R?4(c4ApMOe^6OUWkXjzQ#=g;5MYXoV1y6>U_B%T3jraKh7kc$ zJq!va2tH>=J`e;Srw<<)44h;m9uGVZEFLH*9s_M;o>Bz`0Sg&FzeJt@00=kF9*oJU zls^Ch1{?%Ngq}PqmKhuvrl>3?CgeXp6($N0fImAD85;-<^Y!*vA=S`gLB*FD19mu3km4X89yY*$(ZYZP3@u<- zXaND_g98#bU}%80h1#M&c=Slop@j=3FiQAH0AYiOCUObXjRECnj|2)p@Q@O?u7w_F zd=PN^Q3wwJf?Lq=0pI`#77{oQvKGKGlmIPABpA`5f|1LaEi~Xk8$bgK767!tEYyXV ztUnSE*g(QjkJ2qHK&h!C0fr3`5IqRd!bAcI23mx0ph1EJ3otyDzz!<3 z5I_^Iq!5b_DUj6yIaq!x{yV08(6BCg{ZkG1wCi z4-)w2g#|JQ(87b3Nx%VxKA^C{NG)7Yjt~Wu2?Y%noKV64j0s* zMY>SDn}81kU|i9}DkLxgZl$F#W-1*xAV4ZDV2C7+W4d}C!m=*x<_j*^pxPINOx%Mz z02P2JDjQRP+YB4fK){&mJnO7i%z$7(%TQc^=K~<*D+JB60YHLZvl=q74<{^;fEacU zEguFGaO&xU4uPP7521Ykf(PCyPy*Zqw~%G%SrW3qKOAjtU;5P_%Y!3bzj7D5={0?Ysa2N;+G3=!ghy755(fTE5gG~j}9n2QBgkPJgy z5C9L@!2(NQgZz9Dfd$}!35fj%S zfDwp_iCEOa8V+E^c=*8w9~i+pvWN#fWYG&%9OD#yKmswrO^QE=BDw(dyC47nJL{}t AD*ylh literal 0 HcmV?d00001 diff --git a/gpack/travian_default/img/g/s/lvl1_10_active.gif b/gpack/travian_default/img/g/s/lvl1_10_active.gif new file mode 100644 index 0000000000000000000000000000000000000000..79cab4aa4f5e10c9ab4a8fde471ba13a2749a490 GIT binary patch literal 1197 zcmV;e1XBA)Nk%w1VX6QO0M!5h|FXLOue<-Kz5k@Y|DeMEl*s>)%J>72`VO1>7N!4( z(fuE@|AN*2B)b28*#9TM|9#p2Fv|aV+y8am|99R0apM0v*#B6>i=oz z|4ixsTkQW|>;F^j|5xt+{K^0P%K!Y#|NPDW`^W$M(Et3@|NPqj`o{nG#Q*oi|MbEC z^~3-5#Q*fd|MbKE@WKD=zyIgG|J=O)*SG)Fw*S$%|ID`k$hiN+w*SDk|Ns9000000 z00000A^8LW002AyEC2ui0IC2C000L6z?X0+Oo@m{qKd>+C6h~1sP%ldM5XGGRbn=^ z!d8fx0>8RmsaZ8@JI$;1Xaz2fhU~VvL}Rq5S}8LS9TYQVfie^w1uArAEhP>)E?_D; z3=Wz!k5(Z99ThYoS}Hr54h#waZ%-;P3?2|MtxqX2gpHj@B{&LnDl!v{Sydu377LDn zGZ7CR4-bb`!4VA~2_I8tCJF}%M_MEw2o2@|q@EfG9}x>Qh)E(4=H>?-BvmUe7}*OJ zE_Q8E5yOH%4k-k_7(wGfgb@Utk=t-5Ns0mw5JXs^a0m$s2WFgjkzhlzU% zsD!6wg@_0mlHyFVVnza01y;e5yAo= zyy&0{3q)|iIv5Zzq!275M#l*pSU}|q<17$D3MN>9fr;X@)1DS1c(8yR5hz&&3nNr# z0Rt8&>Q#XwL<$i}4%}&FgjHMtLIMDsAcBWOgrEQiA&e0L2WGAi!v`2xV8HZFJBZ4G6U6>jcUu z_ksxCWI%uc28341MF<33M*~O%>^Q^~BA6gT0wsdiE(A1y6~LP>q`++lGxTGus{V2hYHS+o} literal 0 HcmV?d00001 diff --git a/gpack/travian_default/img/g/s/lvl21_30_active.gif b/gpack/travian_default/img/g/s/lvl21_30_active.gif new file mode 100644 index 0000000000000000000000000000000000000000..f9a06d9f179af220d59b749cfe5f40c673d87564 GIT binary patch literal 930 zcmV;T16}+_Nk%w1VX6QO0M!5h|FgRPr@jBA!vCMb|DePFn#KQ=$p4VZ_ydsti_Q8B zn)?%^|A*218LRyuwEZNy{Uy8qfY<*g!2c}8|9jd0F2?^e&i{Aa|2ftFbKw6u+5d0j z|32UUY~}xA>i=lz|4HcoOzHnz>;GWt|4{7zSMUG)$^ZPz|NPDW`^NwL)BpU{|M|uL z`o{nG#Q*oi|MkQF^uqt~!T<8X|M9~A@4^4XJ$pw!AEnXb-pd!Qt4;I?Jpm87v z3ls+wIV&cXG2sK^haDaivkt{bVJTP^H0pAQph2Ut6)Izfn z6S>UJ7-NK_7$6!*9{x>a2g^oJXl~_d2k9G7OaN$5n#Gb6I{MyFa^lpA4GL_W9xTBE z(&HmKSZL6p%8v3<7a`a|ygnxwCqyg&pyGs^7|Ny8iV1{~;Dia%Eil3gPqdOk4-JrT zf+4;DG=J7{J33`K>aC z3pGH{009OZK)_oQ04XF5F!1<50|gXtKmj&9pn(n$f?$*c4GdrvWJnyg1eRJR02wqm zaQNbxVBj~31P-)$0e2UK5LOH<>;S<8ZIWidoq1wV16@5lAm{^q*`R|4gpwd0iP6EnL4y#Zl4@!dGyFBfsx#=7Lk`_(g+q&*)*1u= EI}$#n00000 literal 0 HcmV?d00001 diff --git a/gpack/travian_default/lang/en/b/zurueck.html b/gpack/travian_default/lang/en/b/zurueck.html index 1b0dc904..01abebcc 100644 --- a/gpack/travian_default/lang/en/b/zurueck.html +++ b/gpack/travian_default/lang/en/b/zurueck.html @@ -10,10 +10,10 @@ - - - - + + + + @@ -42,13 +42,13 @@
Nothing here!

Nothing here!

We looked 404 times already but can't find anything
- +
newsbox 1


- +
newsbox 2
Dear players, @@ -81,7 +81,7 @@
newsbox 3
".round($row['loyalty'])."% $type