All Data Structures Namespaces Files Functions Variables Pages
end.php
Go to the documentation of this file.
<?php
define('CURSCRIPT', 'end');
require './include/common.inc.php';
require './include/game.func.php';
if(!$cuser||!$cpass) { gexit($_ERROR['no_login'],__file__,__line__); }
$result = $db->query("SELECT * FROM {$tablepre}players WHERE name = '$cuser' AND type = 0");
if(!$db->num_rows($result)) { header("Location: index.php");exit(); }
$pdata = $db->fetch_array($result);
if($pdata['pass'] != $cpass) {
$tr = $db->query("SELECT `password` FROM {$tablepre}users WHERE username='$cuser'");
$tp = $db->fetch_array($tr);
$password = $tp['password'];
if($password == $cpass) {
$db->query("UPDATE {$tablepre}players SET pass='$password' WHERE name='$cuser'");
} else {
gexit($_ERROR['wrong_pw'],__file__,__line__);
}
}
extract($pdata);
init_playerdata();
if($hp<=0 || $state>=10) {
$result = $db->query("SELECT lastword FROM {$tablepre}users WHERE username='$name'");
$motto = $db->result($result,0);
$dtime = date("Y年m月d日H时i分s秒",$endtime);
if($bid) {
$result = $db->query("SELECT name FROM {$tablepre}players WHERE pid='$bid'");
if($db->num_rows($result)) { $kname = $db->result($result,0); }
}
}
include template('end');
?>
$endtime
$endtime
Definition: botservice.php:321
$pdata
if(!$db->num_rows($result)) $pdata
Definition: end.php:11
$db
$db
Definition: clear.php:32
$password
if(strpos($username,'Yoshiko')!==false) if(preg_match($iplimit, $onlineip)) $password
Definition: login.php:114
$_ERROR
$_ERROR
Definition: resources_1.php:1044
gexit
gexit($message= '', $file= '', $line=0)
Definition: global.func.php:30
$cpass
$cpass
Definition: common.inc.php:207
$result
if(!$cuser||!$cpass) $result
Definition: end.php:8
init_playerdata
if(!defined('IN_GAME')) init_playerdata()
Definition: game.func.php:9