[問題]水怪rpg的蘿莉帝國刑場的路人砍了不失血

phpBB 2 MOD Support
無論是官方或非官方認證之外掛,安裝與使用問題討論。
(發表文章請按照公告格式發表,違者砍文)

版主: 版主管理群

diber
星球普通子民
星球普通子民
文章: 6
註冊時間: 2003-12-25 09:41

[問題]水怪rpg的蘿莉帝國刑場的路人砍了不失血

文章 diber »

問題外掛:水怪rpg的蘿莉帝國刑場的路人砍了不失血
參考連結:http://phpbb-tw.net/phpbb/viewtopic.php?t=20786
http://www.rdi.com.tw/modules/mydownloa ... eA&show=10
使用版本:(phpBB 2.0.6)
網站位置:http://w3.cies.tyc.edu.tw/~diber/html/m ... action=eol
帳號 test 密碼 5566

狀況描述: 水怪rpg的蘿莉帝國刑場的路人砍了不失血,但被路人砍反而會失血,不知是那裏有問題,然後也不知要貼那個程式碼上來,先貼兩個
rpg.php

代碼: 選擇全部

<?php

define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_RPG);
init_userprefs($userdata);
//
// End session management
//

//
// Start of program proper
//
if ( isset($HTTP_GET_VARS['action']) || isset($HTTP_POST_VARS['action']) )
{
	$mode = ( isset($HTTP_GET_VARS['action']) ) ? $HTTP_GET_VARS['action'] : $HTTP_POST_VARS['action'];

	if ( $mode == 'menu' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=menu", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/menu.'.$phpEx);
		exit;
	}

	if ( $mode == 'extra' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=extra", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/extra.'.$phpEx);
		exit;
	}

	if ( $mode == 'position' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=position", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/position.'.$phpEx);
		exit;
	}

	if ( $mode == 'items' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=items", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/items.'.$phpEx);
		exit;
	}

	if ( $mode == 'weapons' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=weapons", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/weapons.'.$phpEx);
		exit;
	}
if ( $mode == 'defend' ) 
{ 
if ( !$userdata['session_logged_in'] ) 
{ 
$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: "; 
header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=defend", true)); 
exit; 
} 
include($phpbb_root_path . 'rpg/defend.'.$phpEx); 
exit; 
}
	if ( $mode == 'magic' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=magic", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/magic.'.$phpEx);
		exit;
	}

	if ( $mode == 'hospital' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=hospital", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/hospital.'.$phpEx);
		exit;
	}

	if ( $mode == 'joinjobs' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=joinjobs", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/joinjobs.'.$phpEx);
		exit;
	}

	if ( $mode == 'dice' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=dice", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/dice.'.$phpEx);
		exit;
	}

	if ( $mode == 'race' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=race", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/race.'.$phpEx);
		exit;
	}

	if ( $mode == 'gamble' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=gamble", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/gamble.'.$phpEx);
		exit;
	}

	if ( $mode == 'bank' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=bank", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/bank.'.$phpEx);
		exit;
	}

	if ( $mode == 'rob' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=rob", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/rob.'.$phpEx);
		exit;
	}

	if ( $mode == 'richer' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=richer", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/richer.'.$phpEx);
		exit;
	}

	if ( $mode == 'eol' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=eol", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/eol.'.$phpEx);
		exit;
	}

	if ( $mode == 'stat' )
	{
		if ( !$userdata['session_logged_in'] )
		{
			$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
			header($header_location . append_sid("login.$phpEx?redirect=rpg.$phpEx&action=stat", true));
			exit;
		}
		include($phpbb_root_path . 'rpg/stat.'.$phpEx);
		exit;
	}

}
else
{
	$header_location = ( @preg_match("/Microsoft|WebSTAR|Xitami/", getenv("SERVER_SOFTWARE")) ) ? "Refresh: 0; URL=" : "Location: ";
	header($header_location . append_sid("index.$phpEx", true));
	exit;
}

?>
eol.php

代碼: 選擇全部

<?php

if ( !defined('IN_PHPBB') )
{
	die("Hacking attempt");
	exit;
}

include($phpbb_root_path . 'rpg/function_rpg.'.$phpEx);
include($phpbb_root_path . 'rpg/function_eol.'.$phpEx);

$returnurl = '<br /><br /><a href="rpg.php?action=eol">返回上一頁</a>';

function PosCompare($a, $b)
{
	if ( substr($a, 13) == substr($b, 13) )
	{
		srand((double)microtime()*1000000);
		return rand(0, 1);
	}
	return ( substr($a, 13) > substr($b, 13) ? 1 : -1 );
}

$template->set_filenames(array(
	'menu' => 'rpg_header.tpl',
	'body' => 'rpg_eol.tpl')
);

if ( isset($HTTP_POST_VARS['go2escape']) ) // 離開 EOL
{
	$sql = "update xoops_users set user_money = floor(user_money * 0.8), user_bank = floor(user_bank * 0.8), rpg_eol_data = concat('0', substring(rpg_eol_data, 2, 2), '000000086') where uid = " . intval($userdata['uid']);
	$db->sql_query($sql);
}
if ( isset($HTTP_POST_VARS['go2url']) ) // 設定 EOL 圖檔位置\r
{
	$sql = "update xoops_users set rpg_eol_url = '" . $HTTP_POST_VARS['rpg_eol_url'] . "' where uid = " . intval($userdata['uid']);
	$db->sql_query($sql);
}

