Enable and disable display of oases

+Now during the installation (or after installation in the admin panel) you can enable or disable oasis display for villages in the player profile.

NOTE: To play this version of the game, you need to reinstall the server OR you can simply add these lines of code into your file:
GameEngine/config.php

/////////////////////////////////////////////////
//   ****  NEW MECHANICS AND FUNCTIONS  ****   //
/////////////////////////////////////////////////
define("NEW_FUNCTIONS_OASIS", True);

GameEngine/Admin/Modsconstant_format.tpl

/////////////////////////////////////////////////
//   ****  NEW MECHANICS AND FUNCTIONS  ****   //
/////////////////////////////////////////////////
define("NEW_FUNCTIONS_OASIS", %NEW_FUNCTIONS_OASIS%);

NOTICE 2: pay special attention to the fact that these are two different records !!! If the records are entered incorrectly, you will receive a non-working code!
This commit is contained in:
Vladyslav
2018-06-20 16:57:13 +03:00
parent 7747a301be
commit 11ae61c013
13 changed files with 306 additions and 60 deletions
+17
View File
@@ -179,7 +179,24 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN);
<td><b><?php echo (ERROR_REPORT=="error_reporting (0);")? "No": "Yes";?></b></td>
</tr>
</table>
<table id="member">
<thead>
<tr>
<th>New Mechanics and Functions <a href="admin.php?p=editNewFunctions"><img src="../img/admin/edit.gif" title="Edit New Mechanics and Functions"></a></th>
</tr>
</thead>
</table>
<table id="profile">
<tr>
<td class="b"><?php echo SERV_VARIABLE ?></td>
<td class="b"><?php echo SERV_VALUE ?></td>
</tr>
<tr>
<td>Display oasis in profile <em class="tooltip">?<span class="classic">Turns on or off the display of oases of each village in the player profile</span></em></td>
<td><?php echo NEW_FUNCTIONS_OASIS ? "<b><font color='Green'>Enabled</font></b>" : "<b><font color='Red'>Disabled</font></b>"; ?></td>
</tr>
</table>
<table id="member">
<thead>
<tr>
+44
View File
@@ -0,0 +1,44 @@
<?php
#################################################################################
## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
## --------------------------------------------------------------------------- ##
## Filename editNewFunctions.tpl ##
## Developed by: velhbxtyrj ##
## License: TravianZ Project ##
## Copyright: TravianZ (c) 2010-2014. All rights reserved. ##
## ##
#################################################################################
if (!isset($_SESSION)) {
session_start();
}
if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN);
?>
<h2><center><?php echo SERV_CONFIG ?></center></h2>
<form action="../GameEngine/Admin/Mods/editNewFunctions.php" method="POST">
<input type="hidden" name="id" id="id" value="<?php echo $_SESSION['id']; ?>">
<br />
<table id="profile" cellpadding="0" cellspacing="0">
<thead>
<tr>
<th colspan="2">Edit New Mechanics and Functions</th>
</tr>
</thead>
<tbody>
<tr>
<td width="50%">Display oasis in profile <em class="tooltip">?<span class="classic">Turns on or off the display of oases of each village in the player profile</span></em></td>
<td width="50%">
<select name="new_functions_oasis">
<option value="True" <?php if(NEW_FUNCTIONS_OASIS==true) echo "selected";?>>True</option>
<option value="False" <?php if(NEW_FUNCTIONS_OASIS==false) echo "selected";?>>False</option>
</select>
</td>
</tr>
</tbody>
</table>
<br />
<table width="100%">
<tr><td align="left"><a href="../Admin/admin.php?p=config"><< <?php echo EDIT_BACK ?></a></td>
<td align="right"><input type="image" border="0" src="../img/admin/b/ok1.gif"></td>
</tr>
</table>
</form>