Commit 73281bff authored by Nemo Ma's avatar Nemo Ma Committed by GitHub

Merge pull request #91 from hikawiier/waaagh

rev combat phase 3.?+2
parents feb8f653 a4beeeca
......@@ -17,11 +17,11 @@ $club_skillslist = Array
9 => Array('s_hp','s_ad','f_heal','c9_spirit','c9_lb','c9_iceheart','c9_charge','c9_heartfire'), #'超能力者',
10 => Array('s_hp','s_ad','f_heal','c10_inspire','c10_insight','c10_decons'), #'天赋异禀', //高速成长与天赋异禀合并为天赋异禀
11 => Array('s_hp','s_ad','f_heal'), #'富家子弟',
12 => Array('s_hp','s_ad','f_heal'), #'全能骑士',
13 => Array('s_hp','s_ad','f_heal'), #'根性兄贵',
14 => Array('s_hp','s_ad','f_heal'), #'肌肉兄贵',
12 => Array('s_hp','s_ad','f_heal','c12_huge','c12_enmity','c12_garrison','c12_rage','c12_bloody','c12_swell'), #'全能兄贵', //根性兄贵、肌肉兄贵、全能骑士合并为全能兄贵
//13 => Array('s_hp','s_ad','f_heal'), #'根性兄贵',
//14 => Array('s_hp','s_ad','f_heal'), #'肌肉兄贵',
15 => Array('f_heal'), #'<span class="L5">L5状态</span>',
16 => Array('s_hp','s_ad','f_heal'), #'全能骑士',
//16 => Array('s_hp','s_ad','f_heal'), #'全能骑士',
17 => Array('f_heal'), #'走路萌物',
//18 => Array('s_hp','s_ad','f_heal'), #'天赋异禀',
19 => Array('s_hp','s_ad','f_heal'), #'晶莹剔透',
......@@ -112,7 +112,7 @@ $cskills = Array
'status' => Array('hp','mhp'),
'effect' => Array(
0 => Array( 'hp' => '+=::3', 'mhp' => '+=::3',),
13 => Array( 'hp' => '+=::6', 'mhp' => '+=::6',),
12 => Array( 'hp' => '+=::6', 'mhp' => '+=::6',),
),
),
's_ad' => Array
......@@ -127,7 +127,7 @@ $cskills = Array
'status' => Array('att','def'),
'effect' => Array(
0 => Array('att' => '+=::4', 'def' => '+=::6'),
14 => Array('att' => '+=::9', 'def' => '+=::12'),
12 => Array('att' => '+=::9', 'def' => '+=::12'),
),
),
'f_heal' => Array
......@@ -1427,7 +1427,7 @@ $cskills = Array
'cost' => Array(4,5,7,9,11,14,17,20,-1),
'input' => '思考',
'log' => '……<br>',
'choice' => Array(1,2,3,4,5,6,7,8,9), //无效果/重视遇敌/重视探物
'choice' => Array(1,2,3,4,5,6,7,8,9,12), //无效果/重视遇敌/重视探物
'clog' => '<span class="yellow">切换了选定称号。</span><br>',
'events' => Array('inspire'),
'status' => Array('skillpara|c10_inspire-lvl'),
......@@ -1481,6 +1481,113 @@ $cskills = Array
'lvl' => '[:lvl:] >= 3',
),
),
'c12_huge' => Array
(
'name' => '瞩目',
'tags' => Array('passive'),
'desc' => '你对敌人的隐蔽率<span class="yellow">-[:hidegain:]%</span>;敌人对你的隐蔽率<span class="yellow">-[:hideloss:]%</span>',
'vars' => Array(
'hidegain' => 100,
'hideloss' => 75,
),
),
'c12_enmity' => Array
(
'name' => '底力',
'tags' => Array('passive'),
'desc' => '当前生命值越低,你造成的最终伤害越高<br>
最终伤害增幅:<span class="yellow">[:findmgr:]%</span>×<span class="gold" tooltip2="底力系数计算公式:(1+2×已损失生命百分比)×已损失生命百分比">底力系数</span>',
'maxlvl' => 6,
'cost' => Array(1,1,2,2,2,3,-1),
'input' => '升级',
'log' => '<span class="yellow">「底力」升级成功。</span><br>',
'status' => Array('skillpara|c12_enmity-lvl'),
'effect' => Array(
0 => Array('skillpara|c12_enmity-lvl' => '+=::1',),
),
'svars' => Array('lvl' => 0),
'vars' => Array(
'findmgr' => Array(10,15,20,25,35,45,55),
),
),
'c12_garrison' => Array
(
'name' => '根性',
'tags' => Array('passive'),
'desc' => '当前生命值越低,基础防御力越高<br>
基础防御力增幅:<span class="yellow">[:defgain:]%</span>×<span class="gold" tooltip2="根性系数计算公式:(-1×已损失生命百分比^3)+4×已损失生命百分比">根性系数</span>',
'maxlvl' => 8,
'cost' => Array(2,2,2,3,4,5,7,11,-1),
'input' => '升级',
'log' => '<span class="yellow">「底力」升级成功。</span><br>',
'status' => Array('skillpara|c12_garrison-lvl'),
'effect' => Array(
0 => Array('skillpara|c12_garrison-lvl' => '+=::1',),
),
'svars' => Array('lvl' => 0),
'vars' => Array(
'defgain' => Array(19,24,29,34,42,52,63,75,90),
),
),
'c12_rage' => Array
(
'name' => '狂怒',
'tags' => Array('battle'),
'desc' => '消耗相当于<span class="red">[:hpcost:]%</span>生命上限的生命值,<br>
附加等于<span class="yellow">所消耗生命值</span>且受<span class="yellow">「底力」</span>加成的最终伤害<br>
发动需消耗<span class="yellow">[:ragecost:]</span>点怒气',
'bdesc' => '消耗<span class="red">[:hpcost:]%</span>生命值,附加等于消耗值且受<span class="yellow">「底力」</span>加成最终伤害;发动需消耗<span class="red">[:ragecost:]</span>怒气',
'vars' => Array(
'ragecost' => 50,
'hpcost' => 25,
),
'lockdesc' => Array(
'lvl' => '7级时解锁',
'hp+mhp' => '生命值在<span class="red">25%</span>以上时可发动',
),
'unlock' => Array(
'lvl' => '[:lvl:] >= 7',
'hp+mhp' => '[:hp:] > [:mhp:]*0.25',
),
),
'c12_bloody' => Array
(
'name' => '浴血',
'tags' => Array('passive'),
'desc' => '在生命值低于<span class="yellow">75%/50%/30%</span>生命上限的情况下,<br>
击杀敌人增加<span class="yellow">2/3/11</span>点基础攻击与<span class="yellow">4/5/15</span>点基础防御',
'vars' => Array(
'hplimit' => Array(75,50,30),
'attgain' => Array(2,3,11),
'defgain' => Array(4,5,15),
),
'lockdesc' => Array(
'lvl' => '13级时解锁',
'hp+mhp' => '生命值低于<span class="red">75%</span>时可触发',
),
'unlock' => Array(
'lvl' => '[:lvl:] >= 13',
'hp+mhp' => '[:hp:] <= [:mhp:]*0.75',
),
),
'c12_swell' => Array
(
'name' => '海虎',
'tags' => Array('passive'),
'desc' => '在生命值低于<span class="yellow">50%/30%</span>生命上限的情况下,<br>
有<span class="yellow">[:swellr:]%×</span><span class="gold" tooltip2="底力系数计算公式:(1+2×已损失生命百分比)×已损失生命百分比">底力系数</span>概率连续造成<span class="yellow">2/3</span>次攻击',
'vars' => Array(
'swellr' => 19,
),
'lockdesc' => Array(
'lvl' => '21级时解锁',
'hp+mhp' => '生命值低于<span class="red">50%</span>时可触发',
),
'unlock' => Array(
'lvl' => '[:lvl:] >= 21',
'hp+mhp' => '[:hp:] <= [:mhp:]*0.5',
),
),
'tl_cstick' => Array
(
'name' => '抡尸',
......
......@@ -1456,7 +1456,7 @@ $npcinfo = array
(
'name' => '卡',
'icon' => 10,
'club' => 13,
'club' => 12,
'wep' => '【不屈的意志】',
'wepk' => 'WF',
'wepe' => 140,
......@@ -1549,7 +1549,7 @@ $npcinfo = array
(
'name' => '超魔理沙-电子',
'icon' => 10,
'club' => 14,
'club' => 12,
'wep' => '【荆棘式电子地雷】',
'wepk' => 'WP',
'wepe' => 240,
......@@ -1755,7 +1755,7 @@ $npcinfo = array
(
'name' => 'tabris',
'icon' => 10,
'club' => 13,
'club' => 12,
'wep' => '十二试炼',
'wepk' => 'WC',
'wepe' => 400,
......
......@@ -37,11 +37,11 @@ $clubinfo = Array(
//10=>'高速成长', //天赋异禀与高速成长合并
10=>'天赋异禀',
11=>'富家子弟',
12=>'全能骑士',
13=>'根性兄贵',
14=>'肌肉兄贵',
12=>'全能骑士', //根性兄贵、肌肉兄贵、全能骑士合并为全能兄贵
//13=>'根性兄贵',
//14=>'肌肉兄贵',
15=>'<span class="L5">L5状态</span>',
16=>'全能骑士',
//16=>'全能骑士',
17=>'走路萌物',
//18=>'天赋异禀',
19=>'晶莹剔透',
......
......@@ -45,8 +45,8 @@ function getclub($who, &$c1, &$c2, &$c3)
$c3=calc(11131,6397,$curgid,$curuid,$curpid,$starttime,$validtime);
//$clubid = array(6,7,8,99,10,11,13,14,16,18,19,7,99,13,14,18,6,19,13,14,18);
//$c3%=21; $c3=$clubid[$c3];
$clubid = array(6,7,8,99,10,11,13,14,16,19,7,99,13,14,18,6,19,13,14);
$c3%=19; $c3=$clubid[$c3];
$clubid = array(6,7,8,10,11,12,19,99,6,7,8,10,11,12,19,99);
$c3%=16; $c3=$clubid[$c3];
if ($c1==$c3 || $c2==$c3) $c3=99;
if ($c1>$c2) swap($c1,$c2);
......@@ -82,9 +82,10 @@ function updateskill(&$data=NULL)
if ($club==5) $wd+=50;
if ($club==9) $wf+=40;
if ($club==11) $money+=680;
if ($club==16) { $wp+=25; $wk+=25; $wc+=25; $wg+=25; $wd+=25; $wf+=25; }
if ($club==12) {$wp+=25; $wk+=25; $wc+=25; $wg+=25; $wd+=25; $wf+=25; $mhp+=250; $hp+=250; $att+=300; $def+=300;}
/*if ($club==16) { $wp+=25; $wk+=25; $wc+=25; $wg+=25; $wd+=25; $wf+=25; }
if ($club==13) { $mhp+=250; $hp+=250; }
if ($club==14) { $att+=300; $def+=300; }
if ($club==14) { $att+=300; $def+=300; }*/
# 变更社团时 获取社团技能
//include_once GAME_ROOT.'./include/game/revclubskills.func.php';
......
......@@ -132,8 +132,8 @@ function itemuse($itmn,&$data=NULL) {
//global $sp, $msp,$club;
if ($sp < $msp) {
$oldsp = $sp;
if($club == 16){
$spup = round($itme*2.5);
if($club == 12){
$spup = round($itme*1.25);
}else{
$spup = $itme;
}
......@@ -158,8 +158,8 @@ function itemuse($itmn,&$data=NULL) {
//global $hp, $mhp,$club;
if ($hp < $mhp) {
$oldhp = $hp;
if($club == 16){
$hpup = round($itme*2.5);
if($club == 12){
$hpup = round($itme*1.25);
}else{
$hpup = $itme;
}
......@@ -216,8 +216,8 @@ function itemuse($itmn,&$data=NULL) {
} elseif (strpos ( $itmk, 'HB' ) === 0) {
//global $hp, $mhp, $sp, $msp,$club;
if (($hp < $mhp) || ($sp < $msp)) {
if($club == 16){
$bpup = round($itme*2.5);
if($club == 12){
$bpup = round($itme*1.25);
}else{
$bpup = $itme;
}
......
......@@ -198,6 +198,7 @@ function trap(&$data=NULL){
real_trap_damage:
$tmp_club=$club;
$hp -= $damage;
$trapkill = false;
if($playerflag)
{
......
......@@ -677,7 +677,7 @@
//获取pd的防御力与修正
function get_base_def(&$pa,&$pd,$active,$tooltip=0)
{
global $specialrate,$log;
global $specialrate,$log,$cskills;
if(!isset($pd['wep_kind'])) get_wep_kind($pd);
# pd基础防御力:
$base_def = $pd['def'];
......@@ -703,7 +703,6 @@
# 「格挡」技能加成
if(!check_skill_unlock('c1_def',$pd))
{
global $cskills;
$def_trans_rate = $cskills['c1_def']['vars']['trans'];
$def_maxtrans = $cskills['c1_def']['vars']['maxtrans'];
$sk_def = min($def_maxtrans, $def_trans_rate * $pd['wepe'] / 100);
......@@ -718,7 +717,7 @@
{
$tooltip = "<span tooltip=\" 基础防御值:{$base_def}+{$equip_def}";
if(!empty($def1)) $tooltip .="+{$def1}";
if(!empty($sk_def)) $tooltip .="\r「格挡」:+{$sk_def}";
if(!empty($sk_def)) $tooltip .="\r技能加成:+{$sk_def}";
$tooltip .= "\r";
}
# 计算防御力修正
......@@ -767,9 +766,16 @@
rev_get_clubskill_bonus_p($pa['club'],$pa['skills'],$pa,$pd['club'],$pa['skills'],$pd,$attfac,$deffac);
$club_def_per *= $deffac;
}*/
# 计算社团技能对pd防御力的修正(新)
#「根性」技能加成
if(!check_skill_unlock('c12_garrison',$pd))
{
$sk_lvl = get_skilllvl('c12_garrison',$pd);
$sk_var = 100+round(get_skillvars('c12_garrison','defgain',$sk_lvl) * calc_garrison_losshpr($pa,$pd));
}
# 汇总
$total_def = round($total_def*($base_def_per/100)*($inf_def_per/100));
if(isset($sk_var)) $total_def = round($total_def*($sk_var/100));
$total_def = max(0.01,$total_def);
if($tooltip)
......@@ -777,6 +783,7 @@
$tooltip .= "天气修正:{$wth_def_per}% \r 地点修正:{$pls_def_per}% \r 姿态修正:{$pose_def_per}% \r 策略修正:{$tac_def_per}%";
if($inf_def_per <> 100) $tooltip .=" \r 异常状态修正:{$inf_def_per}%";
//if($club_def_per <> 100) $tooltip .=" \r 称号技能修正:{$club_def_per}%";
if(isset($sk_var)) $tooltip .=" \r 技能修正:".($sk_var-100)."%";
$tooltip .="\">".$total_def."</span>";
return $tooltip;
}
......@@ -1637,6 +1644,18 @@
$fin_dmg_p[] = $sk_p;
}
}
# 「底力」效果判定:
if(isset($pa['skill_c12_enmity']))
{
$sk_lvl = get_skilllvl('c12_enmity',$pa);
$sk_p = round(get_skillvars('c12_enmity','findmgr',$sk_lvl) * calc_enmity_losshpr($pa,$pd));
if($sk_p > 5)
{
$p = 1+($sk_p / 100);
$log.= "<span class='yellow'>「底力」使{$pa['nm']}造成的最终伤害提高了{$sk_p}%!</span><br>";
$fin_dmg_p[] = $p;
}
}
# 书中虫防守事件:移动到最终伤害系数变化阶段了
if($pd['type'] == 89 && ($pd['name'] == '高中生·白神' || $pd['name'] == '白神·讨价还价'))
......@@ -1753,6 +1772,20 @@
}
}
# 「狂怒」效果判定:
if(isset($pa['bskill_c12_rage']))
{
$sk_dmg = round($pa['mhp']*0.25);
$pa['hp'] -= $sk_dmg;
$sk_vars = get_skillvars('c12_enmity','findmgr',get_skilllvl('c12_enmity',$pa)) * calc_enmity_losshpr($pa,$pd);
if($sk_vars > 1) $sk_dmg = round($sk_dmg *(1 + ($sk_vars/100)));
if($sk_dmg > 0)
{
$fin_dmg += $sk_dmg;
$log .= "<span class=\"yellow\">{$pa['nm']}燃烧生命打出了狂怒一击!附加了<span class=\"red\">$sk_dmg</span>点额外伤害!</span><br>";
}
}
# 「护盾」效果判定
if(isset($pd['skill_buff_shield']))
{
......@@ -2314,13 +2347,21 @@
{
global $log;
$loop = 0;
#「双响」效果判定
# 「双响」效果判定
if(isset($pa['bskill_c5_double']))
{
unset($pa['bskill_c5_double']);unset($pa['bskilllog']);
$log .= "<span class=\"yellow\">{$pa['nm']}引爆了预埋的另一组爆炸物!</span><br>";
$loop = 1;
}
# 「海虎」效果判定
if(isset($pa['skill_c12_swell']))
{
$pa['skill_c12_swell'] --;
if(empty($pa['skill_c12_swell'])) unset($pa['skill_c12_swell']);
$log .= "<span class=\"lime\">{$pa['nm']}以雷霆万钧之势再度袭向{$pd['nm']}!</span><br>";
$loop = 1;
}
return $loop;
}
?>
\ No newline at end of file
......@@ -140,6 +140,16 @@
$pa['skill_c10_insight'] = 1;
$pa['skilllog'] .= "<span class='yellow'>{$pa['nm']}凭借丰富的经验看穿了{$pd['nm']}的破绽!</span><br>";
}
# 「海虎」特殊判定:
elseif($sk == 'c12_swell')
{
$sk_var = get_skillvars('c12_swell','swellr') * calc_enmity_losshpr($pa,$pd);
$dice = diceroll(99);
if($dice < $sk_var)
{
$pa['skill_c12_swell'] = $pa['hp'] <= $pa['mhp']*0.3 ? 2 : 1;
}
}
# 其他非特判技能,默认给一个触发标记
else
{
......@@ -179,6 +189,18 @@
$sk_r = get_skillvars('buff_assassin','hidegain');
$r += $sk_r;
}
# pa持有「瞩目」时的效果判定:
if(!check_skill_unlock('c12_huge',$pa))
{
$sk_r = get_skillvars('c12_huge','hideloss');
$r -= $sk_r;
}
# pd持有「瞩目」时的效果判定:
if(!check_skill_unlock('c12_huge',$pd))
{
$sk_r = get_skillvars('c12_huge','hidegain');
$r -= $sk_r;
}
return $r;
}
......@@ -516,6 +538,22 @@
return $ex_dmg_fix;
}
# 背水HP系数
function calc_enmity_losshpr(&$pa,&$pd)
{
$hpr = 1 - ($pa['hp']/$pa['mhp']);
$r = (1 + 2*$hpr) * $hpr;
return $r;
}
# 坚守HP系数
function calc_garrison_losshpr(&$pa,&$pd)
{
$hpr = 1 - ($pa['hp']/$pa['mhp']);
$r = -1 * pow($hpr,3) + 4 * $hpr;
return $r;
}
# 真红暮特殊判定
function attr_extra_19_crimson(&$pa,&$pd,$active,$phase=0)
{
......
......@@ -1045,6 +1045,18 @@
}
}
# 「浴血」技能判定
if(isset($pa['skill_c12_bloody']))
{
if($pa['hp'] <= $pa['mhp']*0.3) $sk_lvl = 2;
elseif($pa['hp'] <= $pa['mhp']*0.5) $sk_lvl = 1;
else $sk_lvl = 0;
$sk_att_vars = get_skillvars('c12_bloody','attgain',$sk_lvl);
$sk_def_vars = get_skillvars('c12_bloody','defgain',$sk_lvl);
$pa['att'] += $sk_att_vars; $pa['def'] += $sk_def_vars;
$log .= '<span class="yellow">「浴血」使'.$pa['nm'].'的攻击增加了'.$sk_att_vars.'点,防御增加了'.$sk_def_vars.'点!</span><br>';
}
return;
}
......@@ -1127,7 +1139,7 @@
if ($pa['exp'] >= $up_exp_temp && $pa['lvl'] < 255)
{
$sklanginfo = Array ('wp' => '殴熟', 'wk' => '斩熟', 'wg' => '射熟', 'wc' => '投熟', 'wd' => '爆熟', 'wf' => '灵熟', 'all' => '全系熟练度' );
$sknlist = Array (1 => 'wp', 2 => 'wk', 3 => 'wc', 4 => 'wg', 5 => 'wd', 9 => 'wf', 16 => 'all' );
$sknlist = Array (1 => 'wp', 2 => 'wk', 3 => 'wc', 4 => 'wg', 5 => 'wd', 9 => 'wf', 12 => 'all' );
$skname = isset($sknlist[$pa['club']]) ? $sknlist[$pa['club']] : 0;
//升级判断
$lvup = 1 + floor (($pa['exp'] - $up_exp_temp)/$baseexp/2);
......@@ -1136,13 +1148,13 @@
//升级数值计算
for($i = 0; $i < $lvup; $i += 1)
{
if ($pa['club'] == 13) {
if ($pa['club'] == 12) {
$lvuphp += rand ( 14, 18 );
} else {
$lvuphp += rand ( 8, 10 );
}
$lvupsp += rand( 4,6);
if ($pa['club'] == 14) {
if ($pa['club'] == 12) {
$lvupatt += rand ( 4, 6 );
$lvupdef += rand ( 5, 8 );
} else {
......
......@@ -1808,7 +1808,7 @@ NPC也会发出重击和必杀技,请随时小心。</p>
<span class="grey">但是代价是什么……?</span></span>
</td>
<td class="b3">
<span>待实装</span>
<span><input type="button" class="cmdbutton" value="点击查看称号技能" onclick="showModalDialog($('skillhelp-c12'));"></span>
</td>
</tr>
<tr>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment