コード例 #1
0
ファイル: GetCmpstByGM.php プロジェクト: svn2github/ybtx
function GMCancelCmpst($var, $gm)
{
    global $tbl_sys_msg;
    $gm_name = mysql_escape_string($gm);
    $id = intval($var["id"]);
    $qs = "update tbl_gm_compensate_action set action_state=2 where gca_uId = '{$id}' and gm = '{$gm_name}'";
    $result = MySQLQuery($qs, "GMS");
    $qs = "select action_id, reason, server_id from tbl_gm_compensate_action where gca_uId = '{$id}'";
    $result = MySQLQuery($qs, "GMS");
    $row = mysql_fetch_row($result);
    $action_id = intval($row[0]);
    if ($action_id < 10) {
        $action_str = "000" . $action_id;
    } elseif ($action_id < 100) {
        $action_str = "00" . $action_id;
    } elseif ($action_id < 1000) {
        $action_str = "0" . $action_id;
    }
    if (LogGMCommand($gm_name, $var["action_name"] . "." . $action_str, $row[1], $row[2])) {
        PrintNotice($tbl_sys_msg["success"]);
        BackAndRefresh($tbl_sys_msg["success"]);
        return true;
    }
    return false;
}
コード例 #2
0
ファイル: BulletinMgr.php プロジェクト: svn2github/ybtx
function DelBulletin($var, $gm)
{
    $id = intval($var["id"]);
    $gm_name = mysql_escape_string($gm);
    $qs = "update tbl_gm_anousment set state = 2 where ga_id = '{$id}'";
    $result = MySQLQuery($qs, "GMS");
    $qs = "select title, begin_time, end_time, step, content, serverid from tbl_gm_anousment where ga_id = '{$id}'";
    $result = MySQLQuery($qs, "GMS");
    $row = mysql_fetch_row($result);
    $begin_time = $row[1];
    $end_time = $row[2];
    $step = $row[3];
    $title = $row[0];
    $content = $row[4];
    $serv_id = $row[5];
    $action = array("title" => $title, "content" => $content, "begin_time" => $begin_time, "end_time" => $end_time, "step" => $step);
    if (LogGMCommand($gm_name, $var["action_name"], $action, $serv_id)) {
        PrintNotice(LogInfo($action, true));
        BackAndRefresh();
        return true;
    }
    return false;
}
コード例 #3
0
ファイル: GetBackEquip.php プロジェクト: svn2github/ybtx
function GetBackEquipFun($var, $gm)
{
    $attr = $var["attr"];
    $item_type = intval($var["item_type"]);
    $server_id = intval($var["serverid"]);
    $role_name = $var["role_name"];
    $reason = $var["reason"];
    $attr_array = explode(";", $attr);
    $temp = explode(",", $attr_array[0]);
    $item_name = $temp[0];
    $item_type = $temp[1];
    $item_id = $temp[2];
    $param = array();
    $param["role_name"] = $role_name;
    $param["item_name"] = UTF82Local($item_name);
    $param["item_type"] = $item_type;
    SetParamInfo($param, explode(",", $attr_array[1]), "St");
    SetParamInfo($param, explode(",", $attr_array[2]), "SA");
    SetParamInfo($param, explode(",", $attr_array[3]), "Ad");
    SetParamInfo($param, explode(",", $attr_array[4]), "Ar1");
    SetParamInfo($param, explode(",", $attr_array[5]), "Ar2");
    SetParamInfo($param, explode(",", $attr_array[6]), "Ar3");
    SetParamInfo($param, explode(",", $attr_array[7]), "Ar4");
    SetParamInfo($param, explode(",", $attr_array[8]), "In");
    SetParamInfo($param, explode(",", $attr_array[9]), "IAA");
    SetParamInfo($param, explode(",", $attr_array[10]), "Du");
    SetParamInfo($param, explode(",", $attr_array[11]), "Bd");
    SetParamInfo($param, explode(",", $attr_array[12]), "Su");
    global $tbl_game_server;
    $gas_host = $tbl_game_server[$server_id][0];
    $gas_port = $tbl_game_server[$server_id][1];
    $ret = PostData($gas_host, $gas_port, "GetBackEquip", $param);
    $action = array("role_name" => $role_name, "type" => $item_type, "item" => $item_name, "item_id" => $item_id, "reason" => $reason);
    if (intval($ret) != 200) {
        PrintNotice(LogInfo($action, false, $ret));
        BackAndRefresh($tbl_sys_msg["success"]);
        return true;
    }
    if (LogGMCommand($gm, $var["action_name"], $action, $server_id)) {
        PrintNotice(LogInfo($action, true));
        BackAndRefresh($tbl_sys_msg["success"]);
        return true;
    }
    return false;
}
コード例 #4
0
ファイル: Management.php プロジェクト: svn2github/ybtx
function CancelUserTrust($var, $gm)
{
    $role_name = $var["role_name"];
    $reason = $var["reason"];
    $serverid = $var["serverid"];
    $param = array();
    $param["role_name"] = $role_name;
    $action = array("role_name" => $role_name, "reason" => $reason);
    global $tbl_game_server;
    $gas_host = $tbl_game_server[$serverid][0];
    $gas_port = $tbl_game_server[$serverid][1];
    $ret = PostData($gas_host, $gas_port, "CancelUserTrust", $param);
    if (intval($ret) != 200) {
        PrintNotice(LogInfo($action, false, $ret));
        BackAndRefresh();
        return true;
    }
    if (LogGMCommand($gm_name, $var["action_name"], $action, $serverid)) {
        PrintNotice(LogInfo($action, true));
        BackAndRefresh();
        return true;
    }
    return false;
}
コード例 #5
0
ファイル: CorpsTotal.php プロジェクト: svn2github/ybtx
function ChangeTongLevel($var, $gm)
{
    global $tbl_game_server;
    $level = $var["new_name"];
    $id = $var["id"];
    $serverid = $var["serverid"];
    $reason = $var["reason"];
    $row = mysql_fetch_row(MySQLQuery("select t_sName from tbl_tong where t_uId = {$id}", "Game", $serverid));
    $tong_name = $row[0];
    $param = array();
    $param["id"] = $id;
    $param["level"] = $level;
    $gas_host = $tbl_game_server[$serverid][0];
    $gas_port = $tbl_game_server[$serverid][1];
    $ret = PostData($gas_host, $gas_port, "ChangeTongLevel", $param);
    $action = array("tong" => $tong_name, "level" => $level, "reason" => $reason);
    if (intval($ret) != 200) {
        PrintNotice(LogInfo($action, false, $ret));
        BackAndRefresh();
        return true;
    }
    if (LogGMCommand($gm, $var["action_name"], $action, $serverid)) {
        PrintNotice(LogInfo($action, true));
        BackAndRefresh();
        return true;
    }
    return false;
}
コード例 #6
0
ファイル: ReqAction.php プロジェクト: svn2github/ybtx
function ReqItemUseLimitCanel($var, $gm)
{
    BackAndRefresh();
    return eachServer($var, $gm, ReqItemUseLimitCanel_f);
}
コード例 #7
0
ファイル: CorpsMember.php プロジェクト: svn2github/ybtx
function ChangeTongMemberFun($tong_id, $role_id, $position, $tong_name, $role_name, $serverid, $reason, $gm, $o_position)
{
    global $tbl_game_server, $tbl_tong_pos, $ChangeTongMember;
    $param = array();
    $param["tong_id"] = $tong_id;
    $param["role_id"] = $role_id;
    $param["position"] = $position;
    $param["msg"] = sprintf($ChangeTongMember[0], $tbl_tong_pos[$o_position], $role_name, $tbl_tong_pos[$position]);
    $gas_host = $tbl_game_server[$serverid][0];
    $gas_port = $tbl_game_server[$serverid][1];
    $ret = PostData($gas_host, $gas_port, "ChangeTongMember", $param);
    $action = array("tong" => $tong_name, "role_name" => $role_name, "pos" => $position, "reason" => $reason);
    if (intval($ret) != 200) {
        PrintNotice(LogInfo($action, false, $ret));
        BackAndRefresh();
        return true;
    }
    if (LogGMCommand($gm, 171, $action, $serverid)) {
        PrintNotice(LogInfo($action, true));
        BackAndRefresh();
        return true;
    }
}
コード例 #8
0
ファイル: TalkMgr.php プロジェクト: svn2github/ybtx
function ChannelWordDel($var, $gm)
{
    global $tbl_channel_word;
    echo "<h1>" . $tbl_channel_word[5] . "</h1>\n";
    $word = $var["word"];
    $result = MySQLQuery("delete from tbl_channel_word where word = '{$word}'", "GMS");
    if (mysql_affected_rows() > 0) {
        PrintNotice(sprintf($tbl_channel_word[6], $word));
        if (ChannelChatLoad()) {
            global $tbl_sys_msg;
            PrintNotice($tbl_sys_msg["check_chat"]);
        }
    }
    BackAndRefresh();
    return true;
}
コード例 #9
0
ファイル: DealCompensate.php プロジェクト: svn2github/ybtx
function AddHonorToTong($var, $gm, $role_name, $arg1, $arg2, $reason)
{
    $gm_name = mysql_escape_string($gm);
    $serverid = intval($var["serverid"]);
    $param = array();
    $param["tong_name"] = $role_name;
    $param["add_honor"] = $arg1;
    global $tbl_game_server;
    $gas_host = $tbl_game_server[$serverid][0];
    $gas_port = $tbl_game_server[$serverid][1];
    $ret = PostData($gas_host, $gas_port, "AddHonorToTong", $param);
    if (intval($ret) != 200) {
        PrintNotice(LogInfo($reason, false, $ret));
        BackAndRefresh($tbl_sys_msg["success"]);
        return true;
    }
    if (LogGMCommand($gm_name, $var["action_name"] . ".0250", $reason, $serverid)) {
        PrintNotice(LogInfo($reason, true));
        BackAndRefresh($tbl_sys_msg["success"]);
        return true;
    }
    return false;
}