// 取得個人資料
$profiledata = get_userdata(intval($userdata['uid']));
$mydata = $profiledata['rpg_eol_data'];
while (strlen($mydata) < 12)
{
	$mydata .= '0';
}
/*
00000000000000000
              === Y 座標
           === X 座標
         == MAP_ID <-- 本來要作更多地圖的....算了
        = 面對方向 0:下 1:左 2:上 3:右\r
      == 使用的代表圖像
     = Action Done
*/
$now_y = intval(substr($mydata, -3));
$now_x = intval(substr($mydata, -6, 3));
$map_id = intval(substr($mydata, -8, 2));
$now_dir = intval(substr($mydata, -9, 1));
$now_icon = substr($mydata, -11, 2);
$now_act = intval(substr($mydata, -12, 1));
$eol_url = $profiledata['rpg_eol_url'];
if ( $eol_url == '') $eol_url = 'images/eol';

if ($map_id == 0 && $now_x == 0 && $now_y == 0)
{
	$now_y = 86;
	$now_dir = 3;
}

// 更換角色\r
if ( isset($HTTP_POST_VARS['change_char']) && isset($HTTP_POST_VARS['char_id']) )
{
	$now_icon = $HTTP_POST_VARS['char_id'];
}

// 陣亡列表\r
$dead_list = '';
if ( isset($HTTP_POST_VARS['go2disp']) )
{
	$sql = 'delete from xoops_pbb_rpg_event where event_class = 5 and event_time <= ' . (time() - 86400 * 3) . ' and uid = ' . $profiledata['uid'];
	$db->sql_query($sql);

	$sql = 'select * from xoops_pbb_rpg_event where event_class = 5 and uid = ' . $profiledata['uid'] . ' order by event_time desc limit 0, 30';
	$result = $db->sql_query($sql);
	if ( $row = $db->sql_fetchrow($result) )
	{
		$i = 1;
		$dead_list = '<table width="100%" cellpadding="3" cellspacing="1" border="0" class="forumline">
		<tr><td align="center" class="catLeft"><b><span class="gen">#</span></b></td>
		<td align="center" class="catLeft"><b><span class="gen">日期</span></b></td>
		<td align="center" class="catLeft"><b><span class="gen">金額</span></b></td>
		<td align="center" class="catLeft"><b><span class="gen">備註</span></b></td></tr>';
		do
		{
			$dead_list .= '<tr>
				<td align="center" class="row3"><span class="gensmall">' . $i . '</span></td>
				<td align="center"><span class="gensmall">' . ($row['event_time'] ? create_date($userdata['user_dateformat'], $row['event_time'], $board_config['board_timezone']) : $lang['Never_last_logon']) . '</span></td>
				<td align="right"><span class="gensmall">' . number_format($row['event_money']) . '</span></td>
				<td><span class="gensmall">' . $row['event_note'] . '</span></td>
				</tr>';
			$i++;
		}
		while ( $row = $db->sql_fetchrow($result) );
		$dead_list .= '</table>';
	}
}

// 位置列表\r
if ( isset($HTTP_POST_VARS['go2position']) )
{
	$allpos = array();
	$sql = "select uname, rpg_level, rpg_eol_data from xoops_users where rpg_eol_data is not null and right(rpg_eol_data, 6) <> '000086' and uid <> " . $profiledata['uid'];
	$result = $db->sql_query($sql);
	if ( $row = $db->sql_fetchrow($result) )
	{
		do
		{
			if ( intval(substr($row['rpg_eol_data'], -12, 1)) == 0 ) $allpos[] = sprintf("%05d%02d%03d%03d%10s", $row['rpg_level'], substr($row['rpg_eol_data'], -11, 2), substr($row['rpg_eol_data'], -6, 3), substr($row['rpg_eol_data'], -3), '') . $row['uname'];
		}
		while ( $row = $db->sql_fetchrow($result) );
	}
	$sql = "select npc_id, npc_name, rpg_level, now_icon, now_x, now_y, rpg_cur_hp, rpg_max_hp, generate_time from xoops_pbb_rpg_npc";
	$result = $db->sql_query($sql);
	if ( $row = $db->sql_fetchrow($result) )
	{
		do
		{
			if ( $row['npc_name'] == '' )
			{
				$live_time = $row['generate_time'] - ($row['rpg_cur_hp'] == $row['rpg_max_hp'] ? time() - 21600 : time() - 43200);
				$live_time = sprintf("/ %02d:%02d:%02d", floor($live_time / 3600), floor( ($live_time % 3600) / 60 ), $live_time % 60);
			}
			else
			{
				$live_time = '';
			}
			$allpos[] = sprintf("%05d%02d%03d%03d%10s", $row['rpg_level'], $row['now_icon'], $row['now_x'], $row['now_y'], $live_time). ($row['npc_name'] == '' ? '路人' . $row['npc_id'] : $row['npc_name']);
		}
		while ( $row = $db->sql_fetchrow($result) );
		unset($live_time);
	}
	if ( count($allpos) > 0 )
	{
		usort($allpos, PosCompare);
		$i = 1;
		$dead_list = '<table width="50%" cellpadding="0" cellspacing="0" border="0" class="forumline">
				<tr>
				<td align="center" class="catLeft"><b><span class="gen">#</span></b></td>
				<td align="center" class="catLeft"><b><span class="gen">對手</span></b></td>
				<td align="center" class="catLeft"><b><span class="gen">座標</span></b></td>
				<td align="center" class="catLeft"><b><span class="gen">圖像</span></b></td>
				</tr>';
		for ( $i=0; $i < count($allpos) - 1; $i++ )
		{
			$dead_list .= '<tr height="32">
							<td rowspan="2" align="center" class="row3"><span class="gensmall">' . ($i + 1) . '</span></td>
							<td rowspan="2"><span class="gensmall"> ' . substr($allpos[$i], 23) . '</span></td>
							<td rowspan="2"><span class="gensmall"> (' . intval(substr($allpos[$i], 7, 3)) . ', ' . intval(substr($allpos[$i], 10, 3)) . ')' . ' LV: ' . intval(substr($allpos[$i], 0, 5)) . ' ' . substr($allpos[$i], 13, 10) . '</span></td>
							<td align="center"><img src="' . $eol_url . '/npc/npc' . substr($allpos[$i], 5, 2) . '.00.gif"></td>
							</tr>
							<tr><td align="center"><img src="' . $eol_url . '/npc/npc' . substr($allpos[$i], 5, 2) . '.01.gif"></td></tr>';
		}
		$dead_list .= '</table>';
	}
	$dead_list = '您現在的座標: (' . $now_x . ', ' . $now_y . ')<br />' . $dead_list;
	unset($allpos);
}

