Updated Tab Navegation
This commit is contained in:
parent
972ff6f78b
commit
dd4e3e9582
@@ -1974,6 +1974,60 @@
|
||||
|
||||
.sheet-navegacao {
|
||||
border-bottom: 1px solid #969696;
|
||||
overflow: hidden;
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
.sheet-navegacao span{
|
||||
margin: 0 .5em 0 0;
|
||||
}
|
||||
|
||||
.sheet-navegacao label {
|
||||
position: relative;
|
||||
background: #ddd;
|
||||
background-image: linear-gradient(to bottom, #fff, #ddd);
|
||||
padding: .7em 0em;
|
||||
float: left;
|
||||
text-decoration: none;
|
||||
color: #444;
|
||||
text-shadow: 0 1px 0 rgba(255,255,255,.8);
|
||||
border-radius: 5px 0 0 0;
|
||||
box-shadow: 0 2px 2px rgba(0,0,0,.4);
|
||||
}
|
||||
|
||||
.sheet-navegacao label:hover,
|
||||
.sheet-navegacao label:hover::after,
|
||||
.sheet-navegacao label:focus,
|
||||
.sheet-navegacao label:focus::after {
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
.sheet-navegacao label:focus {
|
||||
outline: 0;
|
||||
}
|
||||
|
||||
.sheet-navegacao label::after {
|
||||
content:'';
|
||||
position:absolute;
|
||||
z-index: 1;
|
||||
top: 0;
|
||||
right: -.5em;
|
||||
bottom: 0;
|
||||
width: 1em;
|
||||
background: #ddd;
|
||||
background-image: linear-gradient(to bottom, #fff, #ddd);
|
||||
box-shadow: 2px 2px 2px rgba(0,0,0,.4);
|
||||
transform: skew(10deg);
|
||||
border-radius: 0 5px 0 0;
|
||||
}
|
||||
|
||||
.sheet-navegacao label,
|
||||
.sheet-navegacao label::after {
|
||||
background: #fff;
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
.sheet-navegacao > input{
|
||||
@@ -1989,7 +2043,7 @@
|
||||
outline: none
|
||||
}
|
||||
|
||||
.sheet-navegacao span {
|
||||
/*.sheet-navegacao span {
|
||||
color: #202020;
|
||||
height: 12px;
|
||||
font-size: 13px;
|
||||
@@ -2006,7 +2060,7 @@
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-top: 20px;
|
||||
}
|
||||
}*/
|
||||
|
||||
.sheet-main .sheet-hide-author>input {
|
||||
width: 50px;
|
||||
@@ -2837,7 +2891,7 @@
|
||||
display: inline-block;
|
||||
height: 20px !important;
|
||||
margin-bottom: 0px !important;
|
||||
width: 150px !important;
|
||||
width: 200px !important;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@@ -2851,21 +2905,15 @@
|
||||
|
||||
/* The slider */
|
||||
.sheet-slider {
|
||||
position: absolute;
|
||||
cursor: pointer;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
height: 20px !important;
|
||||
background-color: #ccc;
|
||||
-webkit-transition: .4s;
|
||||
transition: .4s;
|
||||
}
|
||||
|
||||
input:checked + .sheet-slider {
|
||||
background-color: #DA0F20;
|
||||
color: white;
|
||||
.sheet-switch-selected {
|
||||
background-color: #DA0F20 !important;
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
input:focus + .sheet-slider {
|
||||
@@ -2880,10 +2928,7 @@
|
||||
}
|
||||
|
||||
/* Rounded sliders */
|
||||
.sheet-slider.sheet-round {
|
||||
border: 1px solid black
|
||||
}
|
||||
|
||||
|
||||
.sheet-menace-spam{
|
||||
font-family: "Alegreya Sans SC";
|
||||
font-weight: bold;
|
||||
@@ -3173,7 +3218,7 @@
|
||||
}
|
||||
|
||||
.sheet-attack-icon, .sheet-damage-icon, .sheet-roll-icon, .sheet-skills-icon,
|
||||
.sheet-defense-icon, .sheet-armor-icon, .sheet-shield-icon {
|
||||
.sheet-defense-icon, .sheet-armor-icon, .sheet-shield-icon, .sheet-resist-icon {
|
||||
height: 20px;
|
||||
filter: invert(11%) sepia(83%) saturate(4245%) hue-rotate(348deg) brightness(97%) contrast(87%);
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
<div class="navegacao">
|
||||
<label class="switch">
|
||||
<label class="switch sheet-pj">
|
||||
<input id="cstype" class="hiddenelement" type="radio" name="attr_cstype" value="0" checked>
|
||||
<span class="slider round" data-i18n="player_charactersheet">Ficha Jogador</span>
|
||||
</label>
|
||||
<label class="switch">
|
||||
<label class="switch sheet-npj">
|
||||
<input id="cstype" class="hiddenelement" type="radio" name="attr_cstype" value="1">
|
||||
<span class="slider round" data-i18n="menace_charactersheet">Ficha Ameaça</span>
|
||||
</label>
|
||||
<label class="switch">
|
||||
<label class="switch sheet-mod">
|
||||
<input id="cstype" class="hiddenelement" type="radio" name="attr_cstype" value="2">
|
||||
<span class="slider round" data-i18n="global_charactersheet">Modificadores Globais</span>
|
||||
</label>
|
||||
@@ -143,7 +143,7 @@
|
||||
<img src="https://raw.githubusercontent.com/RoenMidnight/roll20-character-sheets/t20-goty-menace-character-sheet/Tormenta20%20-%20Jogo%20do%20Ano/icons/numerology.png" class="sheet-roll-icon hiddenelement" title="Rolagem" data-i18n-title="spam-roll"/>
|
||||
|
||||
<span class="sheet-skills-span hiddenelement" name="attr_skillsicon" title="Perícias" data-i18n-title="spam-skills"></span>
|
||||
<img src="https://raw.githubusercontent.com/RoenMidnight/roll20-character-sheets/t20-goty-menace-character-sheet/Tormenta20%20-%20Jogo%20do%20Ano/icons/numerology.png" class="sheet-skills-icon hiddenelement" title="Perícias" data-i18n-title="spam-skills"/>
|
||||
<img src="https://raw.githubusercontent.com/RoenMidnight/roll20-character-sheets/t20-goty-menace-character-sheet/Tormenta20%20-%20Jogo%20do%20Ano/icons/skills.png" class="sheet-skills-icon hiddenelement" title="Perícias" data-i18n-title="spam-skills"/>
|
||||
|
||||
<span class="sheet-resist-span hiddenelement" name="attr_resistsicon" title="Resistências" data-i18n-title="resistance"></span>
|
||||
<img src="https://raw.githubusercontent.com/RoenMidnight/roll20-character-sheets/t20-goty-menace-character-sheet/Tormenta20%20-%20Jogo%20do%20Ano/icons/resistence.png" class="sheet-resist-icon hiddenelement" title="Resistências" data-i18n-title="resistencias"/>
|
||||
@@ -438,12 +438,12 @@
|
||||
</div>
|
||||
<div>
|
||||
<select name="attr_tamanho">
|
||||
<option value="medio" selected="" data-i18n="medio">Médio</option>
|
||||
<option value="minusculo" data-i18n="minusculo">Minúsculo</option>
|
||||
<option value="pequeno" data-i18n="pequeno">Pequeno</option>
|
||||
<option value="grande" data-i18n="grande">Grande</option>
|
||||
<option value="enorme" data-i18n="enorme">Enorme</option>
|
||||
<option value="colossal" data-i18n="colossal">Colossal</option>
|
||||
<option value="0" selected="" data-i18n="medio">Médio</option>
|
||||
<option value="5" data-i18n="minusculo">Minúsculo</option>
|
||||
<option value="2" data-i18n="pequeno">Pequeno</option>
|
||||
<option value="-2" data-i18n="grande">Grande</option>
|
||||
<option value="-5" data-i18n="enorme">Enorme</option>
|
||||
<option value="-10" data-i18n="colossal">Colossal</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="corner top-left"></div>
|
||||
@@ -1037,7 +1037,7 @@
|
||||
</button>
|
||||
</div>
|
||||
<div class="signal"></div>
|
||||
<input class="total last" name="attr_furtividadetotal" maxlength="2" type="text" spellcheck="false" title="@{furtividadetotal}" value="@{metade_do_nivel} + @{condicaopericia} + @{periciatemp} + @{rolltemp} + @{furtividadeatributo2} + @{furtividadetreino} + @{furtividadeoutros} -1 * @{penalidades_armadura} -1 * @{penalidades_armadura_carga}" disabled="true">
|
||||
<input class="total last" name="attr_furtividadetotal" maxlength="2" type="text" spellcheck="false" title="@{furtividadetotal}" value="@{metade_do_nivel} + @{tamanho} + @{condicaopericia} + @{periciatemp} + @{rolltemp} + @{furtividadeatributo2} + @{furtividadetreino} + @{furtividadeoutros} -1 * @{penalidades_armadura} -1 * @{penalidades_armadura_carga}" disabled="true">
|
||||
<div class="signal">=</div>
|
||||
<select name="attr_furtividadeatributo2">
|
||||
<option value="@{for_mod} + @{condicaoperfisico} + @{condicaocego}" data-i18n="mod_forca">FOR</option>
|
||||
@@ -3062,29 +3062,11 @@
|
||||
"defenseicon": global_array[4][0],
|
||||
"armoricon": global_array[5][0],
|
||||
"shieldicon": global_array[6][0],
|
||||
"resisticon": global_array[7][0]
|
||||
"resistsicon": global_array[7][0]
|
||||
});
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
on("clicked:eraseglobal", function(){
|
||||
getAttrs(["rolltemp", "ataquetemp", "periciatemp", "danotemp", "defesafaketemp", "defesaarmaduratemp", "defesaescudotemp", "defesaoutrostemp",
|
||||
"fortemp", "destemp", "contemp", "inttemp", "sabtemp", "cartemp",
|
||||
], function(v){
|
||||
setAttrs({
|
||||
"rolltemp": 0, "ataquetemp": 0,"periciatemp": 0, "danotemp": 0,"defesafaketemp": 0, "defesaoutrostemp": 0,
|
||||
"defesaarmaduratemp": 0, "defesaescudotemp": 0,
|
||||
"fortemp": 0, "destemp": 0, "contemp": 0, "inttemp": 0, "sabtemp": 0, "cartemp": 0, "abalado": 0,
|
||||
"agarrado": 0,"alquebrado": 0,"apavorado": 0,"atordoado": 0,"caido": 0,"cego": 0,"confuso": 0,
|
||||
"debilitado": 0,"desprevenido": 0,"doente": 0,"emchama": 0,"enfeiticado": 0,"enjoado": 0,
|
||||
"enreado": 0,"envenenado": 0,"esmorecido": 0,"exausto": 0,"fascinado": 0,"fatigado": 0,
|
||||
"fraco": 0,"frustrado": 0,"imovel": 0,"inconsciente": 0,"indefeso": 0,"lento": 0,
|
||||
"ofuscado": 0,"paralizado": 0,"pasmo": 0,"petrificacao": 0,"sangrando": 0,
|
||||
"surdo": 0,"surpreendido": 0,"vulneravel": 0, "alquebrado": 0
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
//Trigger CalculoPesoMoeda
|
||||
on("sheet:opened change:ts", function(e){
|
||||
@@ -3096,7 +3078,7 @@
|
||||
on("sheet:opened change:extraslot", function(e){
|
||||
repeatingSumModified("carga","equipment",["equipquantity","equipslot"], "");
|
||||
});
|
||||
|
||||
|
||||
//Bonus em perícia por nível
|
||||
on("sheet:opened change:charnivel", function(e){
|
||||
getAttrs(["charnivel"], function(v){
|
||||
@@ -3305,7 +3287,7 @@
|
||||
|
||||
//Calculando Defesa Total:
|
||||
on("sheet:opened change:condicaodefesa change:defesaoutrostemp change:defesaarmaduratemp change:defesaescudotemp change:defesafaketemp change:defesaatributo change:armaduradefesa1 change:armaduradefesa2 change:defesaoutros change:for_mod change:des_mod change:con_mod change:int_mod change:sab_mod change:car_mod change:modatributodefesa change:caido", function(e){
|
||||
getAttrs(["condicaodefesa", "defesafaketemp", "defesaarmaduratemp", "defesaescudotemp", "defesaatributo", "armaduradefesa1", "armaduradefesa2", "defesaoutros", "for_mod", "des_mod", "con_mod", "int_mod", "sab_mod", "car_mod", "modatributodefesa", "caido"], function(v){
|
||||
getAttrs(["condicaodefesa", "defesafaketemp", "defesaoutrostemp", "defesaarmaduratemp", "defesaescudotemp", "defesaatributo", "armaduradefesa1", "armaduradefesa2", "defesaoutros", "for_mod", "des_mod", "con_mod", "int_mod", "sab_mod", "car_mod", "modatributodefesa", "caido"], function(v){
|
||||
let total = 10;
|
||||
|
||||
//Armadura
|
||||
@@ -3352,79 +3334,137 @@
|
||||
return charnivel
|
||||
}
|
||||
|
||||
on("clicked:eraseglobal", function(){
|
||||
getAttrs(["rolltemp", "ataquetemp", "periciatemp", "danotemp", "defesafaketemp", "defesaarmaduratemp", "defesaescudotemp", "defesaoutrostemp",
|
||||
"fortemp", "destemp", "contemp", "inttemp", "sabtemp", "cartemp",
|
||||
], function(v){
|
||||
setAttrs({
|
||||
"rolltemp": 0, "ataquetemp": 0,"periciatemp": 0, "resistemp":0, "danotemp": 0,"defesafaketemp": 0, "defesaoutrostemp": 0,
|
||||
"defesaarmaduratemp": 0, "defesaescudotemp": 0,
|
||||
"fortemp": 0, "destemp": 0, "contemp": 0, "inttemp": 0, "sabtemp": 0, "cartemp": 0, "abalado": 0,
|
||||
"agarrado": 0,"alquebrado": 0,"apavorado": 0,"atordoado": 0,"caido": 0,"cego": 0,"confuso": 0,
|
||||
"debilitado": 0,"desprevenido": 0,"doente": 0,"emchama": 0,"enfeiticado": 0,"enjoado": 0,
|
||||
"enreado": 0,"envenenado": 0,"esmorecido": 0,"exausto": 0,"fascinado": 0,"fatigado": 0,
|
||||
"fraco": 0,"frustrado": 0,"imovel": 0,"inconsciente": 0,"indefeso": 0,"lento": 0,
|
||||
"ofuscado": 0,"paralizado": 0,"pasmo": 0,"petrificacao": 0,"sangrando": 0,
|
||||
"surdo": 0,"surpreendido": 0,"vulneravel": 0, "alquebrado": 0
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
//Troca entre a ficha de ameaças e a ficha de jogador
|
||||
on("sheet:opened change:cstype", function(e){
|
||||
getAttrs(["cstype"], function(v){
|
||||
if (v.cstype == 0) {
|
||||
$20('.sheet-left-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').removeClass('sheet-hiddenelement');
|
||||
on("sheet:opened change:cstype change:resistemp", function(e){
|
||||
getAttrs(["cstype"], function(v){
|
||||
if (v.cstype == 0) {
|
||||
$20('.sheet-left-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').removeClass('sheet-hiddenelement');
|
||||
|
||||
$20('.sheet-menace-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-menace-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').addClass('sheet-hiddenelement');
|
||||
|
||||
}
|
||||
$20('.sheet-pj').addClass('sheet-switch-selected');
|
||||
$20('.sheet-npj').removeClass('sheet-switch-selected');
|
||||
$20('.sheet-mod').removeClass('sheet-switch-selected');
|
||||
|
||||
if (v.cstype == 1){
|
||||
$20('.sheet-left-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').addClass('sheet-hiddenelement');
|
||||
}
|
||||
|
||||
$20('.sheet-menace-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').addClass('sheet-hiddenelement');
|
||||
}
|
||||
if (v.cstype == 1){
|
||||
$20('.sheet-left-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').addClass('sheet-hiddenelement');
|
||||
|
||||
if (v.cstype == 2){
|
||||
$20('.sheet-left-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-menace-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').addClass('sheet-hiddenelement');
|
||||
|
||||
$20('.sheet-menace-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').removeClass('sheet-hiddenelement');
|
||||
}
|
||||
});
|
||||
|
||||
getAttrs(["character_name", "vida_max", "manatotal", "manatemp", "charnivel", "bonus_treino",
|
||||
"iniciativaatributo2", "percepcaoatributo2", "fortitudeatributo2", "reflexosatributo2", "vontadeatributo2",
|
||||
"iniciativa_treinada", "percepcao_treinada", "fortitude_treinada", "reflexos_treinada", "vontade_treinada",
|
||||
"iniciativaoutros", "percepcaooutros", "fortitudeoutros", "reflexosoutros", "vontadeoutros",
|
||||
"for_mod", "des_mod", "int_mod", "sab_mod", "con_mod", "car_mod",
|
||||
"condicaopericia", "periciatemp", "rolltemp", "condicaoiniciativa", "condicaopercepcao",
|
||||
"condicaoreflexo"
|
||||
], function(v){
|
||||
let setObj = {}
|
||||
setObj['menace_name'] = v.character_name;
|
||||
setObj['menace_hp'] = v.vida_max;
|
||||
let mana_total = parseInt(v.manatotal) ? parseInt(v.manatotal) : 0;
|
||||
let mana_temp = parseInt(v.manatemp) ? parseInt(v.manatemp) : 0;
|
||||
setObj['menace_mp'] = mana_total + mana_temp;
|
||||
setObj['menace_nd'] = convertToND(v.charnivel);
|
||||
$20('.sheet-pj').removeClass('sheet-switch-selected');
|
||||
$20('.sheet-npj').addClass('sheet-switch-selected');
|
||||
$20('.sheet-mod').removeClass('sheet-switch-selected');
|
||||
}
|
||||
|
||||
if (v.cstype == 2){
|
||||
$20('.sheet-left-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-right-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-charnotes-container').addClass('sheet-hiddenelement');
|
||||
|
||||
let metade_nivel = Math.floor(Number.parseFloat(v.charnivel)/2);
|
||||
$20('.sheet-menace-container').addClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container').removeClass('sheet-hiddenelement');
|
||||
$20('.sheet-global-container-conditions').removeClass('sheet-hiddenelement');
|
||||
|
||||
$20('.sheet-pj').removeClass('sheet-switch-selected');
|
||||
$20('.sheet-npj').removeClass('sheet-switch-selected');
|
||||
$20('.sheet-mod').addClass('sheet-switch-selected');
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
getAttrs(["character_name", "vida_max", "manatotal", "manatemp", "charnivel", "bonus_treino",
|
||||
"iniciativaatributo2", "percepcaoatributo2", "fortitudeatributo2", "reflexosatributo2", "vontadeatributo2",
|
||||
"iniciativa_treinada", "percepcao_treinada", "fortitude_treinada", "reflexos_treinada", "vontade_treinada",
|
||||
"iniciativaoutros", "percepcaooutros", "fortitudeoutros", "reflexosoutros", "vontadeoutros",
|
||||
"for_mod", "des_mod", "int_mod", "sab_mod", "con_mod", "car_mod",
|
||||
"condicaopericia", "periciatemp", "rolltemp", "condicaoiniciativa", "condicaopercepcao",
|
||||
"condicaoreflexo", "resistemp",
|
||||
"condicaoperfisico", "condicaopermental", "condicaocego", "condicaomodataquedis"
|
||||
], function(v){
|
||||
|
||||
let setObj = {}
|
||||
setObj['menace_name'] = v.character_name;
|
||||
setObj['menace_hp'] = v.vida_max;
|
||||
let mana_total = parseInt(v.manatotal) ? parseInt(v.manatotal) : 0;
|
||||
let mana_temp = parseInt(v.manatemp) ? parseInt(v.manatemp) : 0;
|
||||
setObj['menace_mp'] = mana_total + mana_temp;
|
||||
setObj['menace_nd'] = convertToND(v.charnivel);
|
||||
|
||||
let atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(v.condicaoiniciativa) + parseInt(metade_nivel) + parseInt(v[stripTag(v.iniciativaatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.iniciativa_treinada)) + parseInt(v.iniciativaoutros);
|
||||
setObj['menace_init'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(v.condicaopercepcao) + parseInt(metade_nivel) + parseInt(v[stripTag(v.percepcaoatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.percepcao_treinada)) + parseInt(v.percepcaooutros);
|
||||
setObj['menace_percep'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(v[stripTag(v.fortitudeatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.fortitude_treinada)) + parseInt(v.fortitudeoutros);
|
||||
setObj['menace_fortitude'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(v[stripTag(v.reflexosatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.reflexos_treinada)) + parseInt(v.reflexosoutros);
|
||||
setObj['menace_reflex'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
atribute = parseInt(v.condicaoreflexo) + parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(v[stripTag(v.vontadeatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.vontade_treinada)) + parseInt(v.vontadeoutros);
|
||||
setObj['menace_will'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
|
||||
if (v.mana_max <= 0){
|
||||
$20('.sheet-menace-mana').addClass('sheet-hiddenelement');
|
||||
} else {
|
||||
$20('.sheet-menace-mana').removeClass('sheet-hiddenelement');
|
||||
}
|
||||
let metade_nivel = Math.floor(Number.parseFloat(v.charnivel)/2);
|
||||
|
||||
let atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(v.condicaoiniciativa) + parseInt(metade_nivel) + parseInt(v[stripTag(v.iniciativaatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.iniciativa_treinada)) + parseInt(v.iniciativaoutros);
|
||||
setObj['menace_init'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
atribute = parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(v.condicaopercepcao) + parseInt(metade_nivel) + parseInt(v[stripTag(v.percepcaoatributo2)]) + (parseInt(v.bonus_treino) * parseInt(v.percepcao_treinada)) + parseInt(v.percepcaooutros);
|
||||
setObj['menace_percep'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
|
||||
setAttrs(setObj);
|
||||
});
|
||||
let splitAttr = stripTag(v.fortitudeatributo2).split("+");
|
||||
let attrSum = 0;
|
||||
|
||||
for(let i=0; i < splitAttr.length; i++){
|
||||
attrSum += parseInt(v[stripTag(splitAttr[i].trim())]);
|
||||
}
|
||||
|
||||
atribute = parseInt(v.resistemp) + parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(attrSum) + (parseInt(v.bonus_treino) * parseInt(v.fortitude_treinada)) + parseInt(v.fortitudeoutros);
|
||||
setObj['menace_fortitude'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
|
||||
splitAttr = stripTag(v.reflexosatributo2).split("+");
|
||||
attrSum = 0;
|
||||
|
||||
for(let i=0; i < splitAttr.length; i++){
|
||||
attrSum += parseInt(v[stripTag(splitAttr[i].trim())]);
|
||||
}
|
||||
|
||||
atribute = parseInt(v.resistemp) + parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(attrSum) + (parseInt(v.bonus_treino) * parseInt(v.reflexos_treinada)) + parseInt(v.reflexosoutros);
|
||||
setObj['menace_reflex'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
|
||||
splitAttr = stripTag(v.vontadeatributo2).split("+");
|
||||
attrSum = 0;
|
||||
|
||||
for(let i=0; i < splitAttr.length; i++){
|
||||
attrSum += parseInt(v[stripTag(splitAttr[i].trim())]);
|
||||
}
|
||||
|
||||
atribute = parseInt(v.resistemp) + parseInt(v.condicaoreflexo) + parseInt(v.condicaopericia) + parseInt(v.periciatemp) + parseInt(v.rolltemp) + parseInt(metade_nivel) + parseInt(attrSum) + (parseInt(v.bonus_treino) * parseInt(v.vontade_treinada)) + parseInt(v.vontadeoutros);
|
||||
setObj['menace_will'] = atribute > 0 ? "+" + atribute : atribute;
|
||||
|
||||
if (v.mana_max <= 0){
|
||||
$20('.sheet-menace-mana').addClass('sheet-hiddenelement');
|
||||
} else {
|
||||
$20('.sheet-menace-mana').removeClass('sheet-hiddenelement');
|
||||
}
|
||||
|
||||
setAttrs(setObj);
|
||||
});
|
||||
|
||||
[
|
||||
'acrobacia','adestramento','atletismo','atuacao','cavalgar','conhecimento','cura','diplomacia',
|
||||
@@ -3471,7 +3511,7 @@
|
||||
}
|
||||
|
||||
|
||||
const stripTag = (tag) => { return tag.replace('@{','').replace('}','').replace('+@{condicaomodataquecc}+@{condicaomodataque}',''); }
|
||||
const stripTag = (tag) => { return tag.replace('@{','').replace('}','').replace('+@{condicaomodataquecc}+@{condicaomodataque}','').replace(' ',''); }
|
||||
|
||||
const createDice = () => {
|
||||
return '<button type="roll" name="roll_attack" class="buttonrollataque dado-simples" value="">T</button>'
|
||||
|
||||
Reference in New Issue
Block a user