From 9bcffbe82e4e839171739a819b0f2f9672eabe9b Mon Sep 17 00:00:00 2001 From: TALE <42292222+yutorize@users.noreply.github.com> Date: Tue, 22 Jul 2025 18:09:16 +0900 Subject: [PATCH 1/2] =?UTF-8?q?:zap:=20=E8=BF=BD=E5=8A=A0:=20[SW2.5]=20?= =?UTF-8?q?=EF=BC=BB=E5=B7=A8=E4=BA=BA=E5=8C=96=EF=BC=BD=E3=81=8A=E3=82=88?= =?UTF-8?q?=E3=81=B3=E3=80=88=E3=82=A2=E3=83=BC=E3=83=A0=E3=82=B9=E3=83=95?= =?UTF-8?q?=E3=82=A3=E3=82=A2=E3=80=89=E3=81=B8=E3=81=AE=E5=AF=BE=E5=BF=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- _core/lib/junction.pl | 2 +- _core/lib/sw2/calc-chara.pl | 6 ++++++ _core/lib/sw2/edit-chara.js | 42 +++++++++++++++++++++++++++++++------ _core/lib/sw2/edit-chara.pl | 11 ++++++---- _core/lib/sw2/view-chara.pl | 3 +++ 5 files changed, 53 insertions(+), 11 deletions(-) diff --git a/_core/lib/junction.pl b/_core/lib/junction.pl index c89a40833..398c75b2f 100644 --- a/_core/lib/junction.pl +++ b/_core/lib/junction.pl @@ -4,7 +4,7 @@ use utf8; use Encode; -our $ver = "1.27.009"; +our $ver = "1.27.010"; our %in; for (param()){ $in{$_} = param($_); } diff --git a/_core/lib/sw2/calc-chara.pl b/_core/lib/sw2/calc-chara.pl index 07f861af2..16281d5b5 100644 --- a/_core/lib/sw2/calc-chara.pl +++ b/_core/lib/sw2/calc-chara.pl @@ -586,6 +586,11 @@ sub data_calc { $acc += $pc{"weapon${_}Acc"}; # 武器の修正値 ## ダメージ my $str = $pc{sttStr} + ($partNum ? $pc{sttPartC} : $pc{sttAddC}+$pc{sttEquipC}); + if($pc{"weapon${_}Note"} =~ /[巨人化]/){ $str += 12; } + if ($pc{"weapon${_}Note"} =~ /〈レッサー・?アームスフィアⅠ〉/){ $str = 1; } + elsif($pc{"weapon${_}Note"} =~ /〈レッサー・?アームスフィアⅡ〉/){ $str = 5; } + elsif($pc{"weapon${_}Note"} =~ /〈レッサー・?アームスフィアⅢ〉/){ $str = 10; } + elsif($pc{"weapon${_}Note"} =~ /〈アームスフィア〉/){ $str = 20; } my $dmg = 0; $dmg = $pc{"weapon${_}Dmg"}; if ($category eq 'クロスボウ'){ @@ -634,6 +639,7 @@ sub data_calc { ## 基礎値 my $agi = $pc{sttAgi} + ($partNum ? $pc{sttPartB} : $pc{sttAddB}+$pc{sttEquipB}); + if($pc{"defenseTotal${i}Note"} =~ /[巨人化]/){ $agi -= 6; } my $eva = $data::class{$class}{evaUnlock}{mod}; my $def = 0; ## 部位(コア含) diff --git a/_core/lib/sw2/edit-chara.js b/_core/lib/sw2/edit-chara.js index 3eb698a68..32c474478 100644 --- a/_core/lib/sw2/edit-chara.js +++ b/_core/lib/sw2/edit-chara.js @@ -1548,6 +1548,7 @@ function calcAttack() { document.getElementById(`attack-${SET.weapons[i][1]}-mastery`).style.display = feats['武器習熟/'+SET.weapons[i][0]] ? '' : 'none'; document.getElementById(`attack-${SET.weapons[i][1]}-mastery-dmg`).textContent = feats['武器習熟/'+SET.weapons[i][0]] || 0; } + document.getElementById("giantize-annotate").style.display = raceAbilities.includes('巨人化') ? '' : 'none'; document.getElementById("attack-artisan-mastery").style.display = feats['魔器習熟'] ? '' : 'none'; document.getElementById("attack-artisan-mastery-dmg").textContent = feats['魔器習熟'] || 0 ; document.getElementById("artisan-annotate").style.display = feats['魔器習熟'] ? '' : 'none'; @@ -1577,11 +1578,21 @@ function calcWeapon() { let str = (partNum ? stt.Str+Number(form.sttPartC.value || 0) : stt.totalStr); let accBase = 0; let dmgBase = 0; + const giantize = note.match(/[巨人化]/) ? 12 : 0; + const constStr + = note.match(/〈レッサー・?アームスフィアⅠ〉/) ? 1 + : note.match(/〈レッサー・?アームスフィアⅡ〉/) ? 5 + : note.match(/〈レッサー・?アームスフィアⅢ〉/) ? 10 + : note.match(/〈アームスフィア〉/) ? 20 + : 0; // 技能選択のエラーチェック form["weapon"+i+"Class"].classList.toggle('error', errorAccClass[className] == true); // 必筋チェック const maxReqd - = SET.class[className]?.reqdHalf ? reqdStrHalf + = constStr ? constStr + : giantize && SET.class[className]?.reqdHalf ? Math.ceil((reqdStr+12) / 2) + : giantize ? (reqdStr+12) + : SET.class[className]?.reqdHalf ? reqdStrHalf : /^\d+w$/i.test(weaponReqdRaw) ? reqdMnd : SET.class[className]?.accUnlock?.reqd ? stt['total'+SET.class[className]?.accUnlock?.reqd] : reqdStr; @@ -1600,7 +1611,8 @@ function calcWeapon() { else if(category === 'ガン') { dmgBase = magicPowers['Mag']; } else if(SET.class[className]?.accUnlock?.dmg === 'power') { dmgBase = magicPowers[SET.class[className].id] } - else if(classLv) { dmgBase = classLv + parseInt(str / 6); } + else if(constStr) { dmgBase = classLv + parseInt(constStr / 6); } + else if(classLv) { dmgBase = classLv + parseInt((str + giantize) / 6); } // 戦闘特技 if(!partNum || partNum == form.partCore.value) { @@ -1746,19 +1758,23 @@ function calcArmour(evaAdd,defBase) { const className = form['evasionClass'+i].value; const partNum = form['evasionPart'+i].value; const partName = form[`part${partNum}Name`]?.value || ''; + const giantize = form[`defenseTotal${i}Note`].value.match(/[巨人化]/) ? -6 : 0; // 技能選択のエラーチェック form['evasionClass'+i].classList.toggle('error', errorEvaClass[className] == true); // 最大必筋 - const maxReqd = (SET.class[className]?.reqdHalf) ? reqdStrHalf : reqdStr; + const maxReqd + = (giantize && SET.class[className]?.reqdHalf) ? math((reqdStr+12) / 2) + : (giantize) ? (reqdStr+12) + : (SET.class[className]?.reqdHalf) ? reqdStrHalf : reqdStr; // 計算 const classLv = lv[SET.class[className]?.id] || 0; let eva = (SET.class[className]?.evaUnlock?.mod || 0); let def = 0; - let agi = (partNum ? stt.Agi+Number(form.sttPartB.value || 0) : stt.totalAgi); + let agi = (partNum ? stt.Agi+Number(form.sttPartB.value || 0) : stt.totalAgi+giantize); if(!partNum || partNum == form.partCore.value) { def += defBase; eva += evaAdd; @@ -1781,14 +1797,28 @@ function calcArmour(evaAdd,defBase) { for (let num = 1; num <= form.armourNum.value; num++){ const checkObj = form[`defTotal${i}CheckArmour${num}`]; checkObj.parentNode.classList.remove('error') + const note = form["armour"+num+"Note"].value; + const constStr + = note.match(/〈レッサー・?アームスフィアⅠ〉/) ? 1 + : note.match(/〈レッサー・?アームスフィアⅡ〉/) ? 5 + : note.match(/〈レッサー・?アームスフィアⅢ〉/) ? 10 + : note.match(/〈アームスフィア〉/) ? 20 + : 0; if(!checkObj.checked) continue; const category = form[`armour${num}Category`].value; let reqdMod = (category == '盾') ? (equipMod.WeaponReqd||0) : 0; - if((safeEval(form[`armour${num}Reqd`].value) || 0) > maxReqd + reqdMod){ - form[`armour${num}Reqd`].classList.add('error'); + if(constStr){ + if((safeEval(form[`armour${num}Reqd`].value) || 0) > constStr){ + form[`armour${num}Reqd`].classList.add('error'); + } + } + else { + if((safeEval(form[`armour${num}Reqd`].value) || 0) > maxReqd + reqdMod){ + form[`armour${num}Reqd`].classList.add('error'); + } } eva += Number(form[`armour${num}Eva`].value); diff --git a/_core/lib/sw2/edit-chara.pl b/_core/lib/sw2/edit-chara.pl index 7d180c7a9..d3a3128cd 100644 --- a/_core/lib/sw2/edit-chara.pl +++ b/_core/lib/sw2/edit-chara.pl @@ -1062,8 +1062,10 @@ sub classInputBox {
@{[input('weaponNum','hidden')]} @@ -1179,7 +1181,7 @@ sub classInputBox { @{[ input "armour${num}Eva",'number','calcDefense' ]} @{[ input "armour${num}Def",'number','calcDefense' ]} @{[ input "armour${num}Own",'checkbox','calcDefense();calcMobility','disabled' ]} - @{[ input "armour${num}Note",'','','onchange="changeEquipMod()"' ]} + @{[ input "armour${num}Note",'','','onchange="changeEquipMod();calcDefense()"' ]} HTML if($num eq 'TMPL'){ print '' } } @@ -1215,7 +1217,7 @@ sub classInputBox { print <<"HTML"; 0 0 - @{[input("defenseTotal${i}Note")]} + @{[ input "defenseTotal${i}Note",'','','onchange="calcDefense()"' ]} HTML print '' if ($i eq 'TMPL'); } @@ -1225,9 +1227,10 @@ sub classInputBox {
diff --git a/_core/lib/sw2/view-chara.pl b/_core/lib/sw2/view-chara.pl index 84f37699e..f9315dc79 100644 --- a/_core/lib/sw2/view-chara.pl +++ b/_core/lib/sw2/view-chara.pl @@ -736,6 +736,7 @@ sub replaceModificationNotation { $pc{'weapon'.$_.'Acc'} = 0; $pc{'weapon'.$_.'Dmg'} = 0; } + $pc{"weapon${_}Note"} =~ s#〈(レッサー・?アームスフィア[ⅠⅡⅢ]|アームスフィア)〉|[巨人化]#$&#; push(@weapons, { NAME => $pc{'weapon'.$_.'Name'}, PART => $pc{'part'.$pc{'weapon'.$_.'Part'}.'Name'}, @@ -886,6 +887,7 @@ sub replaceModificationNotation { if($pc{'armour'.$_.'Type'} =~ /^(鎧|盾|他|龍骸)[0-9]+/ && $count{$1} <= 1){ $pc{'armour'.$_.'Type'} = $1 } + $pc{"armour${_}Note"} =~ s#〈(レッサー・?アームスフィア[ⅠⅡⅢ]|アームスフィア)〉#$&#; push(@armours, { TYPE => $pc{'armour'.$_.'Type'}, NAME => $pc{'armour'.$_.'Name'}, @@ -920,6 +922,7 @@ sub replaceModificationNotation { .($class ? "${class}/" : '') .(@ths == @armours ? 'すべての防具・効果' : join('+', @ths) || ''); $th =~ s|/$||; + $pc{"defenseTotal${i}Note"} =~ s#[巨人化]#$&#; push(@total, { TH => $th, EVA => $pc{"defenseTotal${i}Eva"}, From fb45e57bc8a8af463600d4b51397c688d11ade06 Mon Sep 17 00:00:00 2001 From: ViVi Date: Thu, 24 Jul 2025 14:28:10 +0900 Subject: [PATCH 2/2] =?UTF-8?q?[SW2]=20=E3=83=81=E3=83=A3=E3=83=83?= =?UTF-8?q?=E3=83=88=E3=83=91=E3=83=AC=E3=83=83=E3=83=88=E3=81=AE=E3=80=8C?= =?UTF-8?q?=E8=BF=BD=E5=8A=A0=E6=8C=BF=E5=85=A5=E3=80=8D=E3=81=AE=E9=81=B8?= =?UTF-8?q?=E6=8A=9E=E8=82=A2=E3=81=AB=E3=80=8C=E6=AD=A6=E5=99=A8=E6=94=BB?= =?UTF-8?q?=E6=92=83=E7=B3=BB=E3=81=AE=E5=85=88=E9=A0=AD=E3=80=8D=E3=82=92?= =?UTF-8?q?=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 攻撃に先立って解決すべき処理で利用する想定 --- _core/lib/sw2/edit-chara-palette-option.pl | 2 +- _core/lib/sw2/palette-sub.pl | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/_core/lib/sw2/edit-chara-palette-option.pl b/_core/lib/sw2/edit-chara-palette-option.pl index 698b40a90..c5befa71b 100644 --- a/_core/lib/sw2/edit-chara-palette-option.pl +++ b/_core/lib/sw2/edit-chara-palette-option.pl @@ -43,7 +43,7 @@ sub chatPaletteFormOptional { foreach ('TMPL',1 .. $pc{chatPaletteInsertNum}){ $html .= '' if $_ eq 'TMPL'; diff --git a/_core/lib/sw2/palette-sub.pl b/_core/lib/sw2/palette-sub.pl index 8e2dae843..ae0f20c52 100644 --- a/_core/lib/sw2/palette-sub.pl +++ b/_core/lib/sw2/palette-sub.pl @@ -524,6 +524,7 @@ sub palettePreset { $::pc{'weapon'.$_.'Crit'}.$::pc{'weapon'.$_.'Dmg'} eq ''; $text .= "###\n" if $bot{TKY}; $text .= "### ■武器攻撃系\n"; + $text .= appendPaletteInsert('attack_head'); $text .= "//命中修正=0\n"; $text .= "//C修正=0\n"; $text .= "//追加D修正=0\n";