// 取得地圖資訊,取得欲繪出的左上角座標
if ( intval($HTTP_POST_VARS['next_act']) == 1 && isset($HTTP_POST_VARS['next_x']) && isset($HTTP_POST_VARS['next_y']) )
{
	$start_x = intval($HTTP_POST_VARS['next_x']) - 10;
	$start_y = intval($HTTP_POST_VARS['next_y']) - 10;
}
else
{
	$start_x = $now_x - 10;
	$start_y = $now_y - 10;
}
$sql = "select max(map_x) as max_x, max(map_y) as max_y from xoops_pbb_rpg_eol where map_id = $map_id";
$result = $db->sql_query($sql);
if ( $row = $db->sql_fetchrow($result) )
{
	if ($start_x < 0) $start_x = 0;
	if ($start_y < 0) $start_y = 0;
	if ($start_x > $row['max_x'] - 19) $start_x = $row['max_x'] - 19;
	if ($start_y > $row['max_y'] - 19) $start_y = $row['max_y'] - 19;
}

// 判斷按了什麼按鈕,以及取出最大移動範圍
$button_click = 0;
$max_point = 1;
$need_target = false;
if ( isset($HTTP_POST_VARS['go2move']) ) // 移動
{
	$button_click = 1;
	$max_point = GetMaxPoint($profiledata['uid'], 1);
	$other_info = "移動最大有效距離: $max_point";
}
else if ( isset($HTTP_POST_VARS['go2attack']) ) // 攻擊
{
	$button_click = 2;
	$other_info = "請選擇攻擊目標(只能攻擊週圍的人)";
	$need_target = true;
}
else if ( isset($HTTP_POST_VARS['go2skill']) ) // 技能\r
{
	$button_click = 3;
	$max_point = GetMaxPoint($profiledata['uid'], intval($HTTP_POST_VARS['sp_skill']));
	if ( (intval($HTTP_POST_VARS['sp_skill']) >= 112 && intval($HTTP_POST_VARS['sp_skill']) <= 114) ||
	     (intval($HTTP_POST_VARS['sp_skill']) >= 166 && intval($HTTP_POST_VARS['sp_skill']) <= 170) ||
	      intval($HTTP_POST_VARS['sp_skill']) == 172 )
	{
		$need_target = true;
		$other_info = "使用技能: " . GetSkillName(intval($HTTP_POST_VARS['sp_skill'])) . ($need_target ? "  技能有效範圍: $max_point" : "");
	}
}

$other_info .= ($other_info == "" ? "" : "  ") . "您現在的座標: ($now_x, $now_y)";
if ( $now_act > 0 ) $other_info .= "  技能有效回合: $now_act";

// 處理動作
if ( ( isset($HTTP_POST_VARS['next_x']) || isset($HTTP_POST_VARS['next_y']) || isset($HTTP_POST_VARS['next_act']) ||
     ( isset($HTTP_POST_VARS['go2skill']) && ! $need_target ) )
     && ( intval($HTTP_POST_VARS['next_x']) != $now_x || intval($HTTP_POST_VARS['next_y']) != $now_y ) )
{
	if ( ( intval($HTTP_POST_VARS['next_act']) > 1 ) &&
		( ($now_y == 86 && $now_x == 0) ||
		  (intval($HTTP_POST_VARS['next_x']) == 0 && intval($HTTP_POST_VARS['next_y']) == 86) ) )
	{
		$other_info = '不能在原點或是針對原點作出移動以外的動作!!';
	}
	else
	{
		if ( intval($HTTP_POST_VARS['next_act']) != 1 )
		{
			if ( CheckRefresh(9, intval($userdata['uid']), 10) )
			{
				message_die(GENERAL_MESSAGE, '為了避免系統負荷過重,請間隔 10 秒再進行動作!!' . $returnurl);
			}
		}
		if ( $now_act > 0 ) $now_act--; // 目前隱身的回合
		$other_info = SubmitNext(intval($HTTP_POST_VARS['next_x']), intval($HTTP_POST_VARS['next_y']), (isset($HTTP_POST_VARS['go2skill']) && ! $need_target ? 4 : intval($HTTP_POST_VARS['next_act'])), intval($HTTP_POST_VARS['sp_skill']));
		if ( $other_info == 'xxxxx' )
		{
			message_die(GENERAL_MESSAGE, '您已經陣亡了!!' . $returnurl);
		}
		$profiledata = get_userdata(intval($userdata['uid']));
	}
}

// 頭頂那一格能不能通過,用來決定是否畫貓爪\r
$CanPass = true;
if ( $button_click == 1 )
{
	$sql = "select * from xoops_pbb_rpg_eol where map_id = $map_id and map_x = $now_x and map_y = $now_y - 1 and can_not_pass = 1";
	$result = $db->sql_query($sql);
	if ( $row = $db->sql_fetchrow($result) )
	{
		$CanPass = false;
	}
}

