mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-07-02 10:34:31 +00:00
start to work on gold club and edit plus/1.tpl
This commit is contained in:
@@ -138,6 +138,7 @@ class Session {
|
||||
$this->gpack = $this->userarray['gpack'];
|
||||
$this->access = $this->userarray['access'];
|
||||
$this->plus = ($this->userarray['plus'] > $this->time);
|
||||
$this->goldclub = $this->userarray['goldclub'];
|
||||
$this->villages = $database->getVillagesID($this->uid);
|
||||
$this->tribe = $this->userarray['tribe'];
|
||||
$this->isAdmin = $this->access >= MODERATOR;
|
||||
|
||||
@@ -0,0 +1,254 @@
|
||||
<?php
|
||||
############################### S T A R T ################################
|
||||
## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
## Filename config.php ##
|
||||
## Version 4.8.5 ##
|
||||
## Developed by: Dzoki and Dixie Edited by Advocaite ##
|
||||
## License: TravianX Project ##
|
||||
## Copyright: TravianX (c) 2010-2011. All rights reserved. ##
|
||||
## ##
|
||||
#################################################################################
|
||||
|
||||
//////////////////////////////////
|
||||
// ***** ERROR REPORTING *****//
|
||||
//////////////////////////////////
|
||||
// (E_ALL ^ E_NOTICE) = enabled
|
||||
// (0) = disabled
|
||||
error_reporting (E_ALL ^ E_NOTICE);
|
||||
|
||||
//////////////////////////////////
|
||||
// ***** SERVER SETTINGS *****//
|
||||
//////////////////////////////////
|
||||
|
||||
// ***** Name
|
||||
define("SERVER_NAME","TravianX");
|
||||
|
||||
// ***** Started
|
||||
// Defines when has server started.
|
||||
define("COMMENCE","1333606567");
|
||||
|
||||
// ***** Language
|
||||
// Choose your server language.
|
||||
define("LANG","en");
|
||||
|
||||
// ***** Speed
|
||||
// Choose your server speed. NOTICE: Higher speed, more likely
|
||||
// to have some bugs. Lower speed, most likely no major bugs.
|
||||
// Values: 1 (normal), 3 (3x speed) etc...
|
||||
define("SPEED", "100000");
|
||||
|
||||
// ***** World size
|
||||
// Defines world size. NOTICE: DO NOT EDIT!!
|
||||
define("WORLD_MAX", "25");
|
||||
|
||||
// ***** Graphic Pack
|
||||
// True = enabled, false = disabled
|
||||
//!!!!!!!!!!!! DO NOT ENABLE !!!!!!!!!!!!
|
||||
define("GP_ENABLE",false);
|
||||
// Graphic pack location (default: gpack/travian_default/)
|
||||
define("GP_LOCATE", "gpack/travian_default/");
|
||||
|
||||
// ***** Troop Speed
|
||||
// Values: 1 (normal), 3 (3x speed) etc...
|
||||
define("INCREASE_SPEED","1000");
|
||||
|
||||
// ***** Trader capacity
|
||||
// Values: 1 (normal), 3 (3x speed) etc...
|
||||
define("TRADER_CAPACITY","1");
|
||||
|
||||
|
||||
// ***** Village Expand
|
||||
// 1 = slow village expanding - more Cultural Points needed for every new village
|
||||
// 0 = fast village expanding - less Cultural Points needed for every new village
|
||||
define("CP", 0);
|
||||
|
||||
// ***** Demolish Level Required
|
||||
// Defines which level of Main building is required to be able to
|
||||
// demolish. Min value = 1, max value = 20
|
||||
// Default: 10
|
||||
define("DEMOLISH_LEVEL_REQ","10");
|
||||
|
||||
// ***** Change storage capacity
|
||||
define("STORAGE_MULTIPLIER","1");
|
||||
define("STORAGE_BASE",800*STORAGE_MULTIPLIER);
|
||||
|
||||
// ***** Quest
|
||||
// Ingame quest enabled/disabled.
|
||||
define("QUEST",true);
|
||||
|
||||
// ***** Beginners Protection
|
||||
// 3600 = 1 hour
|
||||
// 3600*12 = 12 hours
|
||||
// 3600*24 = 1 day
|
||||
// 3600*24*3 = 3 days
|
||||
// You can choose any value you want!
|
||||
define("PROTECTION","0");
|
||||
|
||||
// ***** Enable WW Statistics
|
||||
define("WW",True);
|
||||
|
||||
// ***** Enable T4 is Coming screen
|
||||
define("T4_COMING",false);
|
||||
|
||||
// ***** Activation Mail
|
||||
// true = activation mail will be sent, users will have to finish registration
|
||||
// by clicking on link recieved in mail.
|
||||
// false = users can register with any mail. Not needed to be real one.
|
||||
define("AUTH_EMAIL",false);
|
||||
|
||||
// ***** PLUS
|
||||
//Plus account lenght
|
||||
define("PLUS_TIME",3600*24*7);
|
||||
//+25% production lenght
|
||||
define("PLUS_PRODUCTION",3600*24*7);
|
||||
// ***** Great Workshop
|
||||
define("GREAT_WKS",True);
|
||||
// ***** Tourn threshold
|
||||
define("TS_THRESHOLD",20);
|
||||
|
||||
|
||||
|
||||
//////////////////////////////////
|
||||
// **** LOG SETTINGS **** //
|
||||
//////////////////////////////////
|
||||
// LOG BUILDING/UPGRADING
|
||||
define("LOG_BUILD",true);
|
||||
// LOG RESEARCHES
|
||||
define("LOG_TECH",true);
|
||||
// LOG USER LOGIN (IP's)
|
||||
define("LOG_LOGIN",true);
|
||||
// LOG GOLD
|
||||
define("LOG_GOLD_FIN",true);
|
||||
// LOG ADMIN
|
||||
define("LOG_ADMIN",true);
|
||||
// LOG ATTACK REPORTS
|
||||
define("LOG_WAR",true);
|
||||
// LOG MARKET REPORTS
|
||||
define("LOG_MARKET",true);
|
||||
// LOG ILLEGAL ACTIONS
|
||||
define("LOG_ILLEGAL",true);
|
||||
|
||||
|
||||
|
||||
//////////////////////////////////
|
||||
// **** NEWSBOX SETTINGS **** //
|
||||
//////////////////////////////////
|
||||
//true = enabled
|
||||
//false = disabled
|
||||
define("NEWSBOX1",true);
|
||||
define("NEWSBOX2",false);
|
||||
define("NEWSBOX3",false);
|
||||
|
||||
|
||||
|
||||
//////////////////////////////////
|
||||
// **** SQL SETTINGS **** //
|
||||
//////////////////////////////////
|
||||
|
||||
// ***** SQL Hostname
|
||||
// example. sql106.000space.com / localhost
|
||||
// If you host server on own PC than this value is: localhost
|
||||
// If you use online hosting, value must be written in host cpanel
|
||||
define("SQL_SERVER", "localhost");
|
||||
|
||||
// ***** Database Username
|
||||
define("SQL_USER", "root");
|
||||
|
||||
// ***** Database Password
|
||||
define("SQL_PASS", "");
|
||||
|
||||
// ***** Database Name
|
||||
define("SQL_DB", "travianx");
|
||||
|
||||
// ***** Database - Table Prefix
|
||||
define("TB_PREFIX", "s1_");
|
||||
|
||||
// ***** Database type
|
||||
// 0 = MYSQL
|
||||
// 1 = MYSQLi
|
||||
// default: 1
|
||||
define("DB_TYPE", 0);
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////
|
||||
// **** EXTRA SETTINGS **** //
|
||||
////////////////////////////////////
|
||||
|
||||
// ***** Censore words
|
||||
//define("WORD_CENSOR", "%ACTCEN%");
|
||||
|
||||
// ***** Words (censore)
|
||||
// Choose which words do you want to be censored
|
||||
//define("CENSORED","%CENWORDS%");
|
||||
|
||||
|
||||
// ***** Limit Mailbox
|
||||
// Limits mailbox to defined number of mails. (IGM's)
|
||||
define("LIMIT_MAILBOX",true);
|
||||
// If enabled, define number of maximum mails.
|
||||
define("MAX_MAIL","30");
|
||||
|
||||
// ***** Include administrator in statistics/rank
|
||||
define("INCLUDE_ADMIN", False);
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////
|
||||
// **** ADMIN SETTINGS **** //
|
||||
////////////////////////////////////
|
||||
|
||||
// ***** Admin Email
|
||||
define("ADMIN_EMAIL", "");
|
||||
|
||||
// ***** Admin Name
|
||||
define("ADMIN_NAME", "");
|
||||
|
||||
|
||||
|
||||
//////////////////////////////////////////
|
||||
// **** DO NOT EDIT SETTINGS **** //
|
||||
//////////////////////////////////////////
|
||||
define("TRACK_USR","");
|
||||
define("USER_TIMEOUT","");
|
||||
define("ALLOW_BURST",false);
|
||||
define("BASIC_MAX",1);
|
||||
define("INNER_MAX",1);
|
||||
define("PLUS_MAX",1);
|
||||
define("ALLOW_ALL_TRIBE",false);
|
||||
define("CFM_ADMIN_ACT",true);
|
||||
define("SERVER_WEB_ROOT",false);
|
||||
define("USRNM_SPECIAL",true);
|
||||
define("USRNM_MIN_LENGTH",3);
|
||||
define("PW_MIN_LENGTH",4);
|
||||
define("BANNED",0);
|
||||
define("AUTH",1);
|
||||
define("USER",2);
|
||||
define("MULTIHUNTER",8);
|
||||
define("ADMIN",9);
|
||||
define("COOKIE_EXPIRE", 60*60*24*7);
|
||||
define("COOKIE_PATH", "/");
|
||||
|
||||
|
||||
////////////////////////////////////////////
|
||||
// **** DOMAIN/SERVER SETTINGS **** //
|
||||
////////////////////////////////////////////
|
||||
define("DOMAIN", "");
|
||||
define("HOMEPAGE", "http://localhost/");
|
||||
define("SERVER", "");
|
||||
|
||||
$requse = 0;
|
||||
|
||||
############################### E N D ##################################
|
||||
## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
## Filename config.php ##
|
||||
## Version 4.8.5 ##
|
||||
## Developed by: Dzoki and Dixie Edited by Advocaite ##
|
||||
## License: TravianX Project ##
|
||||
## Copyright: TravianX (c) 2010-2011. All rights reserved. ##
|
||||
## ##
|
||||
#################################################################################
|
||||
|
||||
?>
|
||||
@@ -207,7 +207,7 @@ while ($donnees = mysql_fetch_assoc($result2)){
|
||||
<span>x </span><input id="mcx" class="text" name="xp" value="<?php echo $x ?>" maxlength="4"/>
|
||||
<span>y </span><input id="mcy" class="text" name="yp" value="<?php echo $y ?>" maxlength="4"/>
|
||||
<input type="image" id="btn_ok" class="dynamic_img" value="ok" name="s1" src="img/x.gif" alt="OK" /><br />
|
||||
<?php if($session->plus != 0){echo "<a href=\"crop_finder.php\"><img src=\"".GP_LOCATE."img/misc/cropfinder.gif\" /> Crop Finder</a>";}?>
|
||||
<?php if($session->goldclub != 0){echo "<a href=\"crop_finder.php\"><img src=\"".GP_LOCATE."img/misc/cropfinder.gif\" /> Crop Finder</a>";}?>
|
||||
</form>
|
||||
</div>
|
||||
<table cellpadding="1" cellspacing="1" id="map_infobox" class="default"><thead><tr><th colspan="2">Details</th></tr></thead><tbody><tr><th>Player</th><td>-</td></tr><tr><th>Population</th><td>-</td></tr><tr><th>Alliance</th><td></td></tr></tbody></table>
|
||||
|
||||
@@ -436,6 +436,4 @@ if($session->access != BANNED){
|
||||
<div class="clear"></div>
|
||||
<div style="padding: 10px 10px; font-style: italic; font-size: 10px;">All prices listed are final sales amounts.</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
////////////// made by alq0rsan /////////////////////////
|
||||
if($session->access != BANNED){
|
||||
if($session->gold >= 100) {
|
||||
mysql_query("UPDATE ".TB_PREFIX."users set goldclub = 1, gold = gold - 100 where `username`='".$session->username."'");
|
||||
}
|
||||
include("Templates/Plus/3.tpl");
|
||||
}else{
|
||||
header("Location: banned.php");
|
||||
}
|
||||
?>
|
||||
@@ -455,4 +455,54 @@ if (mysql_num_rows($MyGold)) {
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
<table class="plusFunctions" cellpadding="1" cellspacing="1">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="5">Travian Gold Club</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
|
||||
<td>Description</td>
|
||||
<td>Duration</td>
|
||||
<td>Gold</td>
|
||||
<td>Action</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td class="man"></td>
|
||||
<td class="desc">
|
||||
<b>Gold Club</b></br>
|
||||
<font size="2">Gold Club including: farmlist, merchants run three times, crop finder, master builder, trade routes and automatic send away troops before an attack.</font>
|
||||
<span class="run">
|
||||
</span>
|
||||
</td>
|
||||
<td class="dur">Active for the current round of the game, not including bouns production or plus additions.
|
||||
</td>
|
||||
<td class="cost"><img src="img/x.gif" class="gold" alt="Gold" title="Gold" alt="Gold" title="Gold" />100</td>
|
||||
<td class="act">
|
||||
|
||||
<?php
|
||||
$MyGold = mysql_query("SELECT * FROM ".TB_PREFIX."users WHERE `username`='".$session->username."'") or die(mysql_error());
|
||||
$golds = mysql_fetch_array($MyGold);
|
||||
|
||||
if (mysql_num_rows($MyGold)) {
|
||||
if($golds['goldclub']==0){
|
||||
if($golds['gold'] > 99) {
|
||||
echo '
|
||||
<a href="plus.php?id=15"><span>Activate';
|
||||
}else{
|
||||
echo '
|
||||
<a href="plus.php?s=1"><span class="none">too little gold';
|
||||
|
||||
}} else {
|
||||
echo '<a href="plus.php?id=3"><span class="none">On';}
|
||||
}
|
||||
?>
|
||||
</span></a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
+1
-1
@@ -10,7 +10,7 @@
|
||||
|
||||
include ("GameEngine/Village.php");
|
||||
|
||||
if($session->plus == 0) {
|
||||
if($session->goldclub == 0) {
|
||||
header("Location: plus.php?id=3");
|
||||
}
|
||||
|
||||
|
||||
@@ -1234,6 +1234,7 @@ CREATE TABLE IF NOT EXISTS `%PREFIX%users` (
|
||||
`desc1` text NOT NULL,
|
||||
`desc2` text NOT NULL,
|
||||
`plus` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`goldclub` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`b1` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`b2` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`b3` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
|
||||
Reference in New Issue
Block a user