fixed errors
This commit is contained in:
parent
8cb1deaea7
commit
c937db6f9a
392
index.php
392
index.php
@ -644,245 +644,233 @@
|
|||||||
|
|
||||||
|
|
||||||
function calcDiff() {
|
function calcDiff() {
|
||||||
$("#diff_image").attr("src", "img/notfound.jpg");
|
$("#diff_image").attr("src", "img/notfound.jpg");
|
||||||
$("#diff_description").html("I was unable to find a calculation with those parameters.... or any programming at all... give me some time, i'm still working on this app, after all.");
|
$("#diff_description").html("I was unable to find a calculation with those parameters.... or any programming at all... give me some time, i'm still working on this app, after all.");
|
||||||
$("#diff_summary").html("#err_notfound");
|
$("#diff_summary").html("#err_notfound");
|
||||||
|
|
||||||
//MODIFIERS
|
//MODIFIERS
|
||||||
//These are to influence how STRONK the weighting of the different
|
//These are to influence how STRONK the weighting of the different
|
||||||
// thins are.... yes that helps...
|
// thins are.... yes that helps...
|
||||||
|
|
||||||
//Set the Mob Modifier
|
//Set the Mob Modifier
|
||||||
modifier_encounter = 1;
|
modifier_encounter = 1;
|
||||||
modifier_party = 1;
|
modifier_party = 1;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//All Player Stats
|
//All Player Stats
|
||||||
|
|
||||||
//The Party itself, each variable can range form 1 to infinity
|
//The Party itself, each variable can range form 1 to infinity
|
||||||
var party_meelee_fighters = $("#party_meelee").val();
|
var party_meelee_fighters = $("#party_meelee").val();
|
||||||
var party_range_fighters = $("#party_long_range").val();
|
var party_range_fighters = $("#party_long_range").val();
|
||||||
var party_magic_fighters = $("#party_magic").val();
|
var party_magic_fighters = $("#party_magic").val();
|
||||||
var party_support_fighters = $("#party_support").val();
|
var party_support_fighters = $("#party_support").val();
|
||||||
|
|
||||||
//This counts the amount of Party Members for convenience
|
//This counts the amount of Party Members for convenience
|
||||||
var party_amount = party_meelee_fighters + party_range_fighters + party_magic_fighters + party_support_fighters;
|
var party_amount = party_meelee_fighters + party_range_fighters + party_magic_fighters + party_support_fighters;
|
||||||
|
|
||||||
//Party Weighting
|
//Party Weighting
|
||||||
//Too Lazy. I could add something like when the difference
|
//Too Lazy. I could add something like when the difference
|
||||||
//between two categories is a certain amount, they automatically
|
//between two categories is a certain amount, they automatically
|
||||||
//get weightet with more power or something. Somethingsomething
|
//get weightet with more power or something. Somethingsomething
|
||||||
//balance.
|
//balance.
|
||||||
|
|
||||||
//Party Levels (1-20)
|
//Party Levels (1-20)
|
||||||
var party_level = $("#party_level").val();
|
var party_level = $("#party_level").val();
|
||||||
|
|
||||||
//Party Health (1-4) 1=healthy 4=almost dead
|
//Party Health (1-4) 1=healthy 4=almost dead
|
||||||
var party_health = $("input[name='party_health']:checked").val();
|
var party_health = $("input[name='party_health']:checked").val();
|
||||||
var party_health_score = party_health * 5;
|
var party_health_score = party_health * 5;
|
||||||
|
|
||||||
//Party Skill
|
//Party Skill
|
||||||
var party_skill_knowledge = $("input[name='party_dndknowledge']:checked").val();
|
var party_skill_knowledge = $("input[name='party_dndknowledge']:checked").val();
|
||||||
var party_skill_knowledge_score = Math.round(party_skill_knowledge * 6.666666666666666666);
|
var party_skill_knowledge_score = Math.round(party_skill_knowledge * 6.666666666666666666);
|
||||||
|
|
||||||
var party_skill_attention = $("input[name='party_attention']:checked").val();
|
var party_skill_attention = $("input[name='party_attention']:checked").val();
|
||||||
var party_skill_attention_score = Math.round(party_skill_attention * 6.666666666666666666);
|
var party_skill_attention_score = Math.round(party_skill_attention * 6.666666666666666666);
|
||||||
|
|
||||||
var party_skill_strategies = $("input[name='party_strategies']:checked").val();
|
var party_skill_strategies = $("input[name='party_strategies']:checked").val();
|
||||||
var party_skill_strategies_score = Math.round(party_skill_attention * 6.666666666666666666);
|
var party_skill_strategies_score = Math.round(party_skill_strategies * 6.666666666666666666);
|
||||||
|
|
||||||
|
|
||||||
var party_final_score = party_skill_strategies_score + party_skill_attention_score + party_skill_knowledge_score + party_health_score;
|
var party_final_score = party_skill_strategies_score + party_skill_attention_score + party_skill_knowledge_score + party_health_score;
|
||||||
|
|
||||||
//Monster Setup
|
//Monster Setup
|
||||||
//Monster amount
|
//Monster amount
|
||||||
var encounter_amount = $("input[name='mob_ammount']:checked").val();
|
var encounter_amount = $("input[name='mob_ammount']:checked").val();
|
||||||
|
|
||||||
// A modifier, that applies the ratio of Enemies to players
|
// A modifier, that applies the ratio of Enemies to players
|
||||||
var global_amount_modifier = encounter_amount/party_amount;
|
var global_amount_modifier = encounter_amount / party_amount;
|
||||||
|
|
||||||
// What HP Type is used? 1=average 2=rolled 3=max
|
// What HP Type is used? 1=average 2=rolled 3=max
|
||||||
var encounter_hp_type = $("input[name='mob_hp_type']:checked").val();
|
var encounter_hp_type = $("input[name='mob_hp_type']:checked").val();
|
||||||
|
|
||||||
if (encounter_hp_type == 1) {
|
|
||||||
//reset scores
|
|
||||||
encounter_hp_type_rolls_added_score = 0
|
|
||||||
encounter_hp_type_averages_score = 0
|
|
||||||
encounter_hp_type_max_score = 0
|
|
||||||
|
|
||||||
|
|
||||||
//IF Using Health Rolls
|
//reset scores
|
||||||
var encounter_hp_type_rolls_amount = $("#mob_hp_dice_ammount").val();
|
var encounter_hp_type_rolls_added_score = 0;
|
||||||
var encounter_hp_type_rolls_dice = $("#mob_hp_dice_type").val();
|
var encounter_hp_type_averages_score = 0;
|
||||||
//Evaluate by adding the two scores.
|
var encounter_hp_type_max_score = 0;
|
||||||
//I Debated multiplying the points but that would just be the max HP value.
|
if (encounter_hp_type == 1) {
|
||||||
//In the end, it's always hard to give a fair result.
|
|
||||||
var encounter_hp_type_rolls_added = encounter_hp_type_rolls_amount + encounter_hp_type_rolls_dice;
|
|
||||||
var encounter_hp_type_rolls_added_score = 20/(encounter_hp_type_rolls_added / party_amount);
|
|
||||||
|
|
||||||
} else if (encounter_hp_type == 2) {
|
|
||||||
//reset scores
|
|
||||||
encounter_hp_type_rolls_added_score = 0
|
|
||||||
encounter_hp_type_averages_score = 0
|
|
||||||
encounter_hp_type_max_score = 0
|
|
||||||
|
|
||||||
//IF Using Averages
|
|
||||||
var encounter_hp_type_averages = $("#mob_hp_avg").val();
|
|
||||||
var encounter_hp_type_averages_score = 20/(encounter_hp_type_averages / party_amount);
|
|
||||||
|
|
||||||
} else if (encounter_hp_type == 3) {
|
|
||||||
//reset scores
|
|
||||||
encounter_hp_type_rolls_added_score = 0
|
|
||||||
encounter_hp_type_averages_score = 0
|
|
||||||
encounter_hp_type_max_score = 0
|
|
||||||
|
|
||||||
//IF Using Averages
|
|
||||||
var encounter_hp_type_max = $("#mob_hp_max").val();
|
|
||||||
var encounter_hp_type_max_score = 20/(encounter_hp_type_max / party_amount);
|
|
||||||
|
|
||||||
}
|
|
||||||
var encounter_hp_score = encounter_hp_type_rolls_added_score + encounter_hp_type_averages_score + encounter_hp_type_max_score
|
|
||||||
|
|
||||||
// CR Calculation
|
|
||||||
var encounter_cr = $("#mob_CR").val();
|
|
||||||
var encounter_cr_per_player = encounter_cr / party_amount;
|
|
||||||
var encounter_cr_score = (encounter_cr_per_player / party_level) / 20;
|
|
||||||
|
|
||||||
//This sets the AC Score of the encounter.
|
|
||||||
var encounter_ac = $("#mob_ac").val();
|
|
||||||
var encounter_ac_score = (encounter_ac - 2) * global_amount_modifier;
|
|
||||||
|
|
||||||
// What Damage Type is used? 1=average 2=rolled 3=max
|
|
||||||
var encounter_dmg_type = $("input[name='mob_dmg_type']:checked").val();
|
|
||||||
|
|
||||||
if (encounter_dmg_type == 1) {
|
|
||||||
//reset scores
|
|
||||||
encounter_dmg_type_rolls_added_score = 0
|
|
||||||
encounter_dmg_type_averages_score = 0
|
|
||||||
encounter_dmg_type_max_score = 0
|
|
||||||
|
|
||||||
//IF Using Health Rolls
|
|
||||||
var encounter_dmg_type_rolls_amount = $("#mob_dmg_dice_ammount").val();
|
|
||||||
var encounter_dmg_type_rolls_dice = $("#mob_dmg_dice_type").val();
|
|
||||||
//Evaluate by adding the two scores.
|
|
||||||
//I Debated multiplying the points but that would just be the max dmg value.
|
|
||||||
//In the end, it's always hard to give a fair result.
|
|
||||||
var encounter_dmg_type_rolls_added = encounter_dmg_type_rolls_amount + encounter_dmg_type_rolls_dice;
|
|
||||||
var encounter_dmg_type_rolls_added_score = 20/(encounter_dmg_type_rolls_added / party_amount);
|
|
||||||
} else if (encounter_dmg_type == 2) {
|
|
||||||
//reset scores
|
|
||||||
encounter_dmg_type_rolls_added_score = 0
|
|
||||||
encounter_dmg_type_averages_score = 0
|
|
||||||
encounter_dmg_type_max_score = 0
|
|
||||||
|
|
||||||
//IF Using Averages
|
|
||||||
var encounter_dmg_type_averages = $("#mob_dmg_avg").val();
|
|
||||||
var encounter_dmg_type_averages_score = 20/(encounter_dmg_type_averages / party_amount);
|
|
||||||
} else if (encounter_dmg_type == 3) {
|
|
||||||
//reset scores
|
|
||||||
encounter_dmg_type_rolls_added_score = 0
|
|
||||||
encounter_dmg_type_averages_score = 0
|
|
||||||
encounter_dmg_type_max_score = 0
|
|
||||||
|
|
||||||
//IF Using Averages
|
|
||||||
var encounter_dmg_type_max = $("#mob_dmg_max").val();
|
|
||||||
var encounter_dmg_type_max_score = 20/(encounter_dmg_type_max / party_amount);
|
|
||||||
}
|
|
||||||
var encounter_dmg_score = encounter_dmg_type_rolls_added_score + encounter_dmg_type_averages_score + encounter_dmg_type_max_score
|
|
||||||
|
|
||||||
var encounter_dmgtype_possibilities = 0
|
|
||||||
var encounter_dmgtype_points = 0;
|
|
||||||
$.each($("input[name='dmgtype']:checked"), function(){
|
|
||||||
encounter_dmgtype_points++;
|
|
||||||
//selected_dmgtypes.push($(this).val());
|
|
||||||
});
|
|
||||||
$.each($("input[name='dmgtype']"), function(){
|
|
||||||
encounter_dmgtype_possibilities++;
|
|
||||||
});
|
|
||||||
|
|
||||||
var encounter_dmgtype_score = (20 - encounter_dmgtype_possibilities) + encounter_dmgtype_points * global_amount_modifier;
|
|
||||||
|
|
||||||
var encounter_onehit_score = $("input[name='mob_onehits']:checked").val();
|
|
||||||
|
|
||||||
var encounter_multiattack_score = $("input[name='mob_multiattack']:checked").val() * global_amount_modifier;
|
|
||||||
|
|
||||||
var encounter_strategy = $("input[name='mob_strategy']:checked").val();
|
|
||||||
var encounter_strategy_score = Math.round(encounter_strategy * 5);
|
|
||||||
|
|
||||||
var encounter_lair_action_score = $("input[name='mob_lair_action']:checked").val();
|
|
||||||
|
|
||||||
var encounter_legendairy_action_score = $("input[name='mob_legendary_action']:checked").val();
|
|
||||||
|
|
||||||
|
|
||||||
// Immunity Resistances and Vounerabilities
|
//IF Using Health Rolls
|
||||||
var encounter_immunities = 0;
|
var encounter_hp_type_rolls_amount = $("#mob_hp_dice_ammount").val();
|
||||||
var encounter_resistances = 0;
|
var encounter_hp_type_rolls_dice = $("#mob_hp_dice_type").val();
|
||||||
var encounter_vounerabilities = 0;
|
//Evaluate by adding the two scores.
|
||||||
|
//I Debated multiplying the points but that would just be the max HP value.
|
||||||
|
//In the end, it's always hard to give a fair result.
|
||||||
|
var encounter_hp_type_rolls_added = encounter_hp_type_rolls_amount + encounter_hp_type_rolls_dice;
|
||||||
|
encounter_hp_type_rolls_added_score = 20 / (encounter_hp_type_rolls_added / party_amount);
|
||||||
|
|
||||||
$.each($("input[name='mob_immunities']:checked"), function(){
|
} else if (encounter_hp_type == 2) {
|
||||||
encounter_resistances++;
|
|
||||||
//selected_dmgtypes.push($(this).val());
|
|
||||||
});
|
|
||||||
$.each($("input[name='mob_resitances']:checked"), function(){
|
|
||||||
encounter_immunities++;
|
|
||||||
//selected_dmgtypes.push($(this).val());
|
|
||||||
});
|
|
||||||
$.each($("input[name='mob_vounerabilities']:checked"), function(){
|
|
||||||
encounter_vounerabilities++
|
|
||||||
//selected_dmgtypes.push($(this).val());
|
|
||||||
});
|
|
||||||
|
|
||||||
var encounter_status_score = global_amount_modifier*(encounter_resistances + (encounter_immunities*2)) - encounter_vounerabilities;
|
//IF Using Averages
|
||||||
|
var encounter_hp_type_averages = $("#mob_hp_avg").val();
|
||||||
|
encounter_hp_type_averages_score = 20 / (encounter_hp_type_averages / party_amount);
|
||||||
|
|
||||||
var encounter_healing_score = 0;
|
} else if (encounter_hp_type == 3) {
|
||||||
$.each($("input[name='mob_healing']:checked"), function(){
|
|
||||||
encounter_healing_score = encounter_healing_score + $(this).val();
|
|
||||||
});
|
|
||||||
|
|
||||||
var encounter_stunning_score = $("input[name='mob_stun']:checked").val();
|
//IF Using Averages
|
||||||
|
var encounter_hp_type_max = $("#mob_hp_max").val();
|
||||||
|
encounter_hp_type_max_score = 20 / (encounter_hp_type_max / party_amount);
|
||||||
|
|
||||||
|
}
|
||||||
|
var encounter_hp_score = encounter_hp_type_rolls_added_score + encounter_hp_type_averages_score + encounter_hp_type_max_score;
|
||||||
|
|
||||||
|
// CR Calculation
|
||||||
|
var encounter_cr = $("#mob_CR").val();
|
||||||
|
var encounter_cr_per_player = encounter_cr / party_amount;
|
||||||
|
var encounter_cr_score = (encounter_cr_per_player / party_level) / 20;
|
||||||
|
|
||||||
|
//This sets the AC Score of the encounter.
|
||||||
|
var encounter_ac = $("#mob_ac").val();
|
||||||
|
var encounter_ac_score = (encounter_ac - 2) * global_amount_modifier;
|
||||||
|
|
||||||
|
// What Damage Type is used? 1=average 2=rolled 3=max
|
||||||
|
var encounter_dmg_type = $("input[name='mob_dmg_type']:checked").val();
|
||||||
|
|
||||||
|
//reset scores
|
||||||
|
var encounter_dmg_type_rolls_added_score = 0;
|
||||||
|
var encounter_dmg_type_averages_score = 0;
|
||||||
|
var encounter_dmg_type_max_score = 0;
|
||||||
|
if (encounter_dmg_type == 1) {
|
||||||
|
|
||||||
|
//IF Using Health Rolls
|
||||||
|
var encounter_dmg_type_rolls_amount = $("#mob_dmg_dice_ammount").val();
|
||||||
|
var encounter_dmg_type_rolls_dice = $("#mob_dmg_dice_type").val();
|
||||||
|
//Evaluate by adding the two scores.
|
||||||
|
//I Debated multiplying the points but that would just be the max dmg value.
|
||||||
|
//In the end, it's always hard to give a fair result.
|
||||||
|
var encounter_dmg_type_rolls_added = encounter_dmg_type_rolls_amount + encounter_dmg_type_rolls_dice;
|
||||||
|
encounter_dmg_type_rolls_added_score = 20 / (encounter_dmg_type_rolls_added / party_amount);
|
||||||
|
} else if (encounter_dmg_type == 2) {
|
||||||
|
|
||||||
|
//IF Using Averages
|
||||||
|
var encounter_dmg_type_averages = $("#mob_dmg_avg").val();
|
||||||
|
encounter_dmg_type_averages_score = 20 / (encounter_dmg_type_averages / party_amount);
|
||||||
|
} else if (encounter_dmg_type == 3) {
|
||||||
|
|
||||||
|
//IF Using Averages
|
||||||
|
var encounter_dmg_type_max = $("#mob_dmg_max").val();
|
||||||
|
encounter_dmg_type_max_score = 20 / (encounter_dmg_type_max / party_amount);
|
||||||
|
}
|
||||||
|
var encounter_dmg_score = encounter_dmg_type_rolls_added_score + encounter_dmg_type_averages_score + encounter_dmg_type_max_score;
|
||||||
|
|
||||||
|
var encounter_dmgtype_possibilities = 0;
|
||||||
|
var encounter_dmgtype_points = 0;
|
||||||
|
$.each($("input[name='dmgtype']:checked"), function() {
|
||||||
|
encounter_dmgtype_points++;
|
||||||
|
//selected_dmgtypes.push($(this).val());
|
||||||
|
});
|
||||||
|
$.each($("input[name='dmgtype']"), function() {
|
||||||
|
encounter_dmgtype_possibilities++;
|
||||||
|
});
|
||||||
|
|
||||||
|
var encounter_dmgtype_score = (20 - encounter_dmgtype_possibilities) + encounter_dmgtype_points * global_amount_modifier;
|
||||||
|
|
||||||
|
var encounter_onehit_score = $("input[name='mob_onehits']:checked").val();
|
||||||
|
|
||||||
|
var encounter_multiattack_score = $("input[name='mob_multiattack']:checked").val() * global_amount_modifier;
|
||||||
|
|
||||||
|
var encounter_strategy = $("input[name='mob_strategy']:checked").val();
|
||||||
|
var encounter_strategy_score = Math.round(encounter_strategy * 5);
|
||||||
|
|
||||||
|
var encounter_lair_action_score = $("input[name='mob_lair_action']:checked").val();
|
||||||
|
|
||||||
|
var encounter_legendairy_action_score = $("input[name='mob_legendary_action']:checked").val();
|
||||||
|
|
||||||
|
|
||||||
var encounter_conditions = 0;
|
// Immunity Resistances and Vounerabilities
|
||||||
var encounter_apply_conditions = 0;
|
var encounter_immunities = 0;
|
||||||
|
var encounter_resistances = 0;
|
||||||
|
var encounter_vounerabilities = 0;
|
||||||
|
|
||||||
$.each($("input[name='mob_resitances']:checked"), function(){
|
$.each($("input[name='mob_immunities']:checked"), function() {
|
||||||
encounter_conditions++;
|
encounter_resistances++;
|
||||||
//selected_dmgtypes.push($(this).val());
|
//selected_dmgtypes.push($(this).val());
|
||||||
});
|
});
|
||||||
|
$.each($("input[name='mob_resitances']:checked"), function() {
|
||||||
|
encounter_immunities++;
|
||||||
|
//selected_dmgtypes.push($(this).val());
|
||||||
|
});
|
||||||
|
$.each($("input[name='mob_vounerabilities']:checked"), function() {
|
||||||
|
encounter_vounerabilities++;
|
||||||
|
//selected_dmgtypes.push($(this).val());
|
||||||
|
});
|
||||||
|
|
||||||
$.each($("input[name='applying_conditions']:checked"), function(){
|
var encounter_status_score = global_amount_modifier * (encounter_resistances + (encounter_immunities * 2)) - encounter_vounerabilities;
|
||||||
encounter_apply_conditions++;
|
var encounter_healing_score = 0;
|
||||||
//selected_dmgtypes.push($(this).val());
|
$.each($("input[name='mob_healing']:checked"), function() {
|
||||||
});
|
encounter_healing_score = encounter_healing_score + $(this).val();
|
||||||
|
});
|
||||||
|
var encounter_stunning_score = $("input[name='mob_stun']:checked").val();
|
||||||
|
|
||||||
encounter_condition_score = applying_conditions*5-encounter_conditions*3
|
|
||||||
|
|
||||||
//Clamp the score
|
var encounter_conditions = 0;
|
||||||
if (encounter_condition_score > 20) {
|
var encounter_apply_conditions = 0;
|
||||||
encounter_condition_score = 20
|
|
||||||
} else if (encounter_condition_score < -20) {
|
|
||||||
encounter_condition_score = -20
|
|
||||||
}
|
|
||||||
|
|
||||||
encounter_final_score = encounter_hp_score + encounter_cr_score + encounter_ac_score + encounter_dmg_score + encounter_dmgtype_score + encounter_onehit_score + encounter_multiattack_score + encounter_strategy_score + encounter_lair_action_score + encounter_legendairy_action_score + encounter_status_score + encounter_healing_score + encounter_stunning_score + encounter_condition_score
|
$.each($("input[name='mob_resitances']:checked"), function() {
|
||||||
|
encounter_conditions++;
|
||||||
|
//selected_dmgtypes.push($(this).val());
|
||||||
|
});
|
||||||
|
|
||||||
//FINAL CALCULATION
|
$.each($("input[name='applying_conditions']:checked"), function() {
|
||||||
//Party Points:
|
encounter_apply_conditions++;
|
||||||
var final_score = (encounter_final_score * modifier_encounter) - (party_final_score * modifier_party)
|
//selected_dmgtypes.push($(this).val());
|
||||||
|
});
|
||||||
|
|
||||||
var party_variables = [party_skill_strategies_score, party_skill_attention_score, party_skill_knowledge_score, party_health_score]
|
encounter_condition_score = applying_conditions * 5 - encounter_conditions * 3;
|
||||||
var encounter_variables = [encounter_hp_score, encounter_cr_score, encounter_ac_score, encounter_dmg_score, encounter_dmgtype_score, encounter_onehit_score, encounter_multiattack_score, encounter_strategy_score, encounter_lair_action_score, encounter_legendairy_action_score, encounter_status_score, encounter_healing_score, encounter_stunning_score, encounter_condition_score]
|
|
||||||
|
|
||||||
//Fill the tables
|
//Clamp the score
|
||||||
console.log(
|
if (encounter_condition_score > 20) {
|
||||||
"<table><thead><tr><th>Variable</th><th>Pts</th></tr></thead><tbody>"+
|
encounter_condition_score = 20;
|
||||||
$.each(party_variables, function(){
|
} else if (encounter_condition_score < -20) {
|
||||||
"<tr>"+variablesName($(this))+"</tr>"
|
encounter_condition_score = -20;
|
||||||
"<tr>"+$(this).val()+"</tr>"
|
}
|
||||||
})
|
|
||||||
);
|
|
||||||
|
|
||||||
|
encounter_final_score = encounter_hp_score + encounter_cr_score + encounter_ac_score + encounter_dmg_score + encounter_dmgtype_score + encounter_onehit_score + encounter_multiattack_score + encounter_strategy_score + encounter_lair_action_score + encounter_legendairy_action_score + encounter_status_score + encounter_healing_score + encounter_stunning_score + encounter_condition_score;
|
||||||
|
|
||||||
|
//FINAL CALCULATION
|
||||||
|
//Party Points:
|
||||||
|
var final_score = (encounter_final_score * modifier_encounter) - (party_final_score * modifier_party);
|
||||||
|
|
||||||
|
var party_variables = [party_skill_strategies_score, party_skill_attention_score, party_skill_knowledge_score, party_health_score];
|
||||||
|
var encounter_variables = [encounter_hp_score, encounter_cr_score, encounter_ac_score, encounter_dmg_score, encounter_dmgtype_score, encounter_onehit_score, encounter_multiattack_score, encounter_strategy_score, encounter_lair_action_score, encounter_legendairy_action_score, encounter_status_score, encounter_healing_score, encounter_stunning_score, encounter_condition_score];
|
||||||
|
|
||||||
|
|
||||||
|
$.each(party_variables, function() {
|
||||||
|
console.log("<tr>" + variablesName($(this)) + "</tr>" + "<tr>" + $(this).val() + "</tr>");
|
||||||
|
});
|
||||||
|
|
||||||
|
$.each(encounter_variables, function() {
|
||||||
|
console.log("<tr>" + variablesName($(this)) + "</tr>" + "<tr>" + $(this).val() + "</tr>");
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
//Fill the tables
|
||||||
|
console.log(
|
||||||
|
"<table><thead><tr><th>Variable</th><th>Pts</th></tr></thead><tbody>"+"</tbody></table>"
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user