// 取出在附近的人\r
$AroundNPC = array();
$AroundPro = array();
$sql = "select uname, rpg_eol_data, rpg_level, rpg_cur_hp, rpg_max_hp, rpg_cur_mp, rpg_max_mp, rpg_attack, rpg_defense, rpg_magic, rpg_speed  from xoops_users where rpg_eol_data is not null and left(right(rpg_eol_data, 8), 2) = $map_id and left(right(rpg_eol_data, 6), 3) >= $start_x and left(right(rpg_eol_data, 6), 3) <= $start_x + 19 and right(rpg_eol_data, 3) >= $start_y and right(rpg_eol_data, 3) <= $start_y + 19 and uid <> " . $profiledata['uid'];
$result = $db->sql_query($sql);
if ( $row = $db->sql_fetchrow($result) )
{
	do
	{
		// 隱身的人不顯示
		if ( intval(substr($row['rpg_eol_data'], -12, 1)) == 0 || (intval(substr($row['rpg_eol_data'], -12, 1)) != 0 &&
			(intval(substr($row['rpg_eol_data'], -6, 3)) == $now_x && abs(intval(substr($row['rpg_eol_data'], -3)) - $now_y) == 1) ||
			(intval(substr($row['rpg_eol_data'], -3)) == $now_y && abs(intval(substr($row['rpg_eol_data'], -6, 3)) - $now_x) == 1)) )
		{
			$AroundNPC['x' . intval(substr($row['rpg_eol_data'], -6, 3)) . 'y' . intval(substr($row['rpg_eol_data'], -3))] = $row['rpg_eol_data'];
			$AroundPro['x' . intval(substr($row['rpg_eol_data'], -6, 3)) . 'y' . intval(substr($row['rpg_eol_data'], -3))] = $row['uname'] . '
等 級: ' . $row['rpg_level'] . '
H P: ' . $row['rpg_cur_hp'] . ' / ' . $row['rpg_max_hp'] . '
M P: ' . $row['rpg_cur_mp'] . ' / ' . $row['rpg_max_mp'] . '
攻擊力: ' . $row['rpg_attack'] . '
防禦力: ' . $row['rpg_defense'] . '
魔 力: ' . $row['rpg_magic'] . '
速 度: ' . $row['rpg_speed'];
		}
	}
	while ( $row = $db->sql_fetchrow($result) );
}

// NPC
$sql = "select * from xoops_pbb_rpg_npc where map_id = $map_id and now_x >= $start_x and now_x <= $start_x + 19 and now_y >= $start_y and now_y <= $start_y + 19";
$result = $db->sql_query($sql);
if ( $row = $db->sql_fetchrow($result) )
{
	$clear_npc = false;
	$have_mylv = false;
	do
	{
		$live_time = $row['generate_time'] - ( time() - ($row['rpg_cur_hp'] == $row['rpg_max_hp'] ? 21600 : 43200) );
		$live_time = ($row['npc_name'] == '' ? '
出 場: ' . sprintf("%02d:%02d:%02d", floor($live_time / 3600), floor( ($live_time % 3600) / 60 ), $live_time % 60) : '');
		$AroundNPC['x' . $row['now_x'] . 'y' . $row['now_y']] = 
		sprintf("%01d%02d%01d%02d%03d%03d", 0, $row['now_icon'], $row['now_dir'], $row['map_id'], $row['now_x'], $row['now_y']);
		$AroundPro['x' . $row['now_x'] . 'y' . $row['now_y']] = ($row['npc_name'] == '' ? '路人' . $row['npc_id'] : $row['npc_name']) . '
等 級: ' . $row['rpg_level'] . '
H P: ' . $row['rpg_cur_hp'] . ' / ' . $row['rpg_max_hp'] . '
' . ($row['npc_name'] != '' ? 'M P: ' . $row['rpg_cur_mp'] . ' / ' . $row['rpg_max_mp'] . '
' : '') . '攻擊力: ' . $row['rpg_attack'] . '
防禦力: ' . $row['rpg_defense'] . '
魔 力: ' . $row['rpg_magic'] . '
速 度: ' . $row['rpg_speed'] . $live_time;
		if ( ($row['rpg_cur_hp'] == $row['rpg_max_hp'] && $row['generate_time'] <= time() - 21600) || $row['generate_time'] <= time() - 43200 ) $clear_npc = true;
		if ( $row['rpg_level'] == $profiledata['rpg_level'] + 5 ) $have_mylv = true;
	}
	while ( $row = $db->sql_fetchrow($result) );
	unset($live_time);
	if ( $clear_npc || !$have_mylv ) GenerateNPC();
	unset($clear_npc);
	unset($have_mylv);
}

// 產生資料頁面\r
$sql = "select * from xoops_pbb_rpg_eol where map_id = $map_id and map_x >= $start_x and map_x <= $start_x + 19 and map_y >= $start_y and map_y <= $start_y + 19 order by map_y, map_x";
$map_data = '';
$result = $db->sql_query($sql);
if ( $row = $db->sql_fetchrow($result) )
{
	$map_data = '<tr height="32">';
	$old_y = $row['map_y'];
	do
	{
		if ( $row['map_y'] != $old_y ) // 換行判斷\r
		{
			$old_y = $row['map_y'];
			$map_data .= '</tr><tr height="32">';
		}
		$map_data .= '<td width="32" background="' . $eol_url . '/eol' . $row['tile_id'] . '.gif"';
		if (($button_click == 1) && (! $AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']]) && (abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point && !$row['can_not_pass'])
		{
			// 可移動的範圍
			// $style_content = 'cursor=\'hand\'; border-Left=\'1 solid blue\';';
			// $style_content = 'cursor=\'crosshair\';';
			$style_content = 'cursor=\'hand\';';
			$map_data .= ' style="' . $style_content . '" onclick="Click4Mouse(1, ' . $row['map_x'] . ', ' . $row['map_y'] . ')" ';
		}

		if ($now_x == $row['map_x'] && $now_y - 1 == $row['map_y'] )
		{
			// 目前格子所在的上一格,畫頭頂,順便判斷有沒有其他人或是移動的貓爪\r
			if ( $AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']] )
			{
				// 有人\r
				$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -9, 1));
				$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -11, 2);
				$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $now_icon . '.' . $now_dir . '0.gif" alt="' . $AroundPro['x' . $row['map_x'] . 'y' . $row['map_y']] . '" style="background-image: url(\'' . $eol_url . '/npc/' . ($need_target ? 'x' : 'n')  . 'pc' . $npc_icon . '.' . $npc_dir . '1.gif\'); ';
				if ( $need_target )
				{
					// 有作其它動作,例如攻擊、魔法,要畫邊線
					$map_data .= 'cursor=\'crosshair\';" onclick="Click4Mouse(' .
					$button_click . ', ' . $row['map_x'] . ', ' . $row['map_y'] . ')';
				}
				$map_data .= '"></td>';
			}
			else if ( $button_click == 1 )
			{
				// 沒人,畫貓爪\r
				$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $now_icon . '.' . $now_dir . '0.gif" ' . ($CanPass ? 'style="background-image: url(\'images/eol.gif\')"' : '') . '></td>';
			}
			else
			{
				// 什麼都沒有
				$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $now_icon . '.' . $now_dir . '0.gif"></td>';
			}
		}
		else if ($now_x == $row['map_x'] && $now_y == $row['map_y'] )
		{
			// 自己本身這一格\r
			if ($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)])
			{
				// 剛好站在別人的頭頂
				$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -9, 1));
				$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -11, 2);
				$map_data .= ' ><img src="' . $eol_url . '/npc/' . ($need_target ? 'x' : 'n')  . 'pc' . $npc_icon . '.' . $npc_dir . '0.gif" alt="' . $profiledata['uname'] . '
