Tokiwa Battle Royale  GE777
A PHP Battle Royale inspired game
 All Data Structures Namespaces Files Functions Variables Pages
dbup.php
Go to the documentation of this file.
1 <?php
2 
3 define('CURSCRIPT', 'dbup');
4 
5 define('IN_GAME', TRUE);
6 define('GAME_ROOT', dirname(__FILE__));
7 define('GAMENAME', 'bra');
8 
9 if(PHP_VERSION < '4.3.0') {
10  exit('PHP version must >= 4.3.0!');
11 }
12 require GAME_ROOT.'./include/global.func.php';
13 
14 $magic_quotes_gpc = get_magic_quotes_gpc();
15 extract(gstrfilter($_COOKIE));
16 extract(gstrfilter($_POST));
17 unset($_GET);
19 
20 require GAME_ROOT.'./config.inc.php';
21 
22 $errorinfo ? error_reporting(E_ALL) : error_reporting(0);
23 $now = time() + $moveut*3600 + $moveutmin*60;
24 list($sec,$min,$hour,$day,$month,$year,$wday) = explode(',',date("s,i,H,j,n,Y,w",$now));
25 
26 
27 //if($attackevasive) {
28 // include_once GAME_ROOT.'./include/security.inc.php';
29 //}
30 
31 require GAME_ROOT.'./include/db_'.$database.'.class.php';
32 $db = new dbstuff;
34 //$db->select_db($dbname);
36 
37 require GAME_ROOT.'./gamedata/system.php';
38 require config('resources',$gamecfg);
39 require config('gamecfg',$gamecfg);
40 
41 //include GAME_ROOT.'./gamedata/gameinfo.php';
42 $q = "ALTER TABLE {$tablepre}winners ADD killnum2 smallint unsigned NOT NULL default 0 AFTER killnum";
43 echo $q.'<br>';
44 echo $db->query($q);
45 $q = "ALTER TABLE {$tablepre}users ADD credits2 mediumint NOT NULL default 0 AFTER credits";
46 echo $q.'<br>';
47 echo $db->query($q);
48 ?>
$database
Definition: config.inc.php:67
$magic_quotes_gpc
Definition: dbup.php:14
$gamecfg
Definition: system.php:22
$_FILES
Definition: dbup.php:18
$moveutmin
Definition: config.inc.php:52
$dbpw
Definition: config.inc.php:12
gstrfilter($str)
Definition: global.func.php:48
const GAME_ROOT
Definition: dbup.php:6
$db
Definition: dbup.php:32
$q
Definition: dbup.php:42
$now
Definition: dbup.php:23
$moveut
Definition: config.inc.php:49
$errorinfo
Definition: config.inc.php:94
config($file= '', $cfg=1)
$dbhost
Definition: config.inc.php:6
$dbuser
Definition: config.inc.php:9
$pconnect
Definition: config.inc.php:40
$dbname
Definition: config.inc.php:15