About 64 results: "mysql_query repo:Dzoki/travianx"
Page 1 of 4
Filter Results
Sources
Languages
Filter Results
Try Search On





37_train.tpl in travianx https://bitbucket.org/Dzoki/travianx.git | 583 lines | Smarty
  1.     //check if there is unit needed in the village
  2.     $result = mysql_query("SELECT * FROM ".TB_PREFIX."units WHERE `vref` = ".$village->wid."");
  3.                 if($_GET['train'] == 1){
  4.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '1', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u1['time'] / SPEED)*3)."', '50')");
  5.                 if($_GET['train'] == 2){
  6.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '2', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u2['time'] / SPEED)*3)."', '50')");
  7.                 if($_GET['train'] == 5){
  8.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '5', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u5['time'] / SPEED)*3)."', '50')");
  9.                 if($_GET['train'] == 6){
  10.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '6', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u6['time'] / SPEED)*3)."', '50')");
  11.                 if($_GET['train'] == 11){
  12.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '11', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u11['time'] / SPEED)*3)."', '50')");
  13.                 if($_GET['train'] == 12){
  14.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '12', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u12['time'] / SPEED)*3)."', '50')");
  15.                 if($_GET['train'] == 13){
  16.                     mysql_query("INSERT INTO ".TB_PREFIX."hero (`uid`, `unit`, `name`, `level`, `points`, `experience`, `dead`, `health`, `attack`, `defence`, `attackbonus`, `defencebonus`, `trainingtime`, `autoregen`) VALUES ('".$session->uid."', '13', '".$session->username."', '0', '10', '0', '0', '100', '0', '0', '0', '0', '".(time() + ($u13['time'] / SPEED)*3)."', '50')");















Back to Top