等 級: ' . $profiledata['rpg_level'] . '
H P: ' . $profiledata['rpg_cur_hp'] . ' / ' . $profiledata['rpg_max_hp'] . '
M P: ' . $profiledata['rpg_cur_mp'] . ' / ' . $profiledata['rpg_max_mp'] . '
攻擊力: ' . $profiledata['rpg_attack'] . '
防禦力: ' . $profiledata['rpg_defense'] . '
魔 力: ' . $profiledata['rpg_magic'] . '
速 度: ' . $profiledata['rpg_speed'] . '" style="background-image: url(\'' . $eol_url . '/npc/npc' . $now_icon . '.' . $now_dir . '1.gif\')"></td>';
			}
			else
			{
				$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $now_icon . '.' . $now_dir . '1.gif" alt="' . $profiledata['uname'] . '
等 級: ' . $profiledata['rpg_level'] . '
H P: ' . $profiledata['rpg_cur_hp'] . ' / ' . $profiledata['rpg_max_hp'] . '
M P: ' . $profiledata['rpg_cur_mp'] . ' / ' . $profiledata['rpg_max_mp'] . '
攻擊力: ' . $profiledata['rpg_attack'] . '
防禦力: ' . $profiledata['rpg_defense'] . '
魔 力: ' . $profiledata['rpg_magic'] . '
速 度: ' . $profiledata['rpg_speed'] . '"></td>';
			}
		}
		else if (($button_click == 1) && (! $AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']]) && (! $AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)]) && (abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point && !$row['can_not_pass'])
		{
			// 這一格沒人,又有按移動
			$map_data .= '><img src="images/eol.gif"></td>';
		}
		else if ($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']]) // 這一格有人\r
		{
			if ($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)])
			{
				// 剛好站在某個人的頭上
				$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -9, 1));
				$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -11, 2);
				// 先畫這個人的頭\r
				$map_data .= ' ><img src="' . $eol_url . '/npc/' . ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] + 1 - $now_y)) <= $max_point) ? 'x' : 'n') . 'pc' . $npc_icon . '.' . $npc_dir . '0.gif" alt="' . $AroundPro['x' . $row['map_x'] . 'y' . $row['map_y']] . '" style="background-image: url(\'' . $eol_url . '/npc/' . ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point) ? 'x' : 'n') . 'pc';
				// 再畫這個人的身體
				$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -9, 1));
				$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -11, 2);
				$map_data .= $npc_icon . '.' . $npc_dir . '1.gif\')';
				// 有作其它動作,例如攻擊、魔法,而且在範圍內,要畫邊線
				if ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point) ) $map_data .= '; cursor=\'crosshair\';" onclick="Click4Mouse(' . $button_click . ', ' . $row['map_x'] . ', ' . $row['map_y'] . ')';
			}
			else
			{
				$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -9, 1));
				$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . $row['map_y']], -11, 2);
				$map_data .= ' ><img src="' . $eol_url . '/npc/' . ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point) ? 'x' : 'n')  . 'pc' . $npc_icon . '.' . $npc_dir . '1.gif" alt="' . $AroundPro['x' . $row['map_x'] . 'y' . $row['map_y']];
				// 有作其它動作,例如攻擊、魔法,而且在範圍內,要畫邊線
				if ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y)) <= $max_point) ) $map_data .= '"; style="cursor=\'crosshair\';" onclick="Click4Mouse(' . $button_click . ', ' . $row['map_x'] . ', ' . $row['map_y'] . ')';
			}
			$map_data .= '"></td>';
		}
		else if ($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1) ])
		{
			// 這一格是某人的頭頂
			$npc_dir = intval(substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -9, 1));
			$npc_icon = substr($AroundNPC['x' . $row['map_x'] . 'y' . ($row['map_y'] + 1)], -11, 2);
			if (($button_click == 1))
			{
				// 如果剛好有按移動,而且在範圍內,要把貓爪擋掉
				if ( abs($row['map_x'] - $now_x) + abs($row['map_y'] - $now_y) <= $max_point )
				{
					$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $npc_icon . '.' . $npc_dir . '0.gif" style="background-image: url(\'images/eol.gif\')"></td>';
				}
				else
				{
					$map_data .= ' ><img src="' . $eol_url . '/npc/npc' . $npc_icon . '.' . $npc_dir . '0.gif"></td>';
				}
			}
			else
			{
				$map_data .= ' ><img src="' . $eol_url . '/npc/' . ( ($need_target) && ((abs($row['map_x'] - $now_x) + abs($row['map_y'] + 1 - $now_y)) <= $max_point) ? 'x' : 'n') . 'pc' . $npc_icon . '.' . $npc_dir . '0.gif"></td>';
			}
		}
		else
		{
			$map_data .= '> </td>';
		}
	}
	while ( $row = $db->sql_fetchrow($result) );
	$map_data .= '</tr>';
}

