Files
roll20-character-sheets/Skyfall/ficha.html
T
Lucas Hall 245dae3132 Merge pull request #13079 from Capycat-Games/skyfall-new-charactersheet
[BugFix][SkyfallRPG] Fixing a Bug when doing attribute roll
2024-07-09 14:07:10 -04:00

2460 lines
182 KiB
HTML

<link rel="stylesheet" href="skyfall.css">
<div class="sheet-main">
<div class="sheet-header-global">
<div class="sheet-header-left">
<span class="sheet-header-name">NOME DA PERSONAGEM</span>
<input class="sheet-header-name-input" name="attr_character_name" type="text" spellcheck="false" placeholder="" value="">
<span class="sheet-header-pronoums">
<div class="sheet-float-left">
<input class="sheet-header-pronoums-input" name="attr_character_player" type="text" spellcheck="false" placeholder="" value=""><br>
<span>JOGADORE</span>
</div>
<div>
<input class="sheet-header-pronoums-input" name="attr_character_pronoum" type="text" spellcheck="false" placeholder="" value=""><br>
<span>PRONOMES</span>
</div>
</span>
</div>
<div class="sheet-header-middle">
<div class="sheet-header-line-inputs">
<input class="sheet-header-middle-input" name="attr_character_antecedent" type="text" spellcheck="false" placeholder="" value="">
<input class="sheet-header-middle-input" name="attr_character_legacy" type="text" spellcheck="false" placeholder="" value="">
<input class="sheet-header-middle-last-input" name="attr_character_heritage" type="text" spellcheck="false" placeholder="" value="">
</div>
<div class="sheet-header-line-label">
<span>ANTECEDENTE</span>
<span>LEGADO</span>
<span class="sheet-header-line-last-label">HERANÇA</span>
</div>
<div class="sheet-header-line-inputs">
<input class="sheet-header-middle-input" name="attr_character_curse" type="text" spellcheck="false" placeholder="" value="">
<input class="sheet-header-trail-input" name="attr_character_trilha" type="text" spellcheck="false" placeholder="" value="">
</div>
<div class="sheet-header-line-label">
<span>MALDIÇÃO</span>
<span>TRILHA</span>
</div>
<div class="sheet-header-line-inputs">
<!-- 1st Class-->
<input class="sheet-header-middle-input-level" name="attr_character_level" type="text" spellcheck="false" placeholder="1" value="1">
<input class="sheet-header-level-input-class" name="attr_character_class" type="text" spellcheck="false" placeholder="" value="">
<!--2nd Class-->
<input class="sheet-header-middle-input-level" name="attr_character_second_level" type="text" spellcheck="false" placeholder="1" value="0">
<input class="sheet-header-level-input-class" name="attr_character_second_class" type="text" spellcheck="false" placeholder="" value="">
<!--3rd Class-->
<input class="sheet-header-middle-input-level" name="attr_character_third_level" type="text" spellcheck="false" placeholder="1" value="0">
<input class="sheet-header-level-input-class" name="attr_character_third_class" type="text" spellcheck="false" placeholder="" value="">
</div>
<div class="sheet-header-line-label">
<span>NÍVEL/CLASSE</span>
<span>NÍVEL/CLASSE</span>
<span>NÍVEL/CLASSE</span>
</div>
</div>
<div class="sheet-header-right">
<div>
<div>
<div>
<span>PONTOS DE CATARSE</span>
</div>
<div>
<input class="sheet-header-right-input" name="attr_character_catarse" type="text" spellcheck="false" placeholder="" value="">
</div>
</div>
<div>
<div>
<span>PONTOS DE ENFASE</span>
</div>
<div class="sheet-header-right-stats">
<div>
<input class="sheet-header-right-input" name="attr_character_enfase_atual" type="text" spellcheck="false" placeholder="" value="">
<br>
<span>ATUAIS</span>
</div>
<div>
<input class="sheet-header-right-input" name="attr_character_enfase_final" type="text" spellcheck="false" placeholder="" value="">
<br>
<span>TOTAIS</span>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="sheet-navigation-tabs">
<label class="sheet-switch sheet-character-attributes-tab">
<input id="cstype" class="sheet-hiddenelement" type="radio" name="attr_cstype" value="0" checked>
<span class="slider round">Face</span>
</label>
<label class="sheet-switch sheet-character-characteristics-tab">
<input id="cstype" class="sheet-hiddenelement" type="radio" name="attr_cstype" value="4">
<span class="slider round">Características</span>
</label>
<label class="sheet-switch sheet-character-equipment-tab">
<input id="cstype" class="sheet-hiddenelement" type="radio" name="attr_cstype" value="3">
<span class="slider round">Equipamento</span>
</label>
<label class="sheet-switch sheet-character-actions-tab">
<input id="cstype" class="sheet-hiddenelement" type="radio" name="attr_cstype" value="1">
<span class="slider round">Habilidades</span>
</label>
<label class="sheet-switch sheet-character-spells-tab">
<input id="cstype" class="sheet-hiddenelement" type="radio" name="attr_cstype" value="2">
<span class="slider round">Magias</span>
</label>
</div>
<div class="sheet-character-attributes">
<div class="sheet-main-column">
<div class="sheet-attributes">
<div class="sheet-attribute-name">
<label>
<button type="action" name="act_setstrengthroll">
<span class="sheet-attr-span-strength"><b>t</b>FOR</span>
</button>
</label>
<label>
<button type="action" name="act_setdexterityroll">
<span class="sheet-attr-span-dexterity"><b>t</b>DES</span>
</button>
</label>
<label>
<button type="action" name="act_setconstitutionroll">
<span class="sheet-attr-span-constitution"><b>t</b>CON</span>
</button>
</label>
<label>
<button type="action" name="act_setintelligenceroll">
<span class="sheet-attr-span-intelligence"><b>t</b>INT</span>
</button>
</label>
<label>
<button type="action" name="act_setwisdomroll">
<span class="sheet-attr-span-wisdom"><b>t</b>SAB</span>
</button>
</label>
<label class="sheet-attribute-name-last">
<button type="action" name="act_setcharismaroll">
<span class="sheet-attr-span-charisma"><b>t</b>CAR</span>
</button>
</label>
</div>
<div class="sheet-attribute-value">
<input class="sheet-attribute-input" name="attr_character_strength" type="text" spellcheck="false" placeholder="" value="" type="number">
<input class="sheet-attribute-input" name="attr_character_dexterity" type="text" spellcheck="false" placeholder="" value="" type="number">
<input class="sheet-attribute-input" name="attr_character_constitution" type="text" spellcheck="false" placeholder="" value="" type="number">
<input class="sheet-attribute-input" name="attr_character_intelligence" type="text" spellcheck="false" placeholder="" value="" type="number">
<input class="sheet-attribute-input" name="attr_character_wisdom" type="text" spellcheck="false" placeholder="" value="" type="number">
<input class="sheet-attribute-input sheet-attribute-last-input" name="attr_character_charisma" type="text" spellcheck="false" placeholder="" value="" type="number">
</div>
<div class="sheet-attribute-save-checks">
<input class="sheet-attribute-save-check" type="checkbox" id="attr_save_strength_check" name="attr_save_strength_check" value="1" spellcheck="false"/>
<input class="sheet-attribute-save-check" type="checkbox" id="attr_save_dexterity_check" name="attr_save_dexterity_check" value="1" spellcheck="false"/>
<input class="sheet-attribute-save-check" type="checkbox" id="attr_save_constitution_check" name="attr_save_constitution_check" value="1" spellcheck="false"/>
<input class="sheet-attribute-save-check" type="checkbox" id="attr_save_intelligence_check" name="attr_save_intelligence_check" value="1" spellcheck="false"/>
<input class="sheet-attribute-save-check" type="checkbox" id="attr_save_wisdom_check" name="attr_save_wisdom_check" value="1" spellcheck="false"/>
<input class="sheet-attribute-save-check sheet-attribute-save-last-check" type="checkbox" id="attr_save_charisma_check" name="attr_save_charisma_check" value="1" spellcheck="false"/>
</div>
<div class="sheet-attribute-save-values">
<input class="sheet-attribute-save-value" name="attr_save_strength_show" type="text" spellcheck="false" placeholder="" value="@{save_strength_value}" type="number" disabled="true">
<input class="sheet-attribute-save-value" name="attr_save_dexterity_show" type="text" spellcheck="false" placeholder="" value="@{save_dexterity_value}" type="number" disabled="true">
<input class="sheet-attribute-save-value" name="attr_save_constitution_show" type="text" spellcheck="false" placeholder="" value="@{save_constitution_value}" type="number" disabled="true">
<input class="sheet-attribute-save-value" name="attr_save_intelligence_show" type="text" spellcheck="false" placeholder="" value="@{save_intelligence_value}" type="number" disabled="true">
<input class="sheet-attribute-save-value" name="attr_save_wisdom_show" type="text" spellcheck="false" placeholder="" value="@{save_wisdom_value}" type="number" disabled="true">
<input class="sheet-attribute-save-value sheet-attribute-save-last-value" name="attr_save_charisma_show" type="text" spellcheck="false" placeholder="" value="@{save_charisma_value}" type="number" disabled="true">
<input name="attr_save_strength_value" type="hidden">
<input name="attr_save_dexterity_value" type="hidden">
<input name="attr_save_constitution_value" type="hidden">
<input name="attr_save_intelligence_value" type="hidden">
<input name="attr_save_wisdom_value" type="hidden">
<input name="attr_save_charisma_value" type="hidden">
</div>
</div>
</div>
<div class="sheet-face-skills">
<div class="sheet-shadow-death">
<div>
<span>PONTOS DE SOMBRA</span><br>
<input type="checkbox" name="attr_shadowcheck_um" class="sheet-shadow-input"><input type="checkbox" name="attr_shadowcheck_dois" class="sheet-shadow-input"><input type="checkbox" name="attr_shadowcheck_tres" class="sheet-shadow-input"><br>
<input type="checkbox" name="attr_shadowcheck_quatro" class="sheet-shadow-input"><input type="checkbox" name="attr_shadowcheck_cinco" class="sheet-shadow-input">
</div>
<div>
<span>TESTES DE MORTE</span><br>
<input type="checkbox" class="sheet-death-input-margin" name="attr_deathcheck_um">
<input type="checkbox" class="sheet-death-input-margin" name="attr_deathcheck_dois">
<input type="checkbox" class="sheet-death-input-margin" name="attr_deathcheck_tres">
</div>
</div>
</div>
<div class="sheet-attributes-secound-part">
<div class="sheet-collumn-skills">
<div class="sheet-skills-and-languages">
<div class="sheet-skills">
<div class="sheet-skills-header">
<input class="sheet-header-middle-input sheet-proficiency" name="attr_proficient_show" type="text" spellcheck="false" disabled="true" placeholder="" value="@{proficient_bonus}">
<input name="attr_proficient_bonus" type="hidden" value="0">
<span>BÔNUS DE PROFICIÊNCIA</span>
</div>
<div class="sheet-skills-body">
<!--APRESENTAÇÃO-->
<div>
<input type="checkbox" value="1" name="attr_apresentacao_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_apresentacao_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_apresentacao_checkbox"><span>APRESENTAÇÃO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="apresentacao-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="apresentacao-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="apresentacao-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_apresentacao" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--APTIDÃO-->
<div>
<input type="checkbox" value="1" name="attr_aptidaoum_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_aptidaoum_proficiency">
<input class="sheet-rolls-flag sheet-rolls-small" type="checkbox" name="attr_aptidaoum_checkbox"><span>APTIDÃO</span>
<select name="attr_apidaoum_selectbox">
<option></option>
<option>Forja</option>
<option>Veneno</option>
<option>Pescaria</option>
<option>Alquimia</option>
<option>Destilação</option>
<option>Cartografia</option>
<option>Alfaiataria</option>
<option>Culinária</option>
<option>Pintura</option>
<option>Artesanato</option>
<option>Navegação</option>
<option>Instrumentos Musicais</option>
</select>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="aptidaoum-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="aptidaoum-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="aptidaoum-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_aptidaoum" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<div>
<input type="checkbox" value="1" name="attr_aptidaodois_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_aptidaodois_proficiency">
<input class="sheet-rolls-flag sheet-rolls-small" type="checkbox" name="attr_aptidaodois_checkbox"><span>APTIDÃO</span>
<select name="attr_apidaodois_selectbox">
<option></option>
<option>Forja</option>
<option>Veneno</option>
<option>Pescaria</option>
<option>Alquimia</option>
<option>Destilação</option>
<option>Cartografia</option>
<option>Alfaiataria</option>
<option>Culinária</option>
<option>Pintura</option>
<option>Artesanato</option>
<option>Navegação</option>
<option>Instrumentos Musicais</option>
</select>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="aptidaodois-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="aptidaodois-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="aptidaodois-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_aptidaodois" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<div>
<input type="checkbox" value="1" name="attr_aptidaotres_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_aptidaotres_proficiency">
<input class="sheet-rolls-flag sheet-rolls-small" type="checkbox" name="attr_aptidaotres_checkbox"><span>APTIDÃO</span>
<select name="attr_apidaotres_selectbox">
<option></option>
<option>Forja</option>
<option>Veneno</option>
<option>Pescaria</option>
<option>Alquimia</option>
<option>Destilação</option>
<option>Cartografia</option>
<option>Alfaiataria</option>
<option>Culinária</option>
<option>Pintura</option>
<option>Artesanato</option>
<option>Navegação</option>
<option>Instrumentos Musicais</option>
</select>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="aptidaotres-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="aptidaotres-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="aptidaotres-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_aptidaotres" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--ARCANISMO-->
<div>
<input type="checkbox" value="1" name="attr_arcanismo_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_arcanismo_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_arcanismo_checkbox"><span>ARCANISMO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="arcanismo-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="arcanismo-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="arcanismo-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_arcanismo" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--CULTURA-->
<div>
<input type="checkbox" value="1" name="attr_cultura_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_cultura_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_cultura_checkbox"><span>CULTURA</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="cultura-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="cultura-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="cultura-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_cultura" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--DOUTRINAS-->
<div>
<input type="checkbox" value="1" name="attr_doutrinas_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_doutrinas_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_doutrinas_checkbox"><span>DOUTRINAS</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="doutrinas-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="doutrinas-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="doutrinas-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_doutrinas" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--DIPLOMACIA-->
<div>
<input type="checkbox" value="1" name="attr_diplomacia_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_diplomacia_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_diplomacia_checkbox"><span>DIPLOMACIA</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="diplomacia-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="diplomacia-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="diplomacia-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_diplomacia" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--FURTIVIDADE-->
<div>
<input type="checkbox" value="1" name="attr_furtividade_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_furtividade_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_furtividade_checkbox"><span>FURTIVIDADE</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="furtividade-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="furtividade-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="furtividade-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_furtividade" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--INTIMIDAÇÃO-->
<div>
<input type="checkbox" value="1" name="attr_intimidacao_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_intimidacao_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_intimidacao_checkbox"><span>INTIMIDAÇÃO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="intimidacao-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="intimidacao-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="intimidacao-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_intimidacao" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--INTUIÇÃO-->
<div>
<input type="checkbox" value="1" name="attr_intuicao_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_intuicao_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_intuicao_checkbox"><span>INTUIÇÃO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="intuicao-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="intuicao-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="intuicao-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_intuicao" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--MEDICINA-->
<div>
<input type="checkbox" value="1" name="attr_medicina_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_medicina_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_medicina_checkbox"><span>MEDICINA</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="medicina-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="medicina-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="medicina-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_medicina" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--MAGITEC-->
<div>
<input type="checkbox" value="1" name="attr_magitec_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_magitec_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_magitec_checkbox"><span>MAGITEC</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="magitec-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="magitec-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="magitec-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_magitec" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--MALANDRAGEM-->
<div>
<input type="checkbox" value="1" name="attr_malandragem_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_malandragem_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_malandragem_checkbox"><span>MALANDRAGEM</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="malandragem-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="malandragem-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="malandragem-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_malandragem" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--MANIPULAÇÃO-->
<div>
<input type="checkbox" value="1" name="attr_manipulacao_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_manipulacao_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_manipulacao_checkbox"><span>MANIPULAÇÃO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="manipulacao-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="manipulacao-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="manipulacao-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_manipulacao" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--NATUREZA-->
<div>
<input type="checkbox" value="1" name="attr_natureza_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_natureza_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_natureza_checkbox"><span>NATUREZA</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="natureza-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="natureza-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="natureza-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_natureza" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--PERCEPÇÃO-->
<div>
<input type="checkbox" value="1" name="attr_percepcao_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_percepcao_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_percepcao_checkbox"><span>PERCEPÇÃO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="percepcao-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="percepcao-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="percepcao-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_percepcao" spellcheck="false" placeholder="0" value="0">
</div>
</div>
<!--PREPARO FÍSICO-->
<div>
<input type="checkbox" value="1" name="attr_preparofisico_especialization">
<input type="checkbox" class="sheet-big-check" value="1" name="attr_preparofisico_proficiency">
<input class="sheet-rolls-flag" type="checkbox" name="attr_preparofisico_checkbox"><span>PREPARO FÍSICO</span>
<div class="sheet-rolls">
<button title="@{Simples}" type="action" name="act_skillroll" value="preparofisico-simples">t</button>
<button title="@{Vantagem}" type="action" name="act_skillroll" value="preparofisico-vantagem">tt</button>
<button title="@{Desvantagem}" type="action" name="act_skillroll" value="preparofisico-desvantagem">TT</button>
<span>+</span>
<input type="number" name="attr_mod_preparofisico" spellcheck="false" placeholder="0" value="0">
</div>
</div>
</div>
</div>
</div>
</div>
<div class="sheet-collumn-initiative">
<div class="sheet-init-health">
<div class="sheet-initiative">
<div>
<span>INICIATIVA</span>
<input type="text" name="attr_iniciativa" class="sheet-big-box">
</div>
<div>
<span>REDUÇÃO DE DANO</span>
<input type="text" name="attr_reducaodedano_show" value="@{reducaodedano}" class="sheet-big-box" disabled="true">
<input type="hidden" name="attr_reducaodedano" value="0">
</div>
<div>
<div>
<span>DESLOCAMENTO</span>
<input type="text" name="attr_deslocamento" class="sheet-small-box">
</div>
<div>
<span>TAMANHO</span>
<input type="text" name="attr_tamanho" class="sheet-small-box">
</div>
</div>
</div>
<div class="sheet-health-and-dices">
<div>
<div>
<input type="text" name="attr_pontosdevida" class="sheet-big-box">
<span>PONTOS DE VIDA TOTAIS</span>
</div>
<div>
<input type="text" name="attr_pvtemporario" class="sheet-small-box">
<span>PV TEMP.</span>
</div>
<div>
<input type="text" name="attr_pvatuais" class="sheet-big-box">
<span>PONTOS DE VIDA ATUAIS</span>
</div>
</div>
<div class="sheet-bottom-box">
<div>
<input type="text" name="attr_dadosdevidatotais" class="sheet-big-box">
<span>DADOS DE VIDA TOTAIS</span>
</div>
<div>
<input type="text" name="attr_dadosdevidatotais" class="sheet-small-box">
<span>DADO DE VIDA</span>
</div>
<div>
<input type="text" name="attr_dadosdevidaatuais" class="sheet-big-box">
<span>DADOS DE VIDA ATUAIS</span>
</div>
</div>
</div>
</div>
</div>
<div class="sheet-collumn-language">
<div class="sheet-language">
<div class="sheet-language-intern">
<span>IDIOMAS E OUTRAS PROFICIÊNCIAS</span>
<textarea name="attr_languages"></textarea>
</div>
</div>
</div>
<div class="sheet-collumn-attack">
<div class="sheet-all-actions">
<div class="sheet-attacks">
<div class="sheet-top">
<div class="sheet-attacks-name">
<span>ATAQUE</span>
</div>
<div class="sheet-attacks-bonus">
<span>BÔNUS</span>
</div>
<div class="sheet-attacks-damage">
<span>DANO</span>
</div>
</div>
<!-- Ataques -->
<fieldset class="repeating_attacks">
<div class="sheet-attacksgrid">
<input class="sheet-options-flag" type="checkbox" name="attr_options-flag" checked="checked"><span>y</span>
<div class="sheet-options">
<div class="sheet-row">
<span class="sheet-atk-span-name">NOME:</span> <input type="text" name="attr_atkname" >
<input type="checkbox" name="attr_atkflag" value="{{attack=1}}" checked="checked" class="sheet-atk-input-flag"><span class="sheet-atk-margin-atk">ATAQUE:</span>
<select class="sheet-atk-margin-atk" name="attr_atkattr_base">
<option value="@{character_strength}" selected="selected">FOR</option>
<option value="@{character_dexterity}">DES</option>
<option value="@{character_constitution}">CON</option>
<option value="@{character_intelligence}">INT</option>
<option value="@{character_wisdom}">SAB</option>
<option value="@{character_charisma}">CAR</option>
<option value="@{spellcasting_attribute}">MAGIA</option>
<option value="0">-</option>
</select><span class="sheet-atk-plus">+</span>
<input class="sheet-num" type="text" name="attr_atkmod" placeholder="0" >
<span class="sheet-atk-plus">+</span>
<input type="checkbox" name="attr_atkprofflag" value="(@{proficient_bonus})" checked="checked" class="sheet-atk-mod">
<span class="sheet-atk-input-flag">PROFICIENCIA</span>
</div>
<div class="sheet-row">
<span class="sheet-atk-span-name">DISTÂNCIA:</span>
<input type="text" name="attr_atkrange" class="sheet-style-width-hundred-seventy">
<span class="sheet-atk-input-flag">BÔNUS MÁGICO:</span>
<input class="sheet-num" type="text" name="attr_atkmagic" placeholder="0" class="sheet-style-width-thirty">
<span class="sheet-atk-input-flag">CRÍTICO:</span>
<input class="sheet-num" type="text" name="attr_atkcritrange" value="20" placeholder="20" class="sheet-style-width-thirty">
</div>
<div class="sheet-row">
<input type="checkbox" name="attr_dmgflag" value="{{damage=1}} {{dmg1flag=1}}" checked="checked">
<span class="sheet-atk-span-two-name">DANO:</span>
<input type="text" name="attr_dmgbase" placeholder="1d6" class="sheet-style-width-fifty">
<span class="sheet-font-size-twenty">+</span>
<select name="attr_dmgattr">
<option value="@{character_strength}" selected="selected">FOR</option>
<option value="@{character_dexterity}">DES</option>
<option value="@{character_constitution}">CON</option>
<option value="@{character_intelligence}">INT</option>
<option value="@{character_wisdom}">SAB</option>
<option value="@{character_charisma}">CAR</option>
<option value="@{spellcasting_attribute}">MAGIA</option>
<option value="0">-</option>
</select>
<span class="sheet-font-size-twenty">+</span>
<input class="sheet-num" type="text" name="attr_dmgmod" placeholder="0" class="sheet-style-width-thirty">
<span class="sheet-font-size-seventeen">TIPO:</span>
<input type="text" name="attr_dmgtype" placeholder="Corte" class="sheet-style-width-hundred">
<span>CRIT:</span>
<input type="text" name="attr_dmgcustcrit" placeholder="1d6" class="sheet-style-width-fifty">
</div>
<div class="sheet-row">
<input type="checkbox" name="attr_dmg2flag" value="{{damage=1}} {{dmg2flag=1}}"><span class="sheet-dmg-two">DANO 2:</span>
<input type="text" name="attr_dmg2base" placeholder="1d6" class="sheet-style-width-fifty">
<span class="sheet-font-size-twenty">+</span>
<select name="attr_dmg2attr">
<option value="@{character_strength}" selected="selected">FOR</option>
<option value="@{character_dexterity}">DES</option>
<option value="@{character_constitution}">CON</option>
<option value="@{character_intelligence}">INT</option>
<option value="@{character_wisdom}">SAB</option>
<option value="@{character_charisma}">CAR</option>
<option value="@{spellcasting_attribute}">MAGIA</option>
<option value="0">-</option>
</select>
<span class="sheet-font-size-twenty">+</span>
<input class="sheet-num" type="text" name="attr_dmg2mod" placeholder="0" class="sheet-style-width-thirty">
<span class="sheet-font-size-seventeen">TIPO:</span>
<input type="text" name="attr_dmg2type" placeholder="Slashing" class="sheet-style-width-hundred">
<span>CRIT:</span>
<input type="text" name="attr_dmg2custcrit" placeholder="1d6" class="sheet-style-width-fifty">
</div>
<div class="sheet-row">
<span>MUNIÇÃO:</span>
<input type="text" name="attr_ammo" placeholder="Flechas" class="sheet-style-width-hundred-seventy">
</div>
<div class="sheet-row">
<span>DESCRIÇÃO:</span>
<textarea name="attr_atk_desc" placeholder="Descrição"></textarea>
</div>
</div>
<div class="sheet-display sheet-display-attack">
<button type="roll" name="roll_attack" value="@{rollbase}">
<span name="attr_atkname" class="sheet-atk-name-span"></span>
<input type="text" name="attr_atkbonus" class="sheet-atk-bonus-span" value="">
<input type="text" name="attr_atkdmgtype" class="sheet-atk-dmg-span" value="">
</button>
</div>
<input type="hidden" name="attr_rollbase">
<input type="hidden" name="attr_rollbase_dmg">
<input type="hidden" name="attr_rollbase_crit">
<input type="hidden" name="attr_hldmg">
<input type="hidden" name="attr_spelllevel">
<input type="hidden" name="attr_itemid">
<input type="hidden" name="attr_spellid">
<input type="hidden" name="attr_spell_innate">
<input type="hidden" name="attr_versatile_alt">
<input type="hidden" name="attr_spelldesc_link">
<button type="roll" name="roll_spelldesc_link" value="@{spelldesc_link}" class="sheet-hiddenelement btn ui-draggable"></button>
<button type="roll" name="roll_attack_dmg" value="@{rollbase_dmg}" class="sheet-hiddenelement btn ui-draggable"></button>
<button type="roll" name="roll_attack_crit" value="@{rollbase_crit}" class="sheet-hiddenelement btn ui-draggable"></button>
<button type="roll" name="roll_reroll" class="sheet-hiddenelement" value="@{rollbase}"></button>
</div>
</fieldset>
<!-- Ataques -->
</div>
</div>
</div>
</div>
<!--div>
<div class="sheet-main-column-right-collumn">
<!--/div>
</div>
<div class="sheet-face-skills">
</div>
<div class="sheet-all-actions">
<div class="sheet-attacks">
</div>
</div-->
</div>
<div class="sheet-characteristics">
<div class="sheet-character-background">
<div class="sheet-characteristics-base">
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_legacy}}} {{description=@{descriptionlegacy}}}">
<span>LEGADO</span>
</button>
<input name="attr_character_legacy" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptionlegacy"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_heritage}}} {{description=@{descriptionheritage}}}">
<span>HERANÇAS</span>
</button>
<input name="attr_character_heritage" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptionheritage"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_antecedent}}} {{description=@{descriptionantecedent}}}">
<span>ANTECEDENTE</span>
</button>
<input name="attr_character_antecedent" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptionantecedent"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_curse}}} {{description=@{descriptioncurse}}}">
<span>MALDIÇÃO</span>
</button>
<input name="attr_character_curse" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptioncurse"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_melancholy}}} {{description=@{descriptionmelancholy}}}">
<span>MELANCOLIA</span>
</button>
<input name="attr_character_melancholy" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptionmelancholy"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_trilha}}} {{description=@{descriptiontrilha}}}">
<span>TRILHA</span>
</button>
<input name="attr_character_trilha" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptiontrilha"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_class}}} {{description=@{descriptionclass}}}">
<span>CLASSE</span>
</button>
<input name="attr_character_class" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_descriptionclass"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_second_class}}} {{description=@{description_second_class}}}">
<span>CLASSE</span>
</button>
<input name="attr_character_second_class" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_description_second_class"></textarea>
</div>
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{character_third_class}}} {{description=@{description_third_class}}}">
<span>CLASSE</span>
</button>
<input name="attr_character_third_class" type="text" spellcheck="false" placeholder="" value="">
</div>
<textarea name="attr_description_third_class"></textarea>
</div>
</div>
<fieldset class="repeating_characteristics">
<div class="sheet-textbox-div">
<div>
<button type="roll" name="roll_attack" value="&{template:characteristic} {{character_name=@{character_name}}} {{name=@{nomecharacteristics}}} {{description=@{descriptioncharacteristics}}}">
</button>
<input name="attr_nomecharacteristics" type="text" spellcheck="false" class="" value="">
</div>
<textarea name="attr_descriptioncharacteristics"></textarea>
</div>
</fieldset>
</div>
</div>
<div class="sheet-character-equipment">
<div class="sheet-money-others">
<div class="sheet-number-slots">
<div class="sheet-slots-header">
<span>Volume de Carga</span>
</div>
<div class="sheet-slots">
<div>
<input name="attr_volumeatual_show" type="number" value="@{volumeatual}" disabled="true">
<input name="attr_volumeatual" type="hidden" value="0">
<span>Atual</span>
</div>
<div>
<input name="attr_volumeextra" type="number" value="0" >
<span>Extra</span>
</div>
<div class="sheet-border-none">
<input name="attr_volumelimite_show" type="number" value="@{volumelimite}+@{volumeextra}" disabled="true">
<input name="attr_volumelimite" type="hidden">
<span>Limite</span>
</div>
</div>
</div>
<div class="sheet-magic-volumes">
<div class="sheet-fragment-header">
<span>Fragmentos Arcanos</span>
</div>
<div class="sheet-fragments">
<div>
<input name="attr_fragmentosatual_show" type="number" disabled="true" value="@{fragmentosatual}">
<input name="attr_fragmentosatual" type="hidden" value="0">
<span>Atual</span>
</div>
<div class="sheet-border-none">
<input name="attr_fragmentolimite_show" type="number" disabled="true" value="@{character_charisma} + (@{proficient_bonus} * 2)">
<input name="attr_fragmentolimite" type="hidden">
<span>Limite</span>
</div>
</div>
</div>
<div class="sheet-money">
<div>
<input name="attr_trocado" type="text" spellcheck="false"> <span>Trocado (T$)</span>
</div>
<div>
<input name="attr_pila" type="text" spellcheck="false"> <span>Pilar (P$)</span>
</div>
<div>
<input name="attr_kilo" type="text" spellcheck="false"> <span>K's (K$)</span>
</div>
</div>
</div>
<div class="sheet-equipment">
<fieldset class="repeating_equipment">
<div class="sheet-container-equipment">
<div>
<input name="attr_nomeequipamento" type="text" spellcheck="false" class="sheet-equip-name" value="" placeholder="NOME">
<select name="attr_tipoequipamento" class="sheet-equip-type">
<option>-</option>
<option>Arma</option>
<option>Armadura</option>
<option>Escudo</option>
</select>
</div>
<input type="checkbox" class="sheet-hiddencheckbox">
<span class="sheet-hiddencheckboxcover sheet-negat-right">y</span>
<div class="sheet-extra sheet-width-sheet-extra">
<div class="sheet-small-boxes">
<input name="attr_volumeequipamento" type="text" spellcheck="false" class="sheet-equip-vol" value="" placeholder="VOL">
<input name="attr_fragmentoequipamento" type="text" spellcheck="false" class="sheet-equip-frag" value="" placeholder="FRAG">
<input name="attr_reducaoequipamento" type="text" spellcheck="false" class="sheet-equip-rd" value="" placeholder="RD">
</div>
<div class="sheet-text-box">
<textarea name="attr_descriptionequipamento" placeholder="DESCRIÇÃO"></textarea>
</div>
<!--1 Sigílo-->
<label class="sheet-sigilo-label">Sigílo</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal" name="attr_sigilocheckum">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal">
<input name="attr_sigilo" type="text" spellcheck="false" class="sheet-equip-rd" placeholder="Nome">
<textarea name="attr_descritorsigiloum" placeholder="Descritores"></textarea>
<textarea name="attr_efeitosigiloum" placeholder="Efeito"></textarea>
<textarea name="attr_imbuindofragmentoum" placeholder="Imbuindo fragmento"></textarea>
</div>
<!--2 Sigílo-->
<label class="sheet-sigilo-label-two">Sigílo</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-two" name="attr_sigilocheckdois">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-two">
<input name="attr_sigilo" type="text" spellcheck="false" class="sheet-equip-rd" placeholder="Nome">
<textarea name="attr_descritorsigilodois" placeholder="Descritores"></textarea>
<textarea name="attr_efeitosigilodois" placeholder="Efeito"></textarea>
<textarea name="attr_imbuindofragmentodois" placeholder="Imbuindo fragmento"></textarea>
</div>
<!--3 Sigílo-->
<label class="sheet-sigilo-label-three">Sigílo</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-three" name="attr_sigilochecktres">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-three">
<input name="attr_sigilo" type="text" spellcheck="false" class="sheet-equip-rd" placeholder="Nome">
<textarea name="attr_descritorsigilotres" placeholder="Descritores"></textarea>
<textarea name="attr_efeitosigilotres" placeholder="Efeito"></textarea>
<textarea name="attr_imbuindofragmentotres" placeholder="Imbuindo fragmento"></textarea>
</div>
<!--4 Sigílo-->
<label class="sheet-sigilo-label-four">Sigílo</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-four" name="attr_sigilocheckquatro">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-four">
<input name="attr_sigilo" type="text" spellcheck="false" class="sheet-equip-rd" placeholder="Nome">
<textarea name="attr_descritorsigiloquatro" placeholder="Descritores"></textarea>
<textarea name="attr_efeitosigiloquatro" placeholder="Efeito"></textarea>
<textarea name="attr_imbuindofragmentoquatro" placeholder="Imbuindo fragmento"></textarea>
</div>
</div>
</div>
</fieldset>
</div>
</div>
<div class="sheet-character-actions">
<div class="sheet-actions">
<fieldset class="repeating_actions">
<div class="sheet-container-single-spell">
<div class="sheet-style-acao">
<input type="hidden" class="sheet-tipoacaoshow" name="attr_tipoacaoshow" value="" >
<img class="sheet-img-acao"/>
<img class="sheet-img-bonus"/>
<img class="sheet-img-livre"/>
<img class="sheet-img-passiva"/>
<img class="sheet-img-reacao"/>
</div>
<button type="roll" name="roll_spell1" class="sheet-buttonspell"
value="&{template:actspell} {{character_name=@{character_name}}} {{tipoacao=@{tipoacao}}} {{nameaction=@{nameaction}}} {{custoacao=@{custoacao}}} {{info_actions=@{info_actions}}} {{descritores_actions=@{descritores_actions}}} {{alcance_actions=@{alcance_actions}}} {{alvo_actions=@{alvo_actions}}} {{duracao_actions=@{duracao_actions}}} {{component_actions=@{component_actions}}} {{gatilho_actions=@{gatilho_actions}}} {{ataque_actions=@{ataque_actions}}} {{acerto_actions=@{acerto_actions}}} {{erro_actions=@{erro_actions}}} {{efeito_actions=@{efeito_actions}}} {{especial_actions=@{especial_actions}}} {{customod_actions=@{customod_actions}}} {{tipomod_actions=@{tipomod_actions}}} {{description_actions=@{description_actions}}} {{modificacoes=@{modcheckone}@{modchecktwo}@{modcheckthree}@{modcheckfour}@{modcheckfive}@{modchecksix}@{modcheckseven}@{modcheckeigth}@{modchecknine}@{modcheckten}}} {{customodtwo=@{customodtwo_actions}}} {{tipomodtwo=@{tipomodtwo_actions}}} {{descriptiontwo=@{descriptiontwo_actions}}} {{customodthree=@{customodthree_actions}}} {{tipomodthree=@{tipomodthree_actions}}} {{descriptionthree=@{descriptionthree_actions}}} {{customodfour=@{customodfour_actions}}} {{tipomodfour=@{tipomodfour_actions}}} {{descriptionfour=@{descriptionfour_actions}}} {{customodfive=@{customodfive_actions}}} {{tipomodfive=@{tipomodfive_actions}}} {{descriptionfive=@{descriptionfive_actions}}} {{customodsix=@{customodsix_actions}}} {{tipomodsix=@{tipomodsix_actions}}} {{descriptionsix=@{descriptionsix_actions}}} {{customodseven=@{customodseven_actions}}} {{tipomodseven=@{tipomodseven_actions}}} {{descriptionseven=@{descriptionseven_actions}}} {{customodeigth=@{customodeigth_actions}}} {{tipomodeigth=@{tipomodeigth_actions}}} {{descriptioneigth=@{descriptioneigth_actions}}} {{customodnine=@{customodnine_actions}}} {{tipomodnine=@{tipomodnine_actions}}} {{descriptionnine=@{descriptionnine_actions}}} {{customodten=@{customodten_actions}}} {{tipomodten=@{tipomodten_actions}}} {{descriptionten=@{descriptionten_actions}}} {{modcheckone=[[@{modcheckone}]]}} {{modchecktwo=[[@{modchecktwo}]}} {{{modcheckthree}=[[@{modcheckthree}]}} {{{modcheckfour}=[[@{modcheckfour}]}} {{{modcheckfive}=[[@{modcheckfive}]}} {{{modchecksix}=[[@{modchecksix}]}} {{{modcheckseven}=[[@{modcheckseven}]}} {{{modcheckeigth}=[[@{modcheckeigth}]}} {{{modchecknine}=[[@{modchecknine}]}} {{{modcheckten=}[[@{modcheckten}]}} ">
<span class="sheet-name-action" name="attr_nameactionshow" value="@{nameaction}"></span>
</button>
<span name="attr_custoacaoshow" value="@{custoacao}" class="sheet-custo-header"></span>
<input type="checkbox" class="sheet-hiddencheckbox">
<span class="sheet-hiddencheckboxcover">y</span>
<div class="sheet-extra">
<select class="sheet-tipoacao" name="attr_tipoacao">
<option value="Acao">Ação</option>
<option value="Bonus">Bônus</option>
<option value="Livre">Livre</option>
<option value="Passiva">Passiva</option>
<option value="Reacao">Reação</option>
</select>
<input class="sheet-nomeacao" name="attr_nameaction" type="text" spellcheck="false" value="" placeholder="Nome do Poder"/>
<select class="sheet-custoacao" name="attr_custoacao">
<option value="-" selected>-</option>
<option value="rep">Rep</option>
<option value="1PE">1 PE</option>
<option value="2PE">2 PE</option>
<option value="3PE">3 PE</option>
<option value="4PE">4 PE</option>
<option value="5PE">5 PE</option>
</select>
<div class="sheet-even">
<span>Informações</span>
<input type="text" name="attr_info_actions" spellcheck="false" value="">
</div>
<div class="sheet-odd">
<span>Descritores:</span>
<input type="text" class="sheet-descriptor-input" name="attr_descritores_actions">
</div>
<div class="sheet-even">
<div><span>Alcance:</span> <input name="attr_alcance_actions" type="text" spellcheck="false" value=""></div>
<div><span>Alvo:</span> <input name="attr_alvo_actions" type="text" spellcheck="false" value=""></div>
<div><span>Duração:</span> <input name="attr_duracao_actions" type="text" spellcheck="false" value=""></div>
<div><span>Componentes:</span> <input name="attr_component_actions" type="text" spellcheck="false" value=""></div>
</div>
<div class="sheet-odd">
<div><span>Gatilho:</span> <input name="attr_gatilho_actions" type="text" spellcheck="false" value=""></div>
</div>
<div class="sheet-even"><span>Ataque:</span> <input name="attr_ataque_actions" type="text" spellcheck="false" value=""></div>
<div class="sheet-odd"><span>Acerto:</span> <input name="attr_acerto_actions" type="text" spellcheck="false" value=""></div>
<div class="sheet-even"><span>Erro:</span> <input name="attr_erro_actions" type="text" spellcheck="false" value=""></div>
<div class="sheet-odd"><span>Efeito:</span> <textarea class="sheet-effect-textarea" name="attr_efeito_actions" type="text" spellcheck="false" value=""></textarea></div>
<div class="sheet-odd"><span>Especial:</span> <textarea name="attr_especial_actions" type="text" spellcheck="false" value=""></textarea></div>
<div class="sheet-even">
<!--1 Modificação-->
<label class="sheet-sigilo-label">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal" name="attr_modcheckone" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal">
<span>Custo da Modificação</span> <input name="attr_customod_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomod_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_description_actions"></textarea>
</div>
<!--2 Modificação-->
<label class="sheet-sigilo-label-two">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-two" name="attr_modchecktwo" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-two">
<span>Custo da Modificação</span> <input name="attr_customodtwo_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodtwo_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptiontwo_actions"></textarea>
</div>
<!--3 Modificação-->
<label class="sheet-sigilo-label-three">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-three" name="attr_modcheckthree" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-three">
<span>Custo da Modificação</span> <input name="attr_customodthree_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodthree_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionthree_actions"></textarea>
</div>
<!--4 Modificação-->
<label class="sheet-sigilo-label-four">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-four" name="attr_modcheckfour" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-four">
<span>Custo da Modificação</span> <input name="attr_customodfour_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodfour_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionfour_actions"></textarea>
</div>
<!--5 Modificação-->
<label class="sheet-sigilo-label-five">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-five" name="attr_modcheckfive" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-five">
<span>Custo da Modificação</span> <input name="attr_customodfive_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodfive_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionfive_actions"></textarea>
</div>
<!--6 Modificação-->
<label class="sheet-sigilo-label-six">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-six" name="attr_modchecksix" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-six">
<span>Custo da Modificação</span> <input name="attr_customodsix_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodsix_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionsix_actions"></textarea>
</div>
<!--7 Modificação-->
<label class="sheet-sigilo-label-seven" >Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-seven" name="attr_modcheckseven" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-seven">
<span>Custo da Modificação</span> <input name="attr_customodseven_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodseven_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionseven_actions"></textarea>
</div>
<!--8 Modificação-->
<label class="sheet-sigilo-label-eigth" >Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-eigth" name="attr_modcheckeigth" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-eigth">
<span>Custo da Modificação</span> <input name="attr_customodeigth_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodeigth_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptioneigth_actions"></textarea>
</div>
<!--9 Modificação-->
<label class="sheet-sigilo-label-nine">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-nine" name="attr_modchecknine" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-nine">
<span>Custo da Modificação</span> <input name="attr_customodnine_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodnine_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionnine_actions"></textarea>
</div>
<!--10 Modificação-->
<label class="sheet-sigilo-label-ten">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-ten" name="attr_modcheckten" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-ten">
<span>Custo da Modificação</span> <input name="attr_customodten_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodten_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionten_actions"></textarea>
</div>
</div>
</div>
<div class="sheet-extra-body">
<div class="sheet-extra-div sheet-bg-padding"><span name="attr_descritores_show" class="sheet-descriptor-show" ></span></div>
<div class="sheet-extra-div"><span name="attr_informacoes_show"></span></div>
<div class="sheet-extra-div"><label>Alcance: </label><span name="attr_alcance_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Alvo: </label><span name="attr_alvo_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Duração: </label><span name="attr_duracao_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Componentes: </label><span name="attr_component_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Gatilho: </label><span name="attr_gatilho_show"></span></div>
<div class="sheet-extra-div"><label>Ataque: </label><span name="attr_ataque_show"></span></div>
<div class="sheet-extra-div"><label>Acerto: </label><span name="attr_acerto_show"></span></div>
<div class="sheet-extra-div"><label>Erro: </label><span name="attr_erro_show"></span></div>
<div class="sheet-extra-div"><label>Efeito: </label><span name="attr_efeito_show"></span></div>
<div class="sheet-extra-div"><label>Especial: </label><span name="attr_especial_show"></span></div>
<!--1 Mod-->
<div class="sheet-extra-div">
<span name="attr_customod_show"></span> <span name="attr_tipomod_show"></span> <span name="attr_description_show"></span>
</div>
<!--2 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodtwo_show"></span> <span name="attr_tipomodtwo_show"></span> <span name="attr_descriptiontwo_show"></span>
</div>
<!--3 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodthree_show"></span> <span name="attr_tipomodthree_show"></span> <span name="attr_descriptionthree_show"></span>
</div>
<!--4 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodfour_show"></span> <span name="attr_tipomodfour_show"></span> <span name="attr_descriptionfour_show"></span>
</div>
<!--5 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodfive_show"></span> <span name="attr_tipomodfive_show"></span> <span name="attr_descriptionfive_show"></span>
</div>
<!--6 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodsix_show"></span> <span name="attr_tipomodsix_show"></span> <span name="attr_descriptionsix_show"></span>
</div>
<!--7 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodseven_show" ></span> <span name="attr_tipomodseven_show"></span> <span name="attr_descriptionseven_show"></span>
</div>
<!--8 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodeigth_show"></span> <span name="attr_tipomodeigth_show"></span> <span name="attr_descriptioneigth_show"></span>
</div>
<!--9 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodnine_show"></span> <span name="attr_tipomodnine_show"></span> <span name="attr_descriptionnine_show"></span>
</div>
<!--10 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodten_show"></span> <span name="attr_tipomodten_show"></span> <span name="attr_descriptionten_show"></span></div>
</div>
</div>
<input type="hidden" value="" name="attr_rollaction">
</fieldset>
</div>
</div>
<div class="sheet-character-spells">
<div class="sheet-spells">
<div class="sheet-spells-atributes">
<div>
<span>ATRIBUTO CHAVE</span>
<select class="sheet-camada" name="attr_spellcasting_attribute">
<option value="@{character_strength}">Força</option>
<option value="@{character_dexterity}">Destreza</option>
<option value="@{character_constitution}">Constituição</option>
<option value="@{character_intelligence}">Inteligência</option>
<option value="@{character_wisdom}">Sabedoria</option>
<option value="@{character_charisma}">Carisma</option>
</select>
</div>
<div>
<span>BÔNUS DE ATAQUE</span>
<input class="singleline" name="attr_bonusataquemagia" type="number" spellcheck="false" value="(@{spellcasting_attribute})+(@{proficient_bonus})" disabled="true"/>
</div>
</div>
<div class="sheet-spells-container">
<fieldset class="repeating_spells">
<div class="sheet-container-single-spell">
<div class="sheet-style-acao">
<input type="hidden" class="sheet-tipoacaoshow" name="attr_tipoacaoshow" value="" >
<img class="sheet-img-acao" />
<img class="sheet-img-bonus"/>
<img class="sheet-img-livre" />
<img class="sheet-img-passiva" />
<img class="sheet-img-reacao" />
</div>
<button type="roll" name="roll_spell1" class="sheet-buttonspell" value="&{template:actspell} {{character_name=@{character_name}}} {{tipoacao=@{tipoacao}}} {{nameaction=@{nameaction}}} {{custoacao=@{custoacao}}} {{info_actions=@{info_spells}}} {{descritores_actions=@{descritores_actions}}} {{alcance_actions=@{alcance_spells}}} {{alvo_actions=@{alvo_spells}}} {{duracao_actions=@{duracao_spells}}} {{component_actions=@{component_spells}}} {{gatilho_actions=@{gatilho_spells}}} {{ataque_actions=@{ataque_spells}}} {{acerto_actions=@{acerto_spells}}} {{erro_actions=@{erro_spells}}} {{efeito_actions=@{efeito_spells}}} {{especial_actions=@{especial_actions}}} {{customod_actions=@{customod_actions}}} {{tipomod_actions=@{tipomod_actions}}} {{description_actions=@{description_actions}}} {{modificacoes=@{modcheckone}@{modchecktwo}@{modcheckthree}@{modcheckfour}@{modcheckfive}@{modchecksix}@{modcheckseven}@{modcheckeigth}@{modchecknine}@{modcheckten}}} {{customodtwo=@{customodtwo_actions}}} {{tipomodtwo=@{tipomodtwo_actions}}} {{descriptiontwo=@{descriptiontwo_actions}}} {{customodthree=@{customodthree_actions}}} {{tipomodthree=@{tipomodthree_actions}}} {{descriptionthree=@{descriptionthree_actions}}} {{customodfour=@{customodfour_actions}}} {{tipomodfour=@{tipomodfour_actions}}} {{descriptionfour=@{descriptionfour_actions}}} {{customodfive=@{customodfive_actions}}} {{tipomodfive=@{tipomodfive_actions}}} {{descriptionfive=@{descriptionfive_actions}}} {{customodsix=@{customodsix_actions}}} {{tipomodsix=@{tipomodsix_actions}}} {{descriptionsix=@{descriptionsix_actions}}} {{customodseven=@{customodseven_actions}}} {{tipomodseven=@{tipomodseven_actions}}} {{descriptionseven=@{descriptionseven_actions}}} {{customodeigth=@{customodeigth_actions}}} {{tipomodeigth=@{tipomodeigth_actions}}} {{descriptioneigth=@{descriptioneigth_actions}}} {{customodnine=@{customodnine_actions}}} {{tipomodnine=@{tipomodnine_actions}}} {{descriptionnine=@{descriptionnine_actions}}} {{customodten=@{customodten_actions}}} {{tipomodten=@{tipomodten_actions}}} {{descriptionten=@{descriptionten_actions}}} {{modcheckone=[[@{modcheckone}]]}} {{modchecktwo=[[@{modchecktwo}]}} {{{modcheckthree}=[[@{modcheckthree}]}} {{{modcheckfour}=[[@{modcheckfour}]}} {{{modcheckfive}=[[@{modcheckfive}]}} {{{modchecksix}=[[@{modchecksix}]}} {{{modcheckseven}=[[@{modcheckseven}]}} {{{modcheckeigth}=[[@{modcheckeigth}]}} {{{modchecknine}=[[@{modchecknine}]}} {{{modcheckten=}[[@{modcheckten}]}} ">
<span class="sheet-name-action" name="attr_nameactionshow" value="@{nameaction}"></span>
</button>
<span name="attr_custoacaoshow" value="@{custoacao}" class="sheet-custo-header"></span>
<input type="checkbox" class="sheet-hiddencheckbox">
<span class="sheet-hiddencheckboxcover">y</span>
<div class="sheet-extra">
<select class="sheet-tipoacao" name="attr_tipoacao">
<option value="Acao">Ação</option>
<option value="Bonus">Bônus</option>
<option value="Livre">Livre</option>
<option value="Passiva">Passiva</option>
<option value="Reacao">Reação</option>
</select>
<input class="sheet-nomeacao" name="attr_nameaction" type="text" spellcheck="false" value="" placeholder="Nome do Poder"/>
<select class="sheet-custoacao" name="attr_custoacao">
<option value="-" selected>-</option>
<option value="rep">Rep</option>
<option value="1PE">1 PE</option>
<option value="2PE">2 PE</option>
<option value="3PE">3 PE</option>
<option value="4PE">4 PE</option>
<option value="5PE">5 PE</option>
</select>
<div class="sheet-even">
<span>Informações</span>
<input type="text" name="attr_info_spells">
</div>
<div class="sheet-odd">
<span>Descritores:</span>
<input type="text" class="sheet-descriptor-input" name="attr_descritores_actions">
</div>
<div class="sheet-even">
<div><span>Alcance:</span> <input name="attr_alcance_spells" type="text" spellcheck="false" value=""></div>
<div><span>Alvo:</span> <input name="attr_alvo_spells" type="text" spellcheck="false" value=""></div>
<div><span>Duração:</span> <input name="attr_duracao_spells" type="text" spellcheck="false" value=""></div>
<div><span>Componentes:</span> <input name="attr_component_spells" type="text" spellcheck="false" value=""></div>
</div>
<div class="sheet-odd">
<div><span>Gatilho:</span> <input name="attr_gatilho_spells" type="text" spellcheck="false" value=""></div>
</div>
<div class="sheet-even"><span>Ataque:</span> <input name="attr_ataque_spells" type="text" spellcheck="false" value=""></div>
<div class="sheet-odd"><span>Acerto:</span> <input name="attr_acerto_spells" type="text" spellcheck="false" value=""></div>
<div class="sheet-even"><span>Erro:</span> <input name="attr_erro_spells" type="text" spellcheck="false" value=""></div>
<div class="sheet-odd"><span>Efeito:</span> <textarea class="sheet-effect-textarea" name="attr_efeito_spells" type="text" spellcheck="false" value=""></textarea></div>
<div class="sheet-odd"><span>Especial:</span> <textarea name="attr_especial_actions" type="text" spellcheck="false" value=""></textarea></div>
<div class="sheet-even">
<!--1 Modificação-->
<label class="sheet-sigilo-label">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal" name="attr_modcheckone" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal">
<span>Custo da Modificação</span> <input name="attr_customod_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomod_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_description_actions"></textarea>
</div>
<!--2 Modificação-->
<label class="sheet-sigilo-label-two">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-two" name="attr_modchecktwo" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-two">
<span>Custo da Modificação</span> <input name="attr_customodtwo_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodtwo_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptiontwo_actions"></textarea>
</div>
<!--3 Modificação-->
<label class="sheet-sigilo-label-three">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-three" name="attr_modcheckthree" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-three">
<span>Custo da Modificação</span> <input name="attr_customodthree_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodthree_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionthree_actions"></textarea>
</div>
<!--4 Modificação-->
<label class="sheet-sigilo-label-four">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-four" name="attr_modcheckfour" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-four">
<span>Custo da Modificação</span> <input name="attr_customodfour_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodfour_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionfour_actions"></textarea>
</div>
<!--5 Modificação-->
<label class="sheet-sigilo-label-five">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-five" name="attr_modcheckfive" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-five">
<span>Custo da Modificação</span> <input name="attr_customodfive_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodfive_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionfive_actions"></textarea>
</div>
<!--6 Modificação-->
<label class="sheet-sigilo-label-six">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-six" name="attr_modchecksix" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-six">
<span>Custo da Modificação</span> <input name="attr_customodsix_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodsix_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionsix_actions"></textarea>
</div>
<!--7 Modificação-->
<label class="sheet-sigilo-label-seven">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-seven" name="attr_modcheckseven" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-seven">
<span>Custo da Modificação</span> <input name="attr_customodseven_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodseven_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionseven_actions"></textarea>
</div>
<!--8 Modificação-->
<label class="sheet-sigilo-label-eigth">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-eigth" name="attr_modcheckeigth" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-eigth">
<span>Custo da Modificação</span> <input name="attr_customodeigth_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodeigth_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptioneigth_actions"></textarea>
</div>
<!--9 Modificação-->
<label class="sheet-sigilo-label-nine">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-nine" name="attr_modchecknine" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-nine">
<span>Custo da Modificação</span> <input name="attr_customodnine_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodnine_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionnine_actions"></textarea>
</div>
<!--10 Modificação-->
<label class="sheet-sigilo-label-ten">Modificação:</label>
<input type="checkbox" class="sheet-hiddencheckbox-internal-ten" name="attr_modcheckten" value="1">
<!--<span class="sheet-hiddencheckboxcover-internal">y</span>-->
<div class="sheet-extra-internal-ten">
<span>Custo da Modificação</span> <input name="attr_customodten_actions" type="text" spellcheck="false" value="">
<span>Tipo de Modificação</span> <input name="attr_tipomodten_actions" type="text" spellcheck="false" value="">
<textarea class="sheet-modificator-textarea" name="attr_descriptionten_actions"></textarea>
</div>
</div>
</div>
<div class="sheet-extra-body">
<div class="sheet-extra-div sheet-bg-padding"><span name="attr_descritores_show" class="sheet-descriptor-show" ></span></div>
<div class="sheet-extra-div"><span name="attr_informacoes_show"></span></div>
<div class="sheet-extra-div"><label>Alcance: </label><span name="attr_alcance_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Alvo: </label><span name="attr_alvo_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Duração: </label><span name="attr_duracao_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Componentes: </label><span name="attr_component_show" placeholder="descritores"></span></div>
<div class="sheet-extra-div"><label>Gatilho: </label><span name="attr_gatilho_show"></span></div>
<div class="sheet-extra-div"><label>Ataque: </label><span name="attr_ataque_show"></span></div>
<div class="sheet-extra-div"><label>Acerto: </label><span name="attr_acerto_show"></span></div>
<div class="sheet-extra-div"><label>Erro: </label><span name="attr_erro_show"></span></div>
<div class="sheet-extra-div"><label>Efeito: </label><span name="attr_efeito_show"></span></div>
<div class="sheet-extra-div"><label>Especial: </label><span name="attr_especial_show"></span></div>
<!--1 Mod-->
<div class="sheet-extra-div">
<span name="attr_customod_show"></span> <span name="attr_tipomod_show"></span> <span name="attr_description_show"></span>
</div>
<!--2 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodtwo_show"></span> <span name="attr_tipomodtwo_show"></span> <span name="attr_descriptiontwo_show"></span>
</div>
<!--3 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodthree_show"></span> <span name="attr_tipomodthree_show"></span> <span name="attr_descriptionthree_show"></span>
</div>
<!--4 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodfour_show"></span> <span name="attr_tipomodfour_show"></span> <span name="attr_descriptionfour_show"></span>
</div>
<!--5 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodfive_show"></span> <span name="attr_tipomodfive_show"></span> <span name="attr_descriptionfive_show"></span>
</div>
<!--6 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodsix_show"></span> <span name="attr_tipomodsix_show"></span> <span name="attr_descriptionsix_show"></span>
</div>
<!--7 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodseven_show" ></span> <span name="attr_tipomodseven_show"></span> <span name="attr_descriptionseven_show"></span>
</div>
<!--8 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodeigth_show"></span> <span name="attr_tipomodeigth_show"></span> <span name="attr_descriptioneigth_show"></span>
</div>
<!--9 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodnine_show"></span> <span name="attr_tipomodnine_show"></span> <span name="attr_descriptionnine_show"></span>
</div>
<!--10 Mod-->
<div class="sheet-extra-div">
<span name="attr_customodten_show"></span> <span name="attr_tipomodten_show"></span> <span name="attr_descriptionten_show"></span></div>
</div>
</div>
</fieldset>
</div>
</div>
</div>
</div>
<input type="hidden" name="attr_selectedattribute" value="" readonly="1">
<input type="hidden" name="attr_selectedrawvalue" value="" readonly="1">
<input type="hidden" name="attr_rawattribute" value="" readonly="1">
<button type="roll" name="roll_reroll" class="sheet-hiddenelement" value="@{rawroll}"></button>
<input type="hidden" name="attr_rawroll" value="" readonly="1">
<script type="text/worker">
let calc_proficiency = function() {
getAttrs(["character_level", "character_second_level", "character_third_level", "proficient_bonus"], function(v){
let proficiency = 2;
let total_level = convert_to_int(v.character_level) + convert_to_int(v.character_second_level) + convert_to_int(v.character_third_level);
if(total_level > 4){
proficiency = +3;
}
if(total_level > 8){
proficiency = +4;
}
setAttrs({["proficient_bonus"]:proficiency})
update_attacks("all");
});
}
let convert_to_int = (value) => isNaN(parseInt(value)) ? 0 : parseInt(value);
let calc_protection = function(){
// Stat mods
['strength', 'dexterity', 'constitution', 'intelligence', 'wisdom', 'charisma'].forEach(stat => {
let base_stat = `character_${stat}`;
let check_stat = `save_${stat}_check`;
let save_value = `save_${stat}_value`;
getAttrs([base_stat, check_stat, save_value, "proficient_bonus"], function(v){
let save = 10 + convert_to_int(v[base_stat]);
if(convert_to_int(v[check_stat]) == 1){
save += convert_to_int(v["proficient_bonus"]);
}
setAttrs({[`save_${stat}_value`]: save });
});
update_attacks("all");
});
}
let calculate_load = function(){
getAttrs(["character_strength"], function(v){
let base_volume = 16;
if(v.character_strength > 0){
base_volume += (convert_to_int(v.character_strength) * 3);
} else {
base_volume += (convert_to_int(v.character_strength) * 2);
}
setAttrs({["volumelimite"]: base_volume });
});
}
let setattribute_roll = function(attribute){
getAttrs(["selectedattribute", "character_name", "selectedrawvalue", `character_${attribute}`], function(v){
if(v.selectedattribute != `character_${attribute}`){
['strength', 'dexterity', 'constitution', 'intelligence', 'wisdom', 'charisma'].forEach(stat => {
$20(`.sheet-attr-span-${stat}`).removeClass("sheet-active-element");
});
$20(`.sheet-attr-span-${attribute}`).addClass("sheet-active-element");
$20(`.sheet-skills-body`).addClass("sheet-skills-active");
setAttrs({[`selectedattribute`]: `character_${attribute}` });
setAttrs({[`selectedrawvalue`]: v[`character_${attribute}`] });
setAttrs({[`rawattribute`]: attribute});
} else {
//let formated_attribute = `character_${attribute}`;
const atribute_name = {
"strength": "Força", "dexterity": "Destreza", "constitution": "Constituição", "intelligence": "Inteligência", "wisdom": "Sabedoria", "charisma": "Carisma"
}
let roll_construction = `?{Rolagem|Simples, 1d20|Vantagem, 2d20kh1|Desvantagem, 2d20kl1} + ${v["selectedrawvalue"]} + ?{Bônus|0}`;
let final_roll = `&{template:skillroll} {{character=${v.character_name}}} {{pericia=${atribute_name[attribute]}}} {{rolagem=[[${roll_construction}]]}} {{reroll=[ReRoll](~reroll)}}`;
startRoll(final_roll, diceroll => {
});
$20(`.sheet-attr-span-${attribute}`).removeClass("sheet-active-element");
$20(`.sheet-skills-body`).removeClass("sheet-skills-active");
setAttrs({[`rawroll`]: final_roll});
setAttrs({[`selectedattribute`]: "" });
setAttrs({[`selectedrawvalue`]: "" });
setAttrs({[`rawattribute`]: ""});
}
});
}
on('sheet:opened change:repeating_equipment:volumeequipamento change:repeating_equipment:fragmentoequipamento change:repeating_equipment:reducaoequipamento', function(e){
getSectionIDs("equipment", function(idarray) {
let volume = 0;
let fragmento = 0;
let rd = 0;
for(var i=0; i < idarray.length; i++) {
let repeeating_volume = "repeating_equipment_" + idarray[i] + "_volumeequipamento";
let repeeating_fragme = "repeating_equipment_" + idarray[i] + "_fragmentoequipamento";
let repeeating_redano = "repeating_equipment_" + idarray[i] + "_reducaoequipamento";
getAttrs([repeeating_volume, repeeating_fragme, repeeating_redano], function(v){
volume += convert_to_int(v[repeeating_volume]);
fragmento += convert_to_int(v[repeeating_fragme]);
rd += convert_to_int(v[repeeating_redano]);
setAttrs({["volumeatual"]: volume});
setAttrs({["fragmentosatual"]: fragmento});
setAttrs({["reducaodedano"]: rd});
});
}
});
});
on("clicked:skillroll", function(e){
let arr_skill = e.htmlAttributes.value.split('-');
const skills_name = {
"apresentacao": "Apresentação", "aptidaoum": "Aptidão", "aptidaodois": "Aptidão", "aptidaotres": "Aptidão",
"arcanismo": "Arcanismo", "cultura": "Cultura", "doutrinas": "Doutrinas", "diplomacia": "Diplomacia",
"furtividade": "Furtividade", "intimidacao": "Intimidação", "intuicao": "Intuição", "medicina": "Medicina",
"magitec": "Magitec", "malandragem": "Malandragem", "manipulacao": "Manipulação", "natureza": "Natureza",
"percepcao": "Percepção", "preparofisico": "Preparo Físico"
}
const atribute_name = {
"strength": "Força", "dexterity": "Destreza", "constitution": "Constituição", "intelligence": "Inteligência", "wisdom": "Sabedoria", "charisma": "Carisma"
}
getAttrs(["apidaoum_selectbox", "apidaodois_selectbox", "apidaotres_selectbox", "selectedattribute","selectedrawvalue", "rawroll", "rawattribute", `${arr_skill[0]}_checkbox`, `${arr_skill[0]}_proficiency`, "proficient_bonus", `${arr_skill[0]}_especialization`, `mod_${arr_skill[0]}`], function(v){
let pericia_name = skills_name[arr_skill[0]];
if(arr_skill[0] == "aptidaoum"){ pericia_name = pericia_name +" " + v.apidaoum_selectbox; }
if(arr_skill[0] == "aptidaodois"){ pericia_name = pericia_name + " " + v.apidaodois_selectbox; }
if(arr_skill[0] == "aptidaotres"){ pericia_name = pericia_name + " " + v.apidaotres_selectbox; }
let roll_construction = "";
if(arr_skill[1] == "simples"){
roll_construction = `1d20 + ${v["selectedrawvalue"]}+(@{${arr_skill[0]}_proficiency} * @{proficient_bonus} * (1 + @{${arr_skill[0]}_especialization})) + @{mod_${arr_skill[0]}}`;
}
if(arr_skill[1] == "vantagem"){
roll_construction = `2d20kh1 + ${v["selectedrawvalue"]}+(@{${arr_skill[0]}_proficiency} * @{proficient_bonus} * (1 + @{${arr_skill[0]}_especialization})) + @{mod_${arr_skill[0]}}`;
}
if(arr_skill[1] == "desvantagem"){
roll_construction = `2d20kl1 + ${v["selectedrawvalue"]}+(@{${arr_skill[0]}_proficiency} * @{proficient_bonus} * (1 + @{${arr_skill[0]}_especialization})) + @{mod_${arr_skill[0]}}`;
}
let final_roll = `&{template:skillroll}{{character=@{character_name}}} {{pericia=${pericia_name}(${atribute_name[v.rawattribute]})}} {{rolagem=[[ ${roll_construction} ]]}} {{reroll=[ReRoll](~reroll)}}`;
startRoll(final_roll, diceroll => {
});
['strength', 'dexterity', 'constitution', 'intelligence', 'wisdom', 'charisma'].forEach(stat => {
$20(`.sheet-attr-span-${stat}`).removeClass("sheet-active-element");
});
$20(`.sheet-skills-body`).removeClass("sheet-skills-active");
setAttrs({[`rawroll`]: final_roll});
setAttrs({[`selectedattribute`]: "" });
setAttrs({[`selectedrawvalue`]: "" });
setAttrs({[`${arr_skill[0]}_checkbox`]: 0});
});
});
['strength','dexterity','constitution','intelligence','wisdom','charisma'].forEach(attr => {
on(`clicked:set${attr}roll`, function(){
setattribute_roll(attr);
update_attacks(`${attr}`);
calculate_load();
});
on(`change:character_${attr}`, function() {
update_attacks(`${attr}`);
calculate_load();
});
});
on(`change:character_strength change:character_dexterity change:character_constitution change:character_intelligence change:character_wisdom change:character_charisma change:save_strength_check change:save_dexterity_check change:save_constitution_check change:save_intelligence_check change:save_wisdom_check change:save_charisma_check`, function(){
calc_protection();
});
on(`change:character_level change:character_second_level change:character_third_level`, function(e){
calc_proficiency();
});
on("sheet:opened", function(e){
calc_proficiency();
getAttrs(["selectedattribute"], function(v){
setAttrs({["selectedattribute"]: "" });
});
});
//Troca entre as abas
on("sheet:opened change:cstype", function(e){
getAttrs(["cstype"], function(v){
let switch_selector = 'sheet-switch-selected';
if (v.cstype == 0) {
$20('.sheet-character-attributes-tab').addClass(switch_selector);
$20('.sheet-character-actions-tab').removeClass(switch_selector);
$20('.sheet-character-spells-tab').removeClass(switch_selector);
$20('.sheet-character-equipment-tab').removeClass(switch_selector);
$20('.sheet-character-characteristics-tab').removeClass(switch_selector);
$20('.sheet-character-attributes').removeClass('sheet-hiddenelement');
$20('.sheet-character-actions').addClass('sheet-hiddenelement');
$20('.sheet-character-spells').addClass('sheet-hiddenelement');
$20('.sheet-character-equipment').addClass('sheet-hiddenelement');
$20('.sheet-characteristics').addClass('sheet-hiddenelement');
}
if (v.cstype == 1){
$20('.sheet-character-actions-tab').addClass(switch_selector);
$20('.sheet-character-attributes-tab').removeClass(switch_selector);
$20('.sheet-character-spells-tab').removeClass(switch_selector);
$20('.sheet-character-equipment-tab').removeClass(switch_selector);
$20('.sheet-character-characteristics-tab').removeClass(switch_selector);
$20('.sheet-character-actions').removeClass('sheet-hiddenelement');
$20('.sheet-character-attributes').addClass('sheet-hiddenelement');
$20('.sheet-character-spells').addClass('sheet-hiddenelement');
$20('.sheet-character-equipment').addClass('sheet-hiddenelement');
$20('.sheet-characteristics').addClass('sheet-hiddenelement');
}
if (v.cstype == 2){
$20('.sheet-character-spells-tab').addClass(switch_selector);
$20('.sheet-character-actions-tab').removeClass(switch_selector);
$20('.sheet-character-attributes-tab').removeClass(switch_selector);
$20('.sheet-character-equipment-tab').removeClass(switch_selector);
$20('.sheet-character-characteristics-tab').removeClass(switch_selector);
$20('.sheet-character-spells').removeClass('sheet-hiddenelement');
$20('.sheet-character-actions').addClass('sheet-hiddenelement');
$20('.sheet-character-attributes').addClass('sheet-hiddenelement');
$20('.sheet-character-equipment').addClass('sheet-hiddenelement');
$20('.sheet-characteristics').addClass('sheet-hiddenelement');
}
if (v.cstype == 3){
$20('.sheet-character-equipment-tab').addClass(switch_selector);
$20('.sheet-character-spells-tab').removeClass(switch_selector);
$20('.sheet-character-actions-tab').removeClass(switch_selector);
$20('.sheet-character-attributes-tab').removeClass(switch_selector);
$20('.sheet-character-characteristics-tab').removeClass(switch_selector);
$20('.sheet-character-equipment').removeClass('sheet-hiddenelement');
$20('.sheet-character-spells').addClass('sheet-hiddenelement');
$20('.sheet-character-actions').addClass('sheet-hiddenelement');
$20('.sheet-character-attributes').addClass('sheet-hiddenelement');
$20('.sheet-characteristics').addClass('sheet-hiddenelement');
}
if (v.cstype == 4){
$20('.sheet-character-characteristics-tab').addClass(switch_selector);
$20('.sheet-character-equipment-tab').removeClass(switch_selector);
$20('.sheet-character-spells-tab').removeClass(switch_selector);
$20('.sheet-character-actions-tab').removeClass(switch_selector);
$20('.sheet-character-attributes-tab').removeClass(switch_selector);
$20('.sheet-characteristics').removeClass('sheet-hiddenelement');
$20('.sheet-character-equipment').addClass('sheet-hiddenelement');
$20('.sheet-character-spells').addClass('sheet-hiddenelement');
$20('.sheet-character-actions').addClass('sheet-hiddenelement');
$20('.sheet-character-attributes').addClass('sheet-hiddenelement');
}
});
});
const checkModification = (check, str) => check == 1 ? str : ' ';
const setEmpty = (str) => str ? str : '';
const update_spell_card = (eventinfo) => {
getSectionIDs("spells", function(idarray) {
for(var i=0; i < idarray.length; i++) {
let id = idarray[i];
let tipoacao = "repeating_spells_" + id + "_tipoacao";
let nameaction = "repeating_spells_" + id + "_nameaction";
let custoacao = "repeating_spells_" + id + "_custoacao";
let info_actions = "repeating_spells_" + id + "_info_spells";
let descritores_actions = "repeating_spells_" + id + "_descritores_actions";
let alcance_actions = "repeating_spells_" + id + "_alcance_spells";
let alvo_actions = "repeating_spells_" + id + "_alvo_spells";
let duracao_actions = "repeating_spells_" + id + "_duracao_spells";
let component_actions = "repeating_spells_" + id + "_component_spells";
let gatilho_actions = "repeating_spells_" + id + "_gatilho_spells";
let ataque_actions = "repeating_spells_" + id + "_ataque_spells";
let acerto_actions = "repeating_spells_" + id + "_acerto_spells";
let erro_actions = "repeating_spells_" + id + "_erro_spells";
let efeito_actions = "repeating_spells_" + id + "_efeito_spells";
let especial_actions = "repeating_spells_" + id + "_especial_spells";
let customod_actions = "repeating_spells_" + id + "_customod_actions";
let tipomod_actions = "repeating_spells_" + id + "_tipomod_actions";
let description_actions = "repeating_spells_" + id + "_description_actions";
let customodtwo_actions = "repeating_spells_" + id + "_customodtwo_actions";
let tipomodtwo_actions = "repeating_spells_" + id + "_tipomodtwo_actions";
let descriptiontwo_actions = "repeating_spells_" + id + "_descriptiontwo_actions";
let customodthree_actions = "repeating_spells_" + id + "_customodthree_actions";
let tipomodthree_actions = "repeating_spells_" + id + "_tipomodthree_actions";
let descriptionthree_actions = "repeating_spells_" + id + "_descriptionthree_actions";
let customodfour_actions = "repeating_spells_" + id + "_customodfour_actions";
let tipomodfour_actions = "repeating_spells_" + id + "_tipomodfour_actions";
let descriptionfour_actions = "repeating_spells_" + id + "_descriptionfour_actions";
let customodfive_actions = "repeating_spells_" + id + "_customodfive_actions";
let tipomodfive_actions = "repeating_spells_" + id + "_tipomodfive_actions";
let descriptionfive_actions = "repeating_spells_" + id + "_descriptionfive_actions";
let customodsix_actions = "repeating_spells_" + id + "_customodsix_actions";
let tipomodsix_actions = "repeating_spells_" + id + "_tipomodsix_actions";
let descriptionsix_actions = "repeating_spells_" + id + "_descriptionsix_actions";
let customodseven_actions = "repeating_spells_" + id + "_customodseven_actions";
let tipomodseven_actions = "repeating_spells_" + id + "_tipomodseven_actions";
let descriptionseven_actions = "repeating_spells_" + id + "_descriptionseven_actions";
let customodeigth_actions = "repeating_spells_" + id + "_customodeigth_actions";
let tipomodeigth_actions = "repeating_spells_" + id + "_tipomodeigth_actions";
let descriptioneigth_actions = "repeating_spells_" + id + "_descriptioneigth_actions";
let customodnine_actions = "repeating_spells_" + id + "_customodnine_actions";
let tipomodnine_actions = "repeating_spells_" + id + "_tipomodnine_actions";
let descriptionnine_actions = "repeating_spells_" + id + "_descriptionnine_actions";
let customodten_actions = "repeating_spells_" + id + "_customodten_actions";
let tipomodten_actions = "repeating_spells_" + id + "_tipomodten_actions";
let descriptionten_actions = "repeating_spells_" + id + "_descriptionten_actions";
let modcheck_actions_one = "repeating_spells_" + id + "_modcheckone";
let modcheck_actions_two = "repeating_spells_" + id + "_modchecktwo";
let modcheck_actions_three = "repeating_spells_" + id + "_modcheckthree";
let modcheck_actions_four = "repeating_spells_" + id + "_modcheckfour";
let modcheck_actions_five = "repeating_spells_" + id + "_modcheckfive";
let modcheck_actions_six = "repeating_spells_" + id + "_modchecksix";
let modcheck_actions_seven = "repeating_spells_" + id + "_modcheckseven";
let modcheck_actions_eigth = "repeating_spells_" + id + "_modcheckeigth";
let modcheck_actions_nine = "repeating_spells_" + id + "_modchecknine";
let modcheck_actions_ten = "repeating_spells_" + id + "_modcheckten";
getAttrs([tipoacao, nameaction, custoacao, info_actions, descritores_actions, alcance_actions, alvo_actions, duracao_actions, component_actions,
gatilho_actions, ataque_actions, acerto_actions, erro_actions, efeito_actions, especial_actions, customod_actions, tipomod_actions,
description_actions, customodtwo_actions, tipomodtwo_actions, descriptiontwo_actions,
customodthree_actions, tipomodthree_actions, descriptionthree_actions, customodfour_actions,tipomodfour_actions, descriptionfour_actions, customodfive_actions, tipomodfive_actions,
descriptionfive_actions, customodsix_actions, tipomodsix_actions, descriptionsix_actions, customodseven_actions, tipomodseven_actions, descriptionseven_actions, customodeigth_actions,
tipomodeigth_actions, descriptioneigth_actions, customodnine_actions, tipomodnine_actions, descriptionnine_actions, customodten_actions, tipomodten_actions, descriptionten_actions,
modcheck_actions_one, modcheck_actions_two, modcheck_actions_three, modcheck_actions_four, modcheck_actions_five, modcheck_actions_six, modcheck_actions_seven,
modcheck_actions_eigth, modcheck_actions_nine, modcheck_actions_ten
], function(v){
setAttrs({[`repeating_spells_${id}_nameactionshow`]: setEmpty(v[nameaction])});
setAttrs({[`repeating_spells_${id}_custoacaoshow`]: setEmpty(v[custoacao])});
setAttrs({[`repeating_spells_${id}_descritores_show`]: setEmpty(v[descritores_actions])});
setAttrs({[`repeating_spells_${id}_informacoes_show`]: setEmpty(v[info_actions])});
setAttrs({[`repeating_spells_${id}_alcance_show`]: setEmpty(v[alcance_actions])});
setAttrs({[`repeating_spells_${id}_alvo_show`]: setEmpty(v[alvo_actions])});
setAttrs({[`repeating_spells_${id}_duracao_show`]: setEmpty(v[duracao_actions])});
setAttrs({[`repeating_spells_${id}_component_show`]: setEmpty(v[component_actions])});
setAttrs({[`repeating_spells_${id}_gatilho_show`]: setEmpty(v[gatilho_actions])});
setAttrs({[`repeating_spells_${id}_ataque_show`]: setEmpty(v[ataque_actions])});
setAttrs({[`repeating_spells_${id}_acerto_show`]: setEmpty(v[acerto_actions])});
setAttrs({[`repeating_spells_${id}_erro_show`]: setEmpty(v[erro_actions])});
setAttrs({[`repeating_spells_${id}_efeito_show`]: setEmpty(v[efeito_actions])});
setAttrs({[`repeating_spells_${id}_especial_show`]: setEmpty(v[especial_actions])});
setAttrs({[`repeating_spells_${id}_tipoacaoshow`]: setEmpty(v[tipoacao])});
console.log(v[modcheck_actions_one]);
setAttrs({[`repeating_spells_${id}_customod_show`]: checkModification(v[modcheck_actions_one], setEmpty(v[customod_actions])) });
setAttrs({[`repeating_spells_${id}_tipomod_show`]: checkModification(v[modcheck_actions_one],setEmpty(v[tipomod_actions])) });
setAttrs({[`repeating_spells_${id}_description_show`]: checkModification(v[modcheck_actions_one],setEmpty(v[description_actions])) });
setAttrs({[`repeating_spells_${id}_customodtwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[customodtwo_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodtwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[tipomodtwo_actions])) });
setAttrs({[`repeating_spells_${id}_descriptiontwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[descriptiontwo_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[tipomodthree_actions])) });
setAttrs({[`repeating_spells_${id}_customodthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[tipomodfour_actions])) });
setAttrs({[`repeating_spells_${id}_customodfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[tipomodfive_actions])) });
setAttrs({[`repeating_spells_${id}_customodfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[tipomodsix_actions])) });
setAttrs({[`repeating_spells_${id}_customodsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[tipomodseven_actions])) });
setAttrs({[`repeating_spells_${id}_customodseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodeigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[tipomodeigth_actions])) });
setAttrs({[`repeating_spells_${id}_customodeigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptioneigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[tipomodnine_actions])) });
setAttrs({[`repeating_spells_${id}_customodnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_tipomodten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[tipomodten_actions])) });
setAttrs({[`repeating_spells_${id}_customodten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_spells_${id}_descriptionten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[customodthree_actions])) });
});
}
});
}
const update_action_card = (eventinfo) => {
getSectionIDs("actions", function(idarray) {
for(var i=0; i < idarray.length; i++) {
let id = idarray[i];
let tipoacao = "repeating_actions_" + id + "_tipoacao";
let nameaction = "repeating_actions_" + id + "_nameaction";
let custoacao = "repeating_actions_" + id + "_custoacao";
let info_actions = "repeating_actions_" + id + "_info_actions";
let descritores_actions = "repeating_actions_" + id + "_descritores_actions";
let alcance_actions = "repeating_actions_" + id + "_alcance_actions";
let alvo_actions = "repeating_actions_" + id + "_alvo_actions";
let duracao_actions = "repeating_actions_" + id + "_duracao_actions";
let component_actions = "repeating_actions_" + id + "_component_actions";
let gatilho_actions = "repeating_actions_" + id + "_gatilho_actions";
let ataque_actions = "repeating_actions_" + id + "_ataque_actions";
let acerto_actions = "repeating_actions_" + id + "_acerto_actions";
let erro_actions = "repeating_actions_" + id + "_erro_actions";
let efeito_actions = "repeating_actions_" + id + "_efeito_actions";
let especial_actions = "repeating_actions_" + id + "_especial_actions";
let customod_actions = "repeating_actions_" + id + "_customod_actions";
let tipomod_actions = "repeating_actions_" + id + "_tipomod_actions";
let description_actions = "repeating_actions_" + id + "_description_actions";
let customodtwo_actions = "repeating_actions_" + id + "_customodtwo_actions";
let tipomodtwo_actions = "repeating_actions_" + id + "_tipomodtwo_actions";
let descriptiontwo_actions = "repeating_actions_" + id + "_descriptiontwo_actions";
let customodthree_actions = "repeating_actions_" + id + "_customodthree_actions";
let tipomodthree_actions = "repeating_actions_" + id + "_tipomodthree_actions";
let descriptionthree_actions = "repeating_actions_" + id + "_descriptionthree_actions";
let customodfour_actions = "repeating_actions_" + id + "_customodfour_actions";
let tipomodfour_actions = "repeating_actions_" + id + "_tipomodfour_actions";
let descriptionfour_actions = "repeating_actions_" + id + "_descriptionfour_actions";
let customodfive_actions = "repeating_actions_" + id + "_customodfive_actions";
let tipomodfive_actions = "repeating_actions_" + id + "_tipomodfive_actions";
let descriptionfive_actions = "repeating_actions_" + id + "_descriptionfive_actions";
let customodsix_actions = "repeating_actions_" + id + "_customodsix_actions";
let tipomodsix_actions = "repeating_actions_" + id + "_tipomodsix_actions";
let descriptionsix_actions = "repeating_actions_" + id + "_descriptionsix_actions";
let customodseven_actions = "repeating_actions_" + id + "_customodseven_actions";
let tipomodseven_actions = "repeating_actions_" + id + "_tipomodseven_actions";
let descriptionseven_actions = "repeating_actions_" + id + "_descriptionseven_actions";
let customodeigth_actions = "repeating_actions_" + id + "_customodeigth_actions";
let tipomodeigth_actions = "repeating_actions_" + id + "_tipomodeigth_actions";
let descriptioneigth_actions = "repeating_actions_" + id + "_descriptioneigth_actions";
let customodnine_actions = "repeating_actions_" + id + "_customodnine_actions";
let tipomodnine_actions = "repeating_actions_" + id + "_tipomodnine_actions";
let descriptionnine_actions = "repeating_actions_" + id + "_descriptionnine_actions";
let customodten_actions = "repeating_actions_" + id + "_customodten_actions";
let tipomodten_actions = "repeating_actions_" + id + "_tipomodten_actions";
let descriptionten_actions = "repeating_actions_" + id + "_descriptionten_actions";
let modcheck_actions_one = "repeating_actions_" + id + "_modcheckone";
let modcheck_actions_two = "repeating_actions_" + id + "_modchecktwo";
let modcheck_actions_three = "repeating_actions_" + id + "_modcheckthree";
let modcheck_actions_four = "repeating_actions_" + id + "_modcheckfour";
let modcheck_actions_five = "repeating_actions_" + id + "_modcheckfive";
let modcheck_actions_six = "repeating_actions_" + id + "_modchecksix";
let modcheck_actions_seven = "repeating_actions_" + id + "_modcheckseven";
let modcheck_actions_eigth = "repeating_actions_" + id + "_modcheckeigth";
let modcheck_actions_nine = "repeating_actions_" + id + "_modchecknine";
let modcheck_actions_ten = "repeating_actions_" + id + "_modcheckten";
getAttrs([tipoacao, nameaction, custoacao, info_actions, descritores_actions, alcance_actions, alvo_actions, duracao_actions, component_actions,
gatilho_actions, ataque_actions, acerto_actions, erro_actions, efeito_actions, especial_actions, customod_actions, tipomod_actions,
description_actions, customodtwo_actions, tipomodtwo_actions, descriptiontwo_actions,
customodthree_actions, tipomodthree_actions, descriptionthree_actions, customodfour_actions,tipomodfour_actions, descriptionfour_actions, customodfive_actions, tipomodfive_actions,
descriptionfive_actions, customodsix_actions, tipomodsix_actions, descriptionsix_actions, customodseven_actions, tipomodseven_actions, descriptionseven_actions, customodeigth_actions,
tipomodeigth_actions, descriptioneigth_actions, customodnine_actions, tipomodnine_actions, descriptionnine_actions, customodten_actions, tipomodten_actions, descriptionten_actions,
modcheck_actions_one, modcheck_actions_two, modcheck_actions_three, modcheck_actions_four, modcheck_actions_five, modcheck_actions_six, modcheck_actions_seven,
modcheck_actions_eigth, modcheck_actions_nine, modcheck_actions_ten
], function(v){
setAttrs({[`repeating_actions_${id}_nameactionshow`]: setEmpty(v[nameaction])});
setAttrs({[`repeating_actions_${id}_custoacaoshow`]: setEmpty(v[custoacao])});
setAttrs({[`repeating_actions_${id}_descritores_show`]: setEmpty(v[descritores_actions])});
setAttrs({[`repeating_actions_${id}_informacoes_show`]: setEmpty(v[info_actions])});
setAttrs({[`repeating_actions_${id}_alcance_show`]: setEmpty(v[alcance_actions])});
setAttrs({[`repeating_actions_${id}_alvo_show`]: setEmpty(v[alvo_actions])});
setAttrs({[`repeating_actions_${id}_duracao_show`]: setEmpty(v[duracao_actions])});
setAttrs({[`repeating_actions_${id}_component_show`]: setEmpty(v[component_actions])});
setAttrs({[`repeating_actions_${id}_gatilho_show`]: setEmpty(v[gatilho_actions])});
setAttrs({[`repeating_actions_${id}_ataque_show`]: setEmpty(v[ataque_actions])});
setAttrs({[`repeating_actions_${id}_acerto_show`]: setEmpty(v[acerto_actions])});
setAttrs({[`repeating_actions_${id}_erro_show`]: setEmpty(v[erro_actions])});
setAttrs({[`repeating_actions_${id}_efeito_show`]: setEmpty(v[efeito_actions])});
setAttrs({[`repeating_actions_${id}_especial_show`]: setEmpty(v[especial_actions])});
setAttrs({[`repeating_actions_${id}_tipoacaoshow`]: setEmpty(v[tipoacao])});
setAttrs({[`repeating_actions_${id}_customod_show`]: checkModification(v[modcheck_actions_one], setEmpty(v[customod_actions])) });
setAttrs({[`repeating_actions_${id}_tipomod_show`]: checkModification(v[modcheck_actions_one],setEmpty(v[tipomod_actions])) });
setAttrs({[`repeating_actions_${id}_description_show`]: checkModification(v[modcheck_actions_one],setEmpty(v[description_actions])) });
setAttrs({[`repeating_actions_${id}_customodtwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[customodtwo_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodtwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[tipomodtwo_actions])) });
setAttrs({[`repeating_actions_${id}_descriptiontwo_show`]: checkModification(v[modcheck_actions_two],setEmpty(v[descriptiontwo_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[tipomodthree_actions])) });
setAttrs({[`repeating_actions_${id}_customodthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionthree_show`]: checkModification(v[modcheck_actions_three],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[tipomodfour_actions])) });
setAttrs({[`repeating_actions_${id}_customodfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionfour_show`]: checkModification(v[modcheck_actions_four],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[tipomodfive_actions])) });
setAttrs({[`repeating_actions_${id}_customodfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionfive_show`]: checkModification(v[modcheck_actions_five],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[tipomodsix_actions])) });
setAttrs({[`repeating_actions_${id}_customodsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionsix_show`]: checkModification(v[modcheck_actions_six],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[tipomodseven_actions])) });
setAttrs({[`repeating_actions_${id}_customodseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionseven_show`]: checkModification(v[modcheck_actions_seven],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodeigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[tipomodeigth_actions])) });
setAttrs({[`repeating_actions_${id}_customodeigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptioneigth_show`]: checkModification(v[modcheck_actions_eigth],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[tipomodnine_actions])) });
setAttrs({[`repeating_actions_${id}_customodnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionnine_show`]: checkModification(v[modcheck_actions_nine],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_tipomodten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[tipomodten_actions])) });
setAttrs({[`repeating_actions_${id}_customodten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[customodthree_actions])) });
setAttrs({[`repeating_actions_${id}_descriptionten_show`]: checkModification(v[modcheck_actions_ten],setEmpty(v[customodthree_actions])) });
});
}
});
}
['tipoacao', 'nameaction', 'custoacao', 'info_actions', 'descritores_actions', 'alcance_actions', 'alvo_actions', 'duracao_actions', 'component_actions',
'gatilho_actions', 'ataque_actions', 'acerto_actions', 'erro_actions', 'efeito_actions', 'especial_actions', 'customod_actions', 'tipomod_actions',
'description_actions', 'customodtwo_actions', 'tipomodtwo_actions', 'descriptiontwo_actions', 'customodthree_actions', 'tipomodthree_actions', 'descriptionthree_actions',
'customodfour_actions', 'tipomodfour_actions', 'descriptionfour_actions', 'customodfive_actions', 'tipomodfive_actions', 'descriptionfive_actions',
'customodsix_actions', 'tipomodsix_actions', 'descriptionsix_actions', 'customodseven_actions', 'tipomodseven_actions', 'descriptionseven_actions',
'customodeigth_actions', 'tipomodeigth_actions', 'descriptioneigth_actions', 'customodnine_actions', 'tipomodnine_actions', 'descriptionnine_actions',
'customodten_actions', 'tipomodten_actions', 'descriptionten_actions',
"modcheckone", "modchecktwo", "modcheckthree","modcheckfour","modcheckfive","modchecksix", "modcheckseven","modcheckeigth","modchecknine", "modcheckten"
].forEach(atb => {
on(`change:repeating_actions:${atb}`, function(eventinfo){
update_action_card(eventinfo);
});
});
['tipoacao', 'nameaction', 'custoacao', 'info_actions', 'descritores_actions', 'alcance_actions', 'alvo_actions', 'duracao_actions', 'component_actions',
'gatilho_actions', 'ataque_actions', 'acerto_actions', 'erro_actions', 'efeito_actions', 'especial_actions', 'customod_actions', 'tipomod_actions',
'description_actions', 'customodtwo_actions', 'tipomodtwo_actions', 'descriptiontwo_actions', 'customodthree_actions', 'tipomodthree_actions', 'descriptionthree_actions',
'customodfour_actions', 'tipomodfour_actions', 'descriptionfour_actions', 'customodfive_actions', 'tipomodfive_actions', 'descriptionfive_actions',
'customodsix_actions', 'tipomodsix_actions', 'descriptionsix_actions', 'customodseven_actions', 'tipomodseven_actions', 'descriptionseven_actions',
'customodeigth_actions', 'tipomodeigth_actions', 'descriptioneigth_actions', 'customodnine_actions', 'tipomodnine_actions', 'descriptionnine_actions',
'customodten_actions', 'tipomodten_actions', 'descriptionten_actions',
"modcheckone", "modchecktwo", "modcheckthree","modcheckfour","modcheckfive","modchecksix", "modcheckseven","modcheckeigth","modchecknine", "modcheckten",
].forEach(atb => {
on(`change:repeating_spells:${atb}`, function(eventinfo){
update_spell_card(eventinfo);
});
});
["atkflag","atkname","atkattr_base","atkmod","atkprofflag","atkmagic","dmgflag","dmgbase","dmgattr","dmgmod","dmgtype","dmg2flag","dmg2base","dmg2attr","dmg2mod","dmg2type","dmgcustcrit","dmg2custcrit","saveflag","savedc","saveeffect","saveflat","hldmg","spellid","spelllevel","atkrange","itemid","ammo",].forEach((atb) => {
on(`change:repeating_attacks:${atb}`, function(eventinfo){
update_attacks("all");
})
});
const update_attacks = (update_id, source) => {
if (update_id.substring(0,1) === "-" && update_id.length === 20) {
do_update_attack([update_id], source);
} else if (["strength","dexterity","constitution","intelligence","wisdom","charisma","spells","all"].indexOf(update_id) > -1) {
getSectionIDs("repeating_attacks", (idarray) => {
if (update_id === "all") {
do_update_attack(idarray);
} else if (update_id === "spells") {
let attack_attribs = [];
_.each(idarray, (id) => {
attack_attribs.push(`repeating_attacks_${id}_spellid`, `repeating_attacks_${id}_spelllevel`);
});
getAttrs(attack_attribs, (v) => {
const filteredIds = _.filter(idarray, (id) => {
return v[`repeating_attacks_${id}_spellid`] && v[`repeating_attacks_${id}_spellid`] != "";
});
let spell_attacks = {};
_.each(filteredIds, (attack_id) => {
spell_attacks[attack_id] = {
spell_id: v[`repeating_attacks_${attack_id}_spellid`],
spell_lvl: v[`repeating_attacks_${attack_id}_spelllevel`]
};
});
_.each(spell_attacks, (data, attack_id) => { update_attack_from_spell(data.spell_lvl, data.spell_id, attack_id); });
});
} else {
let attack_attribs = ["spellcasting_ability"];
_.each(idarray, (id) => {
attack_attribs.push(`repeating_attacks_${id}_atkattr_base`);
attack_attribs.push(`repeating_attacks_${id}_dmgattr`);
attack_attribs.push(`repeating_attacks_${id}_dmg2attr`);
attack_attribs.push(`repeating_attacks_${id}_savedc`);
});
getAttrs(attack_attribs, (v) => {
let attr_attack_ids = [];
_.each(idarray, (id) => {
if ((v[`repeating_attacks_${id}_atkattr_base`] && v[`repeating_attacks_${id}_atkattr_base`].indexOf(update_id) > -1) || (v[`repeating_attacks_${id}_dmgattr`] && v[`repeating_attacks_${id}_dmgattr`].indexOf(update_id) > -1) || (v[`repeating_attacks_${id}_dmg2attr`] && v[`repeating_attacks_${id}_dmg2attr`].indexOf(update_id) > -1) || (v[`repeating_attacks_${id}_savedc`] && v[`repeating_attacks_${id}_savedc`].indexOf(update_id) > -1) || (v[`repeating_attacks_${id}_savedc`] && v[`repeating_attacks_${id}_savedc`] === "(@{spell_save_dc})" && v["spellcasting_ability"] && v["spellcasting_ability"].indexOf(update_id) > -1)) {
attr_attack_ids.push(id);
}
});
if (attr_attack_ids.length > 0) {
do_update_attack(attr_attack_ids);
}
});
};
});
};
};
const do_update_attack = (attack_array, source) => {
let attack_attribs = ["character_level","proficient_bonus", "globalmagicmod","character_strength","character_dexterity","character_constitution","character_intelligence","character_wisdom","character_charisma","spellcasting_attribute","bonusataquemagia", "global_damage_mod_roll", "global_damage_mod_crit", "character_name"];
_.each(attack_array, (attackid) => {
["atkflag","atkname","atkattr_base","atkmod","atkprofflag","atkmagic","dmgflag","dmgbase","dmgattr","dmgmod","dmgtype","dmg2flag","dmg2base","dmg2attr","dmg2mod","dmg2type","dmgcustcrit","dmg2custcrit","saveflag","savedc","saveeffect","saveflat","hldmg","spellid","spelllevel","atkrange","itemid","ammo",].forEach((attr) => {
attack_attribs.push(`repeating_attacks_${attackid}_${attr}`)
});
});
getAttrs(attack_attribs, (v) => {
_.each(attack_array, (attackid) => {
const repeating_attacks = `repeating_attacks_${attackid}`;
let callbacks = [];
let update = {};
let hbonus = "";
let hdmg1 = "";
let hdmg2 = "";
let dmg = "";
let dmg2 = "";
let rollbase = "";
let spellattack = false;
let magicattackmod = 0;
let magicsavemod = 0;
let atkattr_abrev = "";
let dmgattr_abrev = "";
let dmg2attr_abrev = "";
//PROFICIENCY BONUS select in Settings.
//const pbd_safe = v["pbd_safe"] || "";
//HIGHER LVL CAST DMG found in Spells for spells like Fireball
//ATTACK select inside settings for the repeating attack
if (!v[`${repeating_attacks}_atkattr_base`] || v[`${repeating_attacks}_atkattr_base`] === "0") {
atkattr_base = 0
} else if (v[`${repeating_attacks}_atkattr_base`] && v[`${repeating_attacks}_atkattr_base`] === "spell") {
atkattr_base = convert_to_int(v[v["spellcasting_attribute"].substring(2, v["spellcasting_attribute"].length - 2)], 10);
atkattr_abrev = v["spellcasting_attribute"].substring(2, 5).toUpperCase();
} else {
atkattr_base = convert_to_int(v[v[`${repeating_attacks}_atkattr_base`].substring(2, v[`${repeating_attacks}_atkattr_base`].length - 1)], 10);
atkattr_abrev = v[`${repeating_attacks}_atkattr_base`].substring(2, 5).toUpperCase();
};
//console.log("AtkBase", atkattr_base);
//DAMAGE 1 ability select inside settings for the repeating attack
if (!v[`${repeating_attacks}_dmgattr`] || v[`${repeating_attacks}_dmgattr`] === "0") {
dmgattr = 0;
} else if (v[`${repeating_attacks}_dmgattr`] && v[`${repeating_attacks}_dmgattr`] === "spell") {
dmgattr = convert_to_int(v[v["spellcasting_attribute"].substring(2, v["spellcasting_attribute"].length - 2)], 10);
dmgattr_abrev = v["spellcasting_attribute"].substring(2, 5).toUpperCase();
} else {
dmgattr = convert_to_int(v[v[`${repeating_attacks}_dmgattr`].substring(2, v[`${repeating_attacks}_dmgattr`].length - 1)], 10);
dmgattr_abrev = v[`${repeating_attacks}_dmgattr`].substring(2, 5).toUpperCase();
};
//DAMAGE 2 ability select inside settings for the repeating attack
if (!v[`${repeating_attacks}_dmg2attr`] || v[`${repeating_attacks}_dmg2attr`] === "0") {
dmg2attr = 0;
} else if (v[`${repeating_attacks}_dmg2attr`] && v[`${repeating_attacks}_dmg2attr`] === "spell") {
dmg2attr = convert_to_int(v[v["spellcasting_attribute"].substring(2, v["spellcasting_attribute"].length - 2)], 10);
dmg2attr_abrev = v["spellcasting_attribute"].substring(2, 5).toUpperCase();
} else {
dmg2attr = convert_to_int(v[v[`${repeating_attacks}_dmg2attr`].substring(2, v[`${repeating_attacks}_dmg2attr`].length - 1)], 10);
dmg2attr_abrev =v[`${repeating_attacks}_dmg2attr`].substring(2, 5).toUpperCase();
};
//DAMAGE first input inside settings for the repeating attack
const dmgbase = v[`${repeating_attacks}_dmgbase`] || 0;
const dmg2base = v[`${repeating_attacks}_dmg2base`] || 0;
//DAMAGE 1 second input inside settings for the repeating attack
const dmgmod = convert_to_int(v[`${repeating_attacks}_dmgmod`],10) || 0;
//DAMAGE 2 second input inside settings for the repeating attack
const dmg2mod = convert_to_int(v[`${repeating_attacks}_dmg2mod`],10) || 0;
//DAMAGE 1 TYPE input inside settings for the repeating attack
const dmgtype = v[`${repeating_attacks}_dmgtype`] || "";
//DAMAGE 2 TYPE input inside settings for the repeating attack
const dmg2type = v[`${repeating_attacks}_dmg2type`] || "";
//PROFICIENT flag inside settings for the repeating attack && PROFICIENCY BONUS from Settings
const atkprofflag = v[`${repeating_attacks}_atkprofflag`] || 0;
const proficient_bonus = (atkprofflag != 0 && v.proficient_bonus) ? v.proficient_bonus : 0;
//ATTACK input inside settings for the repeating attack
const atkmod = convert_to_int(v[`${repeating_attacks}_atkmod`],10) || 0;
//MAGIC BONUS input inside settings for the repeating attack
const atkmag = convert_to_int(v[`${repeating_attacks}_atkmagic`],10) || 0;
//used in _atkdmgtype display
const dmgmag = (isNaN(atkmag) === false && atkmag != 0 && ((v[`${repeating_attacks}_dmgflag`] && v[`${repeating_attacks}_dmgflag`] != 0) || (v[`${repeating_attacks}_dmg2flag`] && v[`${repeating_attacks}_dmg2flag`] != 0))) ? `+ ${atkmag} Magic Bonus` : "";
//ATTACK checkbox inside settings for the repeating attack
const atkflag = v[`${repeating_attacks}_atkflag`] || 0;
if (atkflag != 0) {
bonus_mod = atkattr_base + atkmod + atkmag + magicattackmod;
//console.log("variaveis:", atkattr_base, atkmod, atkmag, magicattackmod, bonus_mod);
plus_minus = (bonus_mod > -1) ? "+" : "";
//pb_type is PROFICIENCY BONUS select in Settings
if (v["pb_type"] && v["pb_type"] === "die") {
bonus = `${bonus_mod}+${proficient_bonus}`;
} else {
bonus_mod = bonus_mod + convert_to_int(proficient_bonus, 10);
bonus = plus_minus + bonus_mod;
};
//SAVING THROW checkbox inside settings for the repeating attack
} else if (v[`${repeating_attacks}_saveflag`] && v[`${repeating_attacks}_saveflag`] != 0) {
const saveDC = v[`${repeating_attacks}_savedc`] || "";
//SAVING THROW VS DC select "Spell" inside settings for the repeating attack
if (!saveDC || saveDC === "(@{spell_save_dc})") {
const tempdc = v["spell_save_dc"];
bonus = "DC" + tempdc;
//SAVING THROW VS DC select "FLAT" inside settings for the repeating attack
} else if (saveDC === "(@{saveflat})") {
const tempdc = convert_to_int(v[`${repeating_attacks}_saveflat`]) || 0;
bonus = "DC" + tempdc;
//SAVING THROW VS DC select ability score inside settings for the repeating attack
} else {
const savedcattr = v[`${repeating_attacks}_savedc`].split("_mod")[0].slice(3);
const safe_pb = v["pb_type"] && v["pb_type"] === "die" ? convert_to_int(proficient_bonus.substring(1), 10) / 2 : convert_to_int(proficient_bonus,10);
const safe_attr = v[`${savedcattr}_mod`] ? convert_to_int(v[`${savedcattr}_mod`],10) : 0;
const tempdc = 8 + safe_attr + safe_pb + magicsavemod;
bonus = "DC" + tempdc;
};
} else {
bonus = "-";
}
//DAMAGE checkbox inside settings for the repeating attack
const dmgflag1 = v[`${repeating_attacks}_dmgflag`] || 0;
const dmgflag2 = v[`${repeating_attacks}_dmg2flag`] || 0;
if (dmgflag1 != 0) {
if (spellattack === true && dmgbase.indexOf("[[round((@{level} + 1) / 6 + 0.5)]]") > -1) {
// SPECIAL CANTRIP DAMAGE
dmgdiestring = Math.round(((convert_to_int(v["level"], 10) + 1) / 6) + 0.5).toString();
dmg = dmgdiestring + dmgbase.substring(dmgbase.lastIndexOf("d"));
//select & input to the right of damage
if (dmgattr + dmgmod != 0) {
dmg += `+${(dmgattr + dmgmod)}`;
}
dmg += ` ${dmgtype}`;
} else {
if (dmgbase === 0 && (dmgattr + dmgmod === 0)) {
dmg = 0;
}
if (dmgbase != 0) {
dmg = dmgbase;
}
if (dmgbase != 0 && (dmgattr + dmgmod != 0)) {
dmg = (dmgattr + dmgmod > 0) ? dmg + "+" : dmg;
}
if (dmgattr + dmgmod != 0) {
dmg = dmg + (dmgattr + dmgmod);
}
dmg = dmg + " " + dmgtype;
}
};
if (dmgflag2 != 0) {
if (dmg2base === 0 && (dmg2attr + dmg2mod === 0)) {
dmg2 = 0;
}
if (dmg2base != 0) {
dmg2 = dmg2base;
}
if (dmg2base != 0 && (dmg2attr + dmg2mod != 0)) {
dmg2 = (dmg2attr + dmg2mod > 0) ? dmg2 + "+" : dmg2;
}
if (dmg2attr + dmg2mod != 0) {
dmg2 = dmg2 + (dmg2attr + dmg2mod);
}
dmg2 = dmg2 + " " + dmg2type;
};
update[`${repeating_attacks}_atkdmgtype`] = (dmgflag1 != 0 && dmgflag2 != 0) ? `${dmg} + ${dmg2}${dmgmag} `:`${dmg}${dmg2}${dmgmag} `;
//Build ROLL TEMPLATE with below variables
//ATTACK checkbox inside settings for the repeating attack
if (atkflag != 0) {
if (atkattr_base != 0) {hbonus += ` + ${atkattr_base}[${atkattr_abrev}]`};
if (atkmod != 0) {hbonus += ` + ${atkmod}[MOD]`};
if (proficient_bonus != 0) {hbonus += ` + ${proficient_bonus}[PROF]`};
if (atkmag != 0) {hbonus += ` + ${atkmag}[MAGIC]`};
if (magicattackmod != 0) {hbonus += ` + ${magicattackmod}[SPELLATK]`};
}
//DAMAGE 1 checkbox inside settings for the repeating attack
if (dmgflag1 != 0) {
hdmg1 += dmgbase;
if (dmgattr != 0) {hdmg1 += ` + ${dmgattr}[${dmgattr_abrev}]`};
if (dmgmod != 0) {hdmg1 += ` + ${dmgmod}[MOD]`};
if (atkmag != 0) {hdmg1 += ` + ${atkmag}[MAGIC]`};
} else {
hdmg1 += "0";
}
//DAMAGE 2 checkbox inside settings for the repeating attack
if (dmgflag2 != 0) {
hdmg2 += dmg2base
if (dmg2attr != 0) {hdmg2 += ` + ${dmg2attr}[${dmg2attr_abrev}]`};
if (dmg2mod != 0) {hdmg2 += ` + ${dmg2mod}[MOD]`};
} else {
hdmg2 += "0";
}
//CRIT input inside settings for the repeating attack
let crit1 = v[`${repeating_attacks}_dmgcustcrit`] || 0;
let crit2 = v[`${repeating_attacks}_dmg2custcrit`] || 0;
crit1 = (crit1 != 0) ? v[`${repeating_attacks}_dmgcustcrit`] : dmgbase;
crit2 = (crit2 != 0) ? v[`${repeating_attacks}_dmg2custcrit`] : dmg2base;
r1 = "1d20";
r2 = "{{r2=[[0d20";
//set in the GLOBAL DAMAGE MODIFIER section
let globaldamage = `[[${v.global_damage_mod_roll || 0}]]`;
let globaldamagecrit = `[[${v.global_damage_mod_crit || 0}]]`;
let saveflag = 0;
//Assamble Roll Templates
//if (v.dtype === "full") {
rollbase = `&{template:atkdmg} {{character_name=@{character_name}}} {{mod=@{atkbonus}}} {{rname=@{atkname}}} {{r1=[[1d20cs>@{atkcritrange}${hbonus}]]}} ${r2}cs>@{atkcritrange}${hbonus}]]}} @{atkflag} {{range=@{atkrange}}} @{dmgflag} {{dmg1=[[${hdmg1}]]}} {{dmg1type=${dmgtype}}} @{dmg2flag} {{dmg2=[[${hdmg2}]]}} {{dmg2type=${dmg2type}}} {{crit1=[[${crit1}[CRIT]]]}} {{crit2=[[${crit2}[CRIT]]]}} {{desc=@{atk_desc}}} @{hldmg} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} } {{globaldamage=${globaldamage}}} {{globaldamagecrit=${globaldamagecrit}}} ammo=@{ammo} {{reroll=[ReRoll](~repeating_attacks_reroll)}}`;
/*} else if (atkflag != 0) {
rollbase = `&{template:atk} {{mod=@{atkbonus}}} {{rname=[@{atkname}](~repeating_attacks_attack_dmg)}} {{rnamec=[@{atkname}](~repeating_attacks_attack_crit)}} {{r1=[[1d20cs>@{atkcritrange}${hbonus}]]}} ${r2}cs>@{atkcritrange}${hbonus}]]}} {{range=@{atkrange}}} {{desc=@{atk_desc}}} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} } ammo=@{ammo} `;
} else if (dmgflag1 != 0) {
rollbase = `&{template:dmg} {{rname=@{atkname}}} @{atkflag} {{range=@{atkrange}}} @{dmgflag} {{dmg1=[[${hdmg1}]]}} {{dmg1type=${dmgtype}}} @{dmg2flag} {{dmg2=[[${hdmg2}]]}} {{dmg2type=${dmg2type}}} {{desc=@{atk_desc}}} @{hldmg} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} {{globaldamage=${globaldamage}}} ammo=@{ammo} `;
} else {
rollbase = `&{template:dmg} {{rname=@{atkname}}} @{atkflag} {{range=@{atkrange}}} {{desc=@{atk_desc}}} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} ammo=@{ammo} `;
}*/
update[`${repeating_attacks}_rollbase_dmg`] = `&{template:dmg} {{rname=@{atkname}}} @{atkflag} {{range=@{atkrange}}} @{dmgflag} {{dmg1=[[${hdmg1}]]}} {{dmg1type=${dmgtype}}} @{dmg2flag} {{dmg2=[[${hdmg2}]]}} {{dmg2type=${dmg2type}}} {{desc=@{atk_desc}}} @{hldmg} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} {{globaldamage=${globaldamage}}} `;
update[`${repeating_attacks}_rollbase_crit`] = `&{template:dmg} {{crit=1}} {{rname=@{atkname}}} @{atkflag} {{range=@{atkrange}}} @{dmgflag} {{dmg1=[[${hdmg1}]]}} {{dmg1type=${dmgtype}}} @{dmg2flag} {{dmg2=[[${hdmg2}]]}} {{dmg2type=${dmg2type}}} {{crit1=[[${crit1}]]}} {{crit2=[[${crit2}]]}} {{desc=@{atk_desc}}} @{hldmg} {{spelllevel=@{spelllevel}}} {{innate=@{spell_innate}}} {{globaldamage=${globaldamage}}} {{globaldamagecrit=${globaldamagecrit}}} `;
update[`${repeating_attacks}_atkbonus`] = bonus;
update[`${repeating_attacks}_rollbase`] = rollbase;
setAttrs(update, {silent: true}, () => {
callbacks.forEach((callback) => {
callback();
});
});
});
});
};
</script>
<rolltemplate class="sheet-rolltemplate-actspell">
<div class="container-actspell">
<div class="charname">
<span>{{character_name}}</span>
</div>
<div class="sheet-actionspell-header">
<span>{{{tipoacao}}}</span> |
<span class="sheet-img-acao"><img class="sheet-img-acao" />|</span>
<span class="sheet-img-bonus"><img class="sheet-img-bonus"/>|</span>
<span class="sheet-img-livre"><img class="sheet-img-livre" />|</span>
<span class="sheet-img-passiva"><img class="sheet-img-passiva" />|</span>
<span class="sheet-img-reacao" ><img class="sheet-img-reacao" />|</span>
<span>{{{nameaction}}}</span> |
<span>{{custoacao}}</span>
</div>
{{#descritores_actions}}
<div class="sheet-actionspell-descriptor">
<span class="sheet-span-info">{{descritores_actions}}</span>
</div>
{{/descritores_actions}}
{{#info_actions}}
<div class="sheet-actionspell-info">
<span>{{info_actions}}</span>
</div>
{{/info_actions}}
<div class="sheet-actionspell-body">
{{#alcance_actions}}
<span class="sheet-span-info">Alcance:</span><span>{{alcance_actions}}</span><br>
{{/alcance_actions}}
{{#alvo_actions}}
<span class="sheet-span-info">Alvo:</span><span>{{alvo_actions}}</span><br>
{{/alvo_actions}}
{{#duracao_actions}}
<span class="sheet-span-info">Duração:</span><span>{{duracao_actions}}</span><br>
{{/duracao_actions}}
{{#component_actions}}
<span class="sheet-span-info">Componente:</span><span>{{component_actions}}</span><br>
{{/component_actions}}
</div>
{{#gatilho_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Gatilho:</span><span>{{gatilho_actions}}</span>
</div>
{{/gatilho_actions}}
{{#ataque_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Ataque:</span><span>{{ataque_actions}}</span>
</div>
{{/ataque_actions}}
{{#acerto_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Acerto:</span><span>{{acerto_actions}}</span>
</div>
{{/acerto_actions}}
{{#erro_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Erro:</span><span>{{erro_actions}}</span>
</div>
{{/erro_actions}}
{{#efeito_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Efeito:</span><span>{{efeito_actions}}</span>
</div>
{{/efeito_actions}}
{{#especial_actions}}
<div class="sheet-actionspell-body">
<span class="sheet-span-info">Especial:</span><span>{{especial_actions}}</span>
</div>
{{/especial_actions}}
{{#modificacoes}}
<div class="sheet-actionspell-body">
{{#rollGreater() modcheckone 0}}
<span>{{customod_actions}}</span> <span>{{tipomod_actions}}</span> <span>{{description_actions}}</span><br>
{{/rollGreater() modcheckone 0}}
{{#rollGreater() modchecktwo 0}}
<span>{{customodtwo}}</span> <span>{{tipomodtwo}}</span> <span>{{descriptiontwo}}</span><br>
{{/rollGreater() modchecktwo 0}}
{{#rollGreater() modcheckthree 0}}
<span>{{customodthree}}</span> <span>{{tipomodthree}}</span> <span>{{descriptionthree}}</span><br>
{{/rollGreater() modcheckthree 0}}
{{#rollGreater() modcheckfour 0}}
<span>{{customodfour}}</span> <span>{{tipomodfour}}</span> <span>{{descriptionfour}}</span><br>
{{/rollGreater() modcheckfour 0}}
{{#rollGreater() modcheckfive 0}}
<span>{{customodfive}}</span> <span>{{tipomodfive}}</span> <span>{{descriptionfive}}</span><br>
{{/rollGreater() modcheckfive 0}}
{{#rollGreater() modchecksix 0}}
<span>{{customodsix}}</span> <span>{{tipomodsix}}</span> <span>{{descriptionsix}}</span><br>
{{/rollGreater() modchecksix 0}}
{{#rollGreater() modcheckseven 0}}
<span>{{customodseven}}</span> <span>{{tipomodseven}}</span> <span>{{descriptionseven}}</span><br>
{{/rollGreater() modcheckseven 0}}
{{#rollGreater() modcheckeigth 0}}
<span>{{customodeigth}}</span> <span>{{tipomodeigth}}</span> <span>{{descriptioneigth}}</span><br>
{{/rollGreater() modcheckeigth 0}}
{{#rollGreater() modchecknine 0}}
<span>{{customodnine}}</span> <span>{{tipomodnine}}</span> <span>{{descriptionnine}}</span><br>
{{/rollGreater() modchecknine 0}}
{{#rollGreater() modcheckten 0}}
<span>{{customodten}}</span> <span>{{tipomodten}}</span> <span>{{descriptionten}}</span><br>
{{/rollGreater() modcheckten 0}}
</div>
{{/modificacoes}}
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-atkdmg">
{{#attack}}
<div class="container atk">
<div class="charname">
<span>{{character_name}}</span>
</div>
<div class="result">
<div class="solo">
<span>Ataque:</span><span>{{r1}}{{#globalattack}} + {{globalattack}}{{/globalattack}}</span>
</div>
</div>
{{#range}}
<div class="sublabel">
<span>Distância:</span><span>{{range}}</span>
</div>
{{/range}}
<div class="label">
<span>{{rname}}{{#innate}}<span class="grey">, {{innate}}</span>{{/innate}}{{#attack}} <span>({{mod}})</span>{{/attack}}</span>
</div>
</div>
{{/attack}}
{{#desc}}
<div class="desc info">
<span>
<span class="top"></span><span class="middle">{{desc}}</span><span class="bottom"></span>
</span>
</div>
{{/desc}}
{{#^rollTotal() globaldamage 0}}
<div class="desc">
<span>
{{globaldamage}}
{{#attack}}
{{#rollWasCrit() r1}}<span class="plus"> + </span>{{globaldamagecrit}}{{/rollWasCrit() r1}}
{{/attack}}
</span>
<span class="sublabel">{{globaldamagetype}}</span>
</div>
{{/^rollTotal() globaldamage 0}}
{{#damage}}
<div class="container damagetemplate">
<div class="result">
{{#dmg1flag}}
{{^dmg2flag}}
<div class="solo">
<span>Dano:</span>
<span class="damage">
{{dmg1}}
{{#attack}}
{{#rollWasCrit() r1}} + {{crit1}}{{/rollWasCrit() r1}}
{{/attack}}
</span>
<span class="sublabel">{{dmg1type}}</span>
</div>
{{/dmg2flag}}
{{/dmg1flag}}
{{#dmg2flag}}
{{^dmg1flag}}
<div class="solo">
<span>Dano 2:</span>
<span class="damage">
{{dmg2}}
{{#attack}}
{{#rollWasCrit() r1}}+ {{crit2}}{{/rollWasCrit() r1}}
{{/attack}}
</span>
<span class="sublabel">{{dmg2type}}</span>
</div>
{{/dmg1flag}}
{{/dmg2flag}}
{{#dmg1flag}}
{{#dmg2flag}}
<div class="adv">
<span class="damage">
{{dmg1}}
{{#attack}}
{{#rollWasCrit() r1}}+ {{crit1}}{{/rollWasCrit() r1}}
{{/attack}}
</span>
<span class="sublabel">{{dmg1type}}</span>
</div>
<div class="advspacer"></div>
<div class="adv">
<span>
{{dmg2}}
{{#attack}}
{{#rollWasCrit() r1}}+ {{crit2}}{{/rollWasCrit() r1}}
{{/attack}}
</span>
<span class="sublabel">{{dmg2type}}</span>
</div>
{{/dmg2flag}}
{{/dmg1flag}}
</div>
</div>
{{/damage}}
{{#reroll}}
<div class="sheet-skillreroll">
<span>{{reroll}}</span>
</div>
{{/reroll}}
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-skillroll">
<div class="container-actspell">
<div class="charname">
<span>{{character}}</span>
</div>
<div class="sheet-actionspell-header">
<span>{{{pericia}}}</span>
</div>
<div class="sheet-actionspell-info">
<span class="sheet-span-info">Rolagem</span><span>{{rolagem}}</span>
</div>
<div class="sheet-skillreroll">
<span>{{reroll}}</span>
</div>
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-characteristic">
<div class="container-characteristic">
<div class="charname">
<span>{{character_name}}</span>
</div>
<div class="sheet-actionspell-header">
<span>{{name}}</span>
</div>
<div class="sheet-actionspell-info">
<span>{{description}}</span>
</div>
</div>
</rolltemplate>