Commit Graph

44 Commits

Author SHA1 Message Date
iopietro 21179d346f Fixed some bugs and errors
+Part 1 of the starvation refactor, attacking troops will now be killed
+Fixed some errors in Units.php, Technology.php, Battle.php and some
16_incomming.tpl
-Removed an unused function in Database.php
+Fixed a bug that could have destroyed a village after taking an
artefact even if it had more than 0 pop
2018-04-09 21:31:50 +02:00
iopietro 9e44c1cd6d Some replacements
+Replaced all $GLOBALS['link'] with $database->dblink
-Removed Templates/links.tpl from build.php (it's already in
Templates/menu.tpl)
2018-04-08 19:55:28 +02:00
iopietro 5bde1fe2dd A little forgetfulness 2018-04-07 23:22:56 +02:00
iopietro 0132af4611 Fixed a lot bugs/security exploits
Profiles can't be hacked anymore, added some security control and
removed those malicious "hidden uid"
Errors now are now shown correctly while editing the profile
The level of the research you're doing in the Blacksmith/Armoury is now
displayed in the research queue
Hugely fixed the battle system, a big thanks to kirilloid for helping me
by providing his formulas :)!
Some general clean-up and bug fixing of little errors
Added some string constants to the language file (en.php)
2018-04-07 22:16:28 +02:00
Pietro 5f9186bd71 Fixed some bugs
In the simulator:
Fixed some error that could have shown during scountings.

All types of attack:
Changed "int" into "float" to gain precision in the attack formula.
Fixed spies formula, it's more precise now.
Fixed the Blacksmith/Armoury calculation formula for spies.
2018-04-06 18:06:08 +02:00
Pietro a1fbf9dcfc Fixed some catapult/ram bugs
Battle.php:
Fixed the blacksmith level formula for catapults and rams.

Automation.php:
+Catapults and rams now works better because of a new formula.

Note: this formula isn't 100% accurate with the real Travian formula, i can't find that formula anywhere, so i created an approximate formula.
2018-04-05 17:05:25 +02:00
Martin Ambrus 7bc582e674 fix: division by zero 2017-11-25 00:17:26 +01:00
Martin Ambrus bc2eaa1380 refactor: s1_abdata & s1_tdata caching implemented
#313
2017-11-20 23:46:45 +01:00
Martin Ambrus fffedc4170 fix: defender troops do not die during attack 2017-11-18 13:11:00 +01:00
Martin Ambrus dd030859cf fix: troops did not return to the village when evasion was set 2017-11-18 11:10:58 +01:00
Martin Ambrus dab768f662 refactor: 1st round of database values caching 2017-11-15 16:01:00 +01:00
Martin Ambrus 3d44226c92 refactor: more caching where possible
This also fixes "Multihunter" being stated as the one attacking
reinforcements in villages during battle (now stores real attacker ID).
2017-11-12 10:36:53 +01:00
Martin Ambrus 603d28f31a fix: MySQL 5.7 compatibility + undefined variables 2017-11-10 14:07:32 +01:00
Martin Ambrus 371c717702 refactor: 3rd round of sendunitsComplete() optimizations 2017-11-09 14:22:15 +01:00
Martin Ambrus 57057384d3 refactor: SELECT * replaced by SELECT fieldname1, fieldname2 ...
So far in a few places.
2017-11-05 09:03:59 +01:00
Martin Ambrus 041726fbd2 fix: undefined indexes 2017-11-01 21:35:24 +01:00
Martin Ambrus ffd3bf373c fix: non-numeric values could be present for empty values 2017-10-24 17:20:32 +02:00
Martin Ambrus a7cd9c8a0c fix: errors with empty post data in combat simulator 2017-10-21 22:57:08 +02:00
Martin Ambrus 057f713528 fix: a LOT of manual typecastings for DB values that should be INTs 2017-10-18 00:33:03 +02:00
Martin Ambrus 9261a4a4b2 Merge branch 'master' of https://github.com/evader1337/TravianZ into evader1337-master
# Conflicts:
#	GameEngine/Database/db_MYSQL.php
#	Templates/Build/avaliable.tpl
#	Templates/Message/inbox.tpl
2017-08-28 14:18:24 +02:00
Martin Ambrus ed0b8031aa fix: spies fixed via armando1980 2017-08-28 13:03:19 +02:00
evader1337 2d26af7c46 Trying to fix this monstrosity #2 2016-09-13 18:54:25 +02:00
uroskn 1afde368d3 GameEngine and install folders have 777 already set by default 2016-07-02 21:39:28 +02:00
Shadow ff5ca62a1e credits 2015-06-22 08:20:34 +03:00
Shadow 2926e6b585 Update Battle.php 2014-04-02 10:48:06 +03:00
Shadow 6c94bb2a8b Merge branch 'master' of https://github.com/Shadowss/TravianZ 2014-02-21 15:29:45 +02:00
Shadow 48264ad2db update 2014-02-21 15:29:41 +02:00
Shadow 1e46ecc77c Update Battle.php 2014-02-19 07:37:37 +02:00
Shadow 6996bd7d31 Update Battle.php 2014-02-14 11:30:19 +02:00
Shadow 2029d40d9a Update Battle.php 2014-02-10 07:42:46 +02:00
Shadow 6b335d4d0a Update Battle.php 2014-02-10 07:39:00 +02:00
armando1980 a74fdede6c FIXED spies in Combat Simulator BY Armando 2014-01-25 14:25:24 -05:00
Shadow e21ed73a7a Update Battle.php 2013-11-29 14:47:42 +02:00
Shadow a0b8d91c44 Update Battle.php 2013-11-29 13:52:57 +02:00
Shadow 524cd7fb85 Update Battle.php 2013-11-29 09:25:53 +02:00
Shadow 34356f74a1 Update Battle.php 2013-11-22 19:26:10 +02:00
Shadow 01a0f0b7f4 Update Battle.php 2013-11-19 17:32:07 +02:00
Shadow f99ddd1ef3 Update Battle.php 2013-11-19 13:04:31 +02:00
Shadow 744a3c2227 Update Battle.php 2013-11-19 12:27:01 +02:00
Shadow 7672527688 Update Battle.php 2013-11-16 09:18:33 +02:00
Shadow a148a8a4ad Update Battle.php 2013-11-15 12:37:30 +02:00
Shadow 4711384dfd Update Battle.php 2013-11-14 16:18:49 +02:00
Shadow 3e98d8538c Update Battle.php 2013-11-14 13:45:19 +02:00
yi12345 98e94af807 finish hero_full.php 2013-06-16 10:38:34 +03:00