if ( $mydata != sprintf("%01d%02d%01d%02d%03d%03d", $now_act, $now_icon, $now_dir, $map_id, $now_x, $now_y) )
{
	$mydata = sprintf("%01d%02d%01d%02d%03d%03d", $now_act, $now_icon, $now_dir, $map_id, $now_x, $now_y);
	$sql = "update xoops_users set rpg_eol_data = '$mydata' where uid = " . $profiledata['uid'];
	$db->sql_query($sql);
}

$button_list = GetButtonList($profiledata['uid'], intval($HTTP_POST_VARS['sp_skill']));

if ( $need_target || $button_click == 1 ) $button_list .= '<input type="hidden" name="next_x" value="' . $now_x . '"> <input type="hidden" name="next_y" value="' . $now_y . '"> <input type="hidden" name="next_act" value="' . $button_click . '">';

// 產生資料頁面\r
$page_title = "水怪大陸 RPG 首頁";
include($phpbb_root_path . 'includes/page_header.'.$phpEx);

$template->assign_vars(array(
	'USERNAME' => $profiledata['uname'],
	'AVATAR_IMG' => GetAvatar($profiledata),
	'EOL_MAP' => $map_data,
	'DEAD_LIST' => $dead_list,
	'RESULT_MSG' => $result_msg,
	'BUTTON_CONTROL' => $button_list,
	'OTHER_INFORMATION' => $other_info,
	'RPG_EOL_URL' => $profiledata['rpg_eol_url'],
	'L_NOWMENU' => '蘿莉帝國刑場') );

$template->pparse('menu');
$template->pparse('body');

include($phpbb_root_path . 'includes/page_tail.'.$phpEx);

unset($AroundNPC);
unset($AroundPro);
unset($button_list);
unset($need_target);
unset($button_click);
unset($sql);
unset($row);
unset($result);
unset($mydata);
unset($now_y);
unset($now_x);
unset($map_id);
unset($now_dir);
unset($now_icon);
unset($now_act);
unset($eol_url);
unset($dead_list);
unset($i);
unset($start_x);
unset($start_y);
unset($max_point);
unset($other_info);
unset($map_data);
\nunset($npc_icon);
unset($npc_dir);

?>
小弟已經爬了很多天的文了,但沒有發現相同的問題,所以只好貼出,請各位高手幫幫忙,如果還要貼出其他程式碼,請告知我,謝謝,感激不盡。[/code]
依夢兒
竹貓忠實會員
竹貓忠實會員
文章: 2013
註冊時間: 2002-11-20 00:07

文章 依夢兒 »

路人等級多少啊?
你的等級又多少呢?

如果路人等級很強,你很肉腳,你當然傷不了他,而且會被 k 的滿頭包。
有任何關於 phpBB 或是架站的問題,請在論壇上公開發表出來,大家一起討論。
請不要丟私人訊息問我,因為私訊是用來聊私事的。
這樣作對於解決您的問題一點幫助也沒有,也很沒有效率,小弟我一概謝絕。



搜尋是一種美德,在發問之前,請多加利用頂端的文章搜尋功能,搜尋可能的關鍵字。
確定您想問的問題找不到答案後,再發問。
diber
星球普通子民
星球普通子民
文章: 6
註冊時間: 2003-12-25 09:41

文章 diber »

呵呵,高十級的不能pk,這個我了,但我是砍了人家,結果有損傷點數,但路人血都沒變,我反而一直失血,呵呵,路人變無敵了,這怎麼練功。
依夢兒
竹貓忠實會員
竹貓忠實會員
文章: 2013
註冊時間: 2002-11-20 00:07

文章 依夢兒 »

diber 寫:呵呵,高十級的不能pk,這個我了
不是喲。
等級十級的保護限制是指你(玩家)不能夠傷害等級比你小十級以下的玩家或是路人。
但是等級比你高的玩家或是路人,不管他等級有多高,你一樣可以砍;至於砍的到砍不到那又是另一回事了。

diber 寫:但我是砍了人家,結果有損傷點數,但路人血都沒變
你意思是,你砍路人的時候,畫面會顯示路人遭到 x 點傷害,但是路人的血沒降嗎?
如果是這樣,就是有問題了,可能是你沒裝好,或是不小心改到什麼地方啦~
有任何關於 phpBB 或是架站的問題,請在論壇上公開發表出來,大家一起討論。
請不要丟私人訊息問我,因為私訊是用來聊私事的。
這樣作對於解決您的問題一點幫助也沒有,也很沒有效率,小弟我一概謝絕。



