開啟 wog_act.php 寫:尋找覆蓋為
- 代碼: 選擇全部
case "rebirth":
include("./class/wog_act_rebirth.php");
switch ($_POST["act"])
{
case "rebirth_confirm":
rebirth_confirm($HTTP_COOKIE_VARS["wog_cookie"]);
break;
case "rebirth":
rebirth($HTTP_COOKIE_VARS["wog_cookie"]);
break;
}
break;
- 代碼: 選擇全部
case "rebirth":
include("./class/wog_act_rebirth.php");
[color=red]$wog_act_class = new wog_act_rebirth;[/color]
switch ($_POST["act"])
{
case "rebirth_confirm":
[color=red]$wog_act_class->[/color]rebirth_confirm($HTTP_COOKIE_VARS["wog_cookie"]);
break;
case "rebirth":
[color=red]$wog_act_class->[/color]rebirth($HTTP_COOKIE_VARS["wog_cookie"]);
break;
}
break;
尋找,刪除
- 代碼: 選擇全部
//########################## rebirth_confirm begin #################
function rebirth_confirm($user_id)
{
$wog_act_class = new wog_act_rebirth;
$wog_act_class->rebirth_confirm($user_id);
}
//########################## rebirth begin #################
function rebirth($user_id)
{
$wog_act_class = new wog_act_rebirth;
$wog_act_class->rebirth($user_id);
}
開啟 /class/wog_act_rebirth.php 寫:尋找覆蓋為
- 代碼: 選擇全部
global $DB_site,$_POST,$lang,$wog_arry;
- 代碼: 選擇全部
global $DB_site,$_POST,$lang,$wog_arry[color=red],$wog_act_class[/color];
尋找下方,加入
- 代碼: 選擇全部
alertWindowMsg("您沒有選擇新的屬性!","javascript:history.go(-1)");
- 代碼: 選擇全部
[color=red]}elseif(!isset($_POST[b]) || empty($_POST[b])){
alertWindowMsg("您沒有選擇出生地!","javascript:history.go(-1)");[/color]
尋找覆蓋為
- 代碼: 選擇全部
$d=$DB_site->query_first("select a_id,d_body_id,d_head_id,d_hand_id,d_foot_id,d_item_id from wog_player where p_id=".$user_id."");
- 代碼: 選擇全部
$d=$DB_site->query_first("select a_id,d_body_id,d_head_id,d_hand_id,d_foot_id,d_item_id[color=red],p_bag[/color] from wog_player where p_id=".$user_id."");
尋找覆蓋為
- 代碼: 選擇全部
switch($i)
{
case "0":
$a_id="a_id";
break;
case "1":
$a_id="d_body_id";
break;
case "2":
$a_id="d_head_id";
break;
case "3":
$a_id="d_hand_id";
break;
case "4":
$a_id="d_foot_id";
break;
case "5":
$a_id="d_item_id";
break;
}
- 代碼: 選擇全部
switch($i)
{
case "0":
$a_id="a_id";
[color=red]$bag=$wog_arry["item_limit"];[/color]
break;
case "1":
$a_id="d_body_id";
[color=red]$bag=$wog_arry["item_limit"];[/color]
break;
case "2":
$a_id="d_head_id";
[color=red]$bag=$wog_arry["item_limit"];[/color]
break;
case "3":
$a_id="d_hand_id";
[color=red]$bag=$wog_arry["item_limit"];[/color]
break;
case "4":
$a_id="d_foot_id";
[color=red]$bag=$wog_arry["item_limit"];[/color]
break;
case "5":
$a_id="d_item_id";
[color=red]$bag=$wog_arry["item_limit"]+$d['p_bag'];[/color]
break;
}
尋找覆蓋為
- 代碼: 選擇全部
$item=explode(",",$x[0]);
- 代碼: 選擇全部
[color=red]if($x[0])[/color]$item=explode(",",$x[0]);
尋找覆蓋為
- 代碼: 選擇全部
if(count($item)<10){
$x[0].=($x[0] == "")?$x[1]:",".$x[1];
$DB_site->query("update wog_item set $a_id='$x[0]' where p_id=$user_id");
}
- 代碼: 選擇全部
[color=red]$temp_pack=$wog_act_class->item_take_out($item,$x[1],1,$a_id);
if(count($temp_pack)<=$bag)
{
$DB_site->query("update wog_item set ".$a_id."='".implode(',',$temp_pack)."' where p_id=$user_id");
}[/color]
尋找下面,加入
- 代碼: 選擇全部
if($p[p_rebirth]==0){
$p[p_rebirth]=1;
}
- 代碼: 選擇全部
[color=red]switch($_POST[b])
{
case 1:
$birth="中央大陸";
$birth_num="0";
break;
case 2:
$birth="魔法王國";
$birth_num="1";
break;
case 3:
$birth="熱帶雨林";
$birth_num="2";
break;
case 4:
$birth="末日王城";
$birth_num="3";
break;
}[/color]
尋找覆蓋為
- 代碼: 選擇全部
$DB_site->query("update wog_player set p_lv=1,p_exp=0,p_nextexp=1000,p_at=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["str"]+$basic).",
p_df=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["str"]+$basic).",p_mat=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["smart"]+$basic).",
p_mdf=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["smart"]+$basic).", p_str=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["str"]+$basic).",p_life=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["life"]+$basic).",
p_smart=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["smart"]+$basic).",p_agl=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["agl"]+$basic).",p_au=".rand($p[p_rebirth]*2,$p[p_rebirth]*6)."+$basic/2,p_be=".rand($p[p_rebirth],$p[p_rebirth]*5)."+$basic/2,p_hp=".($_POST["life"]*2+$basic).",
p_hpmax=".($_POST["life"]*2+$basic).", p_luck=".$luck.",p_s=".$_POST[s].",ch_id=6,p_ch_s_id=0,
p_money=p_money-".$wog_arry["rebirth_money"].",p_rebirth=p_rebirth+1 where p_id=".$user_id);
- 代碼: 選擇全部
$DB_site->query("update wog_player set p_lv=1,p_exp=0,p_nextexp=1000,p_at=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["str"]+$basic).",
p_df=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["str"]+$basic).",p_mat=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["smart"]+$basic).",
p_mdf=".rand($p[p_rebirth]*2,$p[p_rebirth]*10)."+".($_POST["smart"]+$basic).", p_str=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["str"]+$basic).",p_life=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["life"]+$basic).",[color=red]p_vit=".rand($p[p_rebirth],$p[p_rebirth]*5)."+$basic/2,[/color]
p_smart=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["smart"]+$basic).",p_agl=".rand($p[p_rebirth],$p[p_rebirth]*5)."+".($_POST["agl"]+$basic).",p_au=".rand($p[p_rebirth]*2,$p[p_rebirth]*6)."+$basic/2,p_be=".rand($p[p_rebirth],$p[p_rebirth]*5)."+$basic/2,p_hp=".($_POST["life"]*2+$basic).",
p_hpmax=".($_POST["life"]*2+$basic).", p_luck=".$luck.",p_s=".$_POST[s].",ch_id=6,p_ch_s_id=0,
p_money=p_money-".$wog_arry["rebirth_money"].",[color=red]p_birth=".$birth_num.",[/color]p_rebirth=p_rebirth+1 where p_id=".$user_id);
尋找覆蓋為
- 代碼: 選擇全部
showscript("parent.rebirth_end(4)");
- 代碼: 選擇全部
showscript("parent.rebirth_end(4)[color=red];parent.d_a_name='';parent.d_body_name='';parent.d_head_name='';parent.d_hand_name='';
parent.d_foot_name='';parent.d_item_name='';parent.d_ch_name='戰士';parent.d_s_ch_name='';parent.my_birth='".$birth."'[/color]");
尋找上面,加入
- 代碼: 選擇全部
}
?>
- 代碼: 選擇全部
[color=red] function item_take_out($temp_pack,$adds,$buy_num=0,$a_id)
{
if($a_id=="d_item_id")
{
for($i=0;$i<count($temp_pack);$i++)
{
$temp_packs=split("\*",$temp_pack[$i]);
if($temp_packs[0]==$adds)
{
$temp_packs[1]=$temp_packs[1]+$buy_num;
if($temp_packs[1] > 9)
{
$buy_num=$temp_packs[1]-9;
$temp_packs[1]=9;
}else
{
$buy_num=0;
}
}
$temp_pack[$i]=$temp_packs[0]."*".$temp_packs[1];
}
if($buy_num > 0)
{
$temp_pack[]=$adds."*".$buy_num;
}
return $temp_pack;
}else
{
$temp_pack[]=$adds;
return $temp_pack;
}
} [/color]
開啟 wog.js 寫:尋找下方,加入
- 代碼: 選擇全部
view_name.document.write('<p align="center"><tr><td class="b1">重設角色屬性:<input type="radio" name="s" value="1">地 <input type="radio" name="s" value="2">水 <input type="radio" name="s" value="3">火 <input type="radio" name="s" value="4">木 <input type="radio" name="s" value="5">風 <input type="radio" name="s" value="6">毒</td></tr></p>');
- 代碼: 選擇全部
[color=red]view_name.document.write('<p align="center">重生地點:<input type="radio" name="b" value="1">中央大陸 <input type="radio" name="b" value="2">魔法王國 <input type="radio" name="b" value="3">熱帶雨林 <input type="radio" name="b" value="4">末日王城</p>');[/color]
儲存以上三個檔案。(完)
[hr]
(2007/5/5 - 11:54 pm) 修改一個BUG
http://www.2233.idv.tw/viewtopic.php?p=3929395#3929395
首文以更新~!!