spell adv disable update

This commit is contained in:
Djjus
2022-01-02 17:56:59 +00:00
parent 48331c3ad9
commit 742f9ea387
2 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -76,7 +76,7 @@ Note conditions are not intended for out of combat situations, GM simply makes t
January 3rd 2022 v1.53.2
- Fix for Characteristics modifier which was adding twice on the skill target display in rolls.
- Resolved issue with Custom Spell Advantage rule (which basic removed advantage modifier from casting), this will now also disable Advantage for Langange Magick skill roll aswell as spellbook rolls. And removes the gold star indicator when disabled too.
December 6th 2021 v1.53.1
@@ -18982,9 +18982,14 @@
<div class="sheet-col-1-10 sheet-center sheet-pad-r-sm sheet-vert-middle">
<input type="checkbox" name="attr_LangMagickCareer" value="1">
</div>
<input type="checkbox" name="attr_Advantage_casting" class="sheet-hidden sheet-hider" value="1" />
<div class="sheet-col-3-8 sheet-pad-r-sm sheet-vert-middle">
<span data-i18n="LANG-MAGICK">Language (Magick)</span><span data-i18n-title="SKILLADV" title="Modified by Advantage" style="margin-left: 5px; font-family: pictos; color: gold; font-size: 10px; padding-bottom: 2px; vertical-align: top">S</span>
</div>
<input type="checkbox" name="attr_Advantage_casting" class="sheet-hidden sheet-hider" value="0" />
<div class="sheet-col-3-8 sheet-pad-r-sm sheet-vert-middle">
<span data-i18n="LANG-MAGICK">Language (Magick)</span>
</div>
<div class="sheet-col-1-10 sheet-center sheet-pad-r-sm sheet-vert-middle">
<select class="sheet-select-no-arrow-center" name="attr_LangMagickChar">
<option value="(@{WeaponSkill})" data-i18n="ABBREVIATE-WEAPON-SKILL">WS</option>
@@ -47938,7 +47943,7 @@ on('clicked:repeating_divinemiracles:miracle clicked:repeating_divinemiracles:mi
on('clicked:coolroll clicked:dodgeroll clicked:meleebasicroll clicked:meleebrawlingroll clicked:meleecavalryroll clicked:meleefencingroll clicked:meleeflailroll clicked:meleeparryroll clicked:meleepolearmroll clicked:meleetwohandedroll clicked:langmagickroll clicked:rangedblackpowderroll clicked:rangedbowroll clicked:rangedcrossbowroll clicked:rangedengineeringroll clicked:rangedentanglingroll clicked:rangedexplosivesroll clicked:rangedslingroll clicked:rangedthrowingroll', (eventInfo) => {
let roll = '{{test=[[@{roll_rule}]]}} {{sl=[[0]]}} {{slbonus=[[0>addsl<]]}} {{sladd=[[0]]}} {{slbonusatk=[[0>addsl<]]}} {{modvalue=[[?{@{translation_modifier}|0}]]}} {{unconscious=[[@{UnconsciousMod}]]}} {{title=^{>Charcap<}}} {{skill=^{BASIC-SKILL}}} {{character_name=@{character_name}}} {{target=[[ [[@{cond-}*-1]] [COND] + [[(@{>Char<Char}+@{>Char<Adv}+@{>Char<Misc})>addtak<]] [SKILL] + [[@{Advantage}*10]] [ADV] + ?{@{translation_modifier}|0} [MOD] ]]}} {{skilltest=true}} {{SLmod=[[?{SL Modifier|0}]]}} {{advantage=[[@{AdvantageDisplay}]]}} {{sitmod=[[0>sitmod<]]}} {{mod1type=[[@{>Char<_modtype1}]]}} {{mod1=@{>Char<_mod1}}} {{mod2type=[[@{>Char<_modtype2}]]}} {{mod2=@{>Char<_mod2}}} {{mod3type=[[@{>Char<_modtype3}]]}} {{mod3=@{>Char<_mod3}}} {{reroll=@{RT-reroll}>Char<roll)}}';
let roll = '{{test=[[@{roll_rule}]]}} {{sl=[[0]]}} {{slbonus=[[0>addsl<]]}} {{sladd=[[0]]}} {{slbonusatk=[[0>addsl<]]}} {{modvalue=[[?{@{translation_modifier}|0}]]}} {{unconscious=[[@{UnconsciousMod}]]}} {{title=^{>Charcap<}}} {{skill=^{BASIC-SKILL}}} {{character_name=@{character_name}}} {{target=[[ [[@{cond-}*-1]] [COND] + [[(@{>Char<Char}+@{>Char<Adv}+@{>Char<Misc})>addtak<]] [SKILL] + [[@{Advantage}*10>MagAdv<]] [ADV] + ?{@{translation_modifier}|0} [MOD] ]]}} {{skilltest=true}} {{SLmod=[[?{SL Modifier|0}]]}} {{advantage=[[@{AdvantageDisplay}>MagAdv<]]}} {{sitmod=[[0>sitmod<]]}} {{mod1type=[[@{>Char<_modtype1}]]}} {{mod1=@{>Char<_mod1}}} {{mod2type=[[@{>Char<_modtype2}]]}} {{mod2=@{>Char<_mod2}}} {{mod3type=[[@{>Char<_modtype3}]]}} {{mod3=@{>Char<_mod3}}} {{reroll=@{RT-reroll}>Char<roll)}}';
var trigger = eventInfo.triggerName.slice(8, -4);
var triggercap = trigger.toUpperCase();
var prefix = trigger.split('_').slice(0,3).join('_') + '_';
@@ -47996,7 +48001,8 @@ on('clicked:repeating_divinemiracles:miracle clicked:repeating_divinemiracles:mi
else if (trigger === 'langmagick') {cond = '{{cond=[[@{condgen_see}]]}} {{fatigued=[[@{FatiguedMod}]]}} {{broken=[[@{BrokenMod}]]}} {{stuned=[[@{StunedMod}]]}} {{poisoned=[[@{PoisonedMod}]]}} {{prone=[[0]]}} {{entangled=[[0]]}} {{blinded=[[@{BlindedMod}]]}} {{deafened=[[0]]}}';
addtak= '*@{LangMagickTaken}';
rollPart = rollPart2.replaceAll('cond-', `condgen_see`).replaceAll('>addtak<', addtak);}
MagAdv= '*@{Advantage_casting}';
rollPart = rollPart2.replaceAll('cond-', `condgen_see`).replaceAll('>MagAdv<', MagAdv);}
else {cond = ''}