搜尋是一種美德,在發問之前,請多加利用頂端的文章搜尋功能,搜尋可能的關鍵字。
確定您想問的問題找不到答案後,再發問。
吉川拓也
竹貓忠實會員
竹貓忠實會員
文章: 1215
註冊時間: 2003-02-09 18:24
來自: [ G.I.T ]
聯繫:

文章 吉川拓也 »

目前水怪還有個問題就是路人會跟玩家重疊 ..
重疊也就算了 . 重點是攻擊路人變成砍玩家= =||
這部分就有點怪異了 .. (難道路人特殊技能 : 合體 ..)
善用 搜尋 可以解決您 90% 的問題
頭腦清晰,選擇正確。 (╯▔︹▔)╯~╘═╛
diber
星球普通子民
星球普通子民
文章: 6
註冊時間: 2003-12-25 09:41

文章 diber »

呵呵,就是砍了畫面會有點數損失,但路人血就是不減,難道路人有再生功能,所以現在我站上的會員只能互砍,還好路人不會主動攻擊人,要不然,真不知如何打。我的rpg水怪目前只遇到這個問題,所以也不知到底有沒有裝好,至於改的地方,也沒改什麼地方,而且也是人家改的,所以根本也不知要改什麼。
悲情小爸爸
星球普通子民
星球普通子民
文章: 15
註冊時間: 2003-12-08 11:27

文章 悲情小爸爸 »

吉川拓也 寫:目前水怪還有個問題就是路人會跟玩家重疊 ..
重疊也就算了 . 重點是攻擊路人變成砍玩家= =||
這部分就有點怪異了 .. (難道路人特殊技能 : 合體 ..)

路人跟路人也會重疊~。
而老鼠放上去就只會顯示上面那個路人的資料,
我家有不少猴子就這樣被下面那個強者KO了,呵呵~。

我站上的會員都在瘋狂互砍。
用本來的版本有個問題,就是看目前HP有點麻煩,很多人被人砍倒了還不知道,呵呵。
所以我在這裡弄了點手腳(挪用了「美化水怪資料顯示」的mod)…\r
圖檔

這樣的話,被暗算了都可以立刻知道~。

假如覺得還有用的話可以把code貼出來~。
反正不是甚麼好東西,哈哈。
不過玩PK時很實用就是了~。
吉川拓也
竹貓忠實會員
竹貓忠實會員
文章: 1215
註冊時間: 2003-02-09 18:24
來自: [ G.I.T ]
聯繫:

文章 吉川拓也 »

diber 寫:呵呵,就是砍了畫面會有點數損失,但路人血就是不減,難道路人有再生功能,所以現在我站上的會員只能互砍,還好路人不會主動攻擊人,要不然,真不知如何打。我的rpg水怪目前只遇到這個問題,所以也不知到底有沒有裝好,至於改的地方,也沒改什麼地方,而且也是人家改的,所以根本也不知要改什麼。
我之前是把NPC部分砍掉 . 在執行一次SQL (NPC部分) ..
結果解決了不損HP情形 . 但是卻換來路人沒HP就躲起來重疊= =||
天啊 . 路人也有AI ??
最後由 吉川拓也 於 2003-12-29 14:51 編輯,總共編輯了 1 次。
善用 搜尋 可以解決您 90% 的問題
頭腦清晰,選擇正確。 (╯▔︹▔)╯~╘═╛
diber
星球普通子民
星球普通子民
文章: 6
註冊時間: 2003-12-25 09:41

文章 diber »

唉,我再執行一次sql,還是一樣,不死的路人,看來還是讓會員互砍了。
不過樓上的那位小爸爸,方便把那個code貼出來嗎,那個很實用的說,可以直接看到血,要不然,有時候,數學不夠好,減錯的話,很容易去賣鴨蛋的說,謝謝。
吉川拓也
竹貓忠實會員
竹貓忠實會員
文章: 1215
註冊時間: 2003-02-09 18:24
來自: [ G.I.T ]
聯繫:

文章 吉川拓也 »

diber 寫:唉,我再執行一次sql,還是一樣,不死的路人,看來還是讓會員互砍了。
不過樓上的那位小爸爸,方便把那個code貼出來嗎,那個很實用的說,可以直接看到血,要不然,有時候,數學不夠好,減錯的話,很容易去賣鴨蛋的說,謝謝。
別洩氣 . 來這裡下載最新版本的eol
http://www.watermonster.org/phpBB/download/rpg_src/
覆蓋過去看看 ~
善用 搜尋 可以解決您 90% 的問題
頭腦清晰,選擇正確。 (╯▔︹▔)╯~╘═╛
依夢兒
竹貓忠實會員
竹貓忠實會員
文章: 2013
註冊時間: 2002-11-20 00:07

文章 依夢兒 »

吉川拓也 寫:目前水怪還有個問題就是路人會跟玩家重疊 ..
重疊也就算了 . 重點是攻擊路人變成砍玩家= =||
這一點作者 paikang 有提過,玩家和玩家或是玩家和路人可能會重疊在一起,
所以你砍到的路人不一定是路人,而是玩家。
同理,你砍到的玩家不一定是玩家,而是另一位玩家(或是路人)。

因為 paikang 已經終止水怪的開發計畫,所以這個 bug 只能讓有辦法的人去解決吧。

悲情小爸爸 寫:所以我在這裡弄了點手腳(挪用了「美化水怪資料顯示」的mod)…
這個蠻實用的喲.... :-P

吉川拓也 寫:我之前是把NPC部分砍掉 . 在執行一次SQL (NPC部分) ..
結果解決了不損HP情形 . 蛋市卻換來路人沒HP就躲起來重疊= =||
天啊 . 路人也有AI ??
路人血變少的確會逃跑,程式有設計路人逃跑機制,好像是在 functions_eol.php 內。
不過應該還不至於全部龜縮在一個地方重疊,就算真的有,也只是恰巧讓你碰上罷了。 ;-)
有任何關於 phpBB 或是架站的問題,請在論壇上公開發表出來,大家一起討論。
請不要丟私人訊息問我,因為私訊是用來聊私事的。
這樣作對於解決您的問題一點幫助也沒有,也很沒有效率,小弟我一概謝絕。



搜尋是一種美德,在發問之前,請多加利用頂端的文章搜尋功能,搜尋可能的關鍵字。
確定您想問的問題找不到答案後,再發問。
悲情小爸爸
星球普通子民
星球普通子民
文章: 15
註冊時間: 2003-12-08 11:27

文章 悲情小爸爸 »

#
#-----[ OPEN ]---------------------------------------------
#
\nrpg/eol.php
#
#-----[ 找尋 ]---------------------------------------------
#
$template->assign_vars(array(
'USERNAME' => $profiledata['username'],
'AVATAR_IMG' => GetAvatar($profiledata),
#
#-----[ 在後面加入 ]---------------------------------------------
#
'RPG_LEVEL' => $profiledata['rpg_level'],
'RPG_CUR_HP' => $profiledata['rpg_cur_hp'],
'RPG_MAX_HP' => $profiledata['rpg_max_hp'],
'RPG_CUR_MP' => $profiledata['rpg_cur_mp'],
'RPG_MAX_MP' => $profiledata['rpg_max_mp'],
#
#-----[ OPEN ]---------------------------------------------
#
templates/subSilver/rpg_eol.tpl
#
#-----[ 找尋 ]---------------------------------------------
#
<font color="red"><b>{RESULT_MSG}</b></font></span>
#
#-----[ 在後面加入 ]---------------------------------------------
#
<br /><span class="postdetails">等級: <font color=#FF8000>{RPG_LEVEL}</font>
<span class="postdetails">體力: <font color=#FF8000>{RPG_CUR_HP} / {RPG_MAX_HP}</font>
<span class="postdetails">魔攻: <font color=#FF8000>{RPG_CUR_MP} / {RPG_MAX_MP}</font>



另外,有會員反映過在下面也加一列控制鍵,那就…\r
同樣在rpg_eol.tpl

#
#-----[ 找尋 ]---------------------------------------------
#
<td width="100%"><table class="forumline" cellpadding="0" cellspacing="0" border="0">{EOL_MAP}</table></td>
</tr>
</table>
</td>
</tr>
</table>
#
#-----[ 換成這個 ]---------------------------------------------
#
<td width="100%"><table class="forumline" cellpadding="0" cellspacing="0" border="0">{EOL_MAP}</table></br>
<form action="rpg.php#listmap" method="post">
<input type="hidden" name="action" value="eol"><a name="listmap"></a>{BUTTON_CONTROL}<br />
<br />
<span class="postdetails">等級: <font color=#FF8000>{RPG_LEVEL}</font>
<span class="postdetails">體力: <font color=#FF8000>{RPG_CUR_HP} / {RPG_MAX_HP}</font>
<span class="postdetails">魔攻: <font color=#FF8000>{RPG_CUR_MP} / {RPG_MAX_MP}</font>
<td width="150" align="left" valign="top" class="{profiledata.ROW_CLASS}">{profiledata.POSTER_RPG}</span><br /></tr>
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
diber
星球普通子民
星球普通子民
文章: 6
註冊時間: 2003-12-25 09:41

文章 diber »

感謝各路高手,熱情幫忙,讓小弟的功力又可以大進一步,小弟回去再試試,搞不好,那天路人良心發現,還是不小心打到路人的罩門,要不然,路人現在真的跟背景沒兩樣。
悲情小爸爸
星球普通子民
星球普通子民
文章: 15
註冊時間: 2003-12-08 11:27

文章 悲情小爸爸 »

:lol:
路人的bug 暫時沒有詳細看。
不過我倒覺得生在(0,86)的路人更加討厭…
:evil:

最近迷上水怪RPG,剛剛作了幾個更新,不知道各位大大有沒有用?

圖檔

1) 有猴子說NPC就像沙包一樣,所以提高了NPC反擊傷害值。上圖可見反擊傷害是574點~。

2) 又有猴子說NPC掉了武器一定要先賣掉才能打,所以設定只會掉道具。

3) 為鼓勵玩家自相殘殺(!?),取消PK掉item制\r

4) 發現原來PK會大幅增加金錢…呵呵,現在當然減掉了~。 努力灌水存錢吧~!

5) 如上圖示,中招排版更整齊~。而且改了部份出招文字,令猴子們覺得有趣點~。

6) 如上圖示,開放了幾個原版不能使用的items。 (本名:水怪的便便、翼翼的羽毛、xx的祝福)


除了(6) 以外,全部修改都在 rpg/function_eol.php 裡面。
看過便知道要修改其實非常簡單,因為原碼上都加了說明文字。
;-)
懶去找的話我可以把以上的修正貼出來~。
如何~?
GeniusKiKi
竹貓忠實會員
竹貓忠實會員
文章: 1086
註冊時間: 2003-10-28 14:50

文章 GeniusKiKi »

喵嗚
感謝大大提供以上修改訊息\r

不過最後一篇的內容
我看過了原始檔案
大略知道要修改哪些地方\r
不過實際修改方法卻不太清楚
可以請大大有空的時候分享一下嗎
非常感謝~ ^^
再也不當爛好人...
好人是小白轉型成大白的墊腳石...
主題已鎖定

回到「外掛問題討論」