Herdias Test Page¶
<base target="_parent"> <!-- make links open on the parent wiki page instead of inside the iframe -->
<!-- preload calculator menubar button icons -->
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/swords.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/shield.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/tree.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/five-column.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/three-column.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/five-row.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/three-row.png" as="image">
<link rel="preload" href="/assets/wikidot/rank-bonus-calculator/one-row.png" as="image">
<style>
/* outer styles
--------------- */
body {
font-family: verdana, arial, helvetica, sans-serif;
font-size: 12px;
color: #322E1E;
}
/* width-control wrapper for RB calculator */
div.rb-outer {
max-width: 800px;
/* it just kind of looks bad if it's bigger than this. Not really a functional restriction. */
}
/* add rounded corners to RB container - adjusts dynamically as new calculators are added */
div.rb-container>div:first-child {
border-top-left-radius: 14px;
border-top-right-radius: 14px;
}
div.rb-container>div:last-child {
border-bottom-left-radius: 14px;
border-bottom-right-radius: 14px;
}
/* menubar & menu button styles
------------------------------- */
div.rb-calc-menu {
height: 36px;
background-color: #E2DBBAD0;
border: 1px solid rgb(110, 110, 94);
border-bottom: 0px;
display: flex;
flex-flow: row nowrap;
}
div#rb-menu-title {
font-size: 16px;
flex-grow: 10;
padding: 0.5em;
}
div.rb-button {
flex-grow: 0.01;
height: 26px;
margin: 5px 4px 4px 4px;
width: 26px;
max-width: 26px;
min-width: 26px;
background-repeat: no-repeat;
background-size: 22px 22px;
background-position: center center;
border-radius: 6px;
box-shadow: 0px 0px 1px 1px rgb(66, 66, 56);
transition-duration: 0.25s;
}
div.rb-button:hover {
background-color: #dcc475;
cursor: pointer;
}
div.rb-button:last-child {
margin-right: 8px;
/* adjust button so it's not too far against the right edge of the menubar */
}
div.rb-button.disabled {
opacity: 0.35;
}
div.rb-button.disabled:hover {
background-color: unset;
}
/* button icons */
div.sword-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/swords.png");
}
div.shield-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/shield.png");
}
div.tree-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/tree.png");
}
div.three-col-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/three-column.png");
}
div.five-col-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/five-column.png");
}
div.five-row-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/five-row.png");
}
div.three-row-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/three-row.png");
}
div.one-row-icon {
background-image: url("/assets/wikidot/rank-bonus-calculator/one-row.png");
}
div.dec-none:before {
content: ".0";
font-size: 15px;
font-weight: bold;
color: rgb(121, 121, 106);
display: block;
position: relative;
top: 3px;
left: 4px;
}
div.dec-none:after {
content: "\2573";
position: relative;
color: rgb(47, 47, 36);
font-weight: bold;
display: block;
top: -15px;
left: 7px;
font-size: 12px;
}
div.dec-one:after {
content: ".0";
font-size: 15px;
font-weight: bold;
color: rgb(47, 47, 36);
display: block;
position: relative;
top: 3px;
left: 4px;
}
div.dec-two:after {
content: ".00";
font-size: 12px;
font-weight: bold;
color: rgb(47, 47, 36);
display: block;
position: relative;
top: 5px;
left: 2px;
}
div.dec-three:after {
content: ".000";
font-size: 9px;
font-weight: bold;
color: rgb(47, 47, 36);
display: block;
position: relative;
top: 7px;
left: 2px;
}
div.dec-infin:after {
content: ".000\A 000\A 000";
white-space: pre-wrap;
line-height: 1;
font-size: 8px;
font-weight: bold;
color: rgb(47, 47, 36);
display: block;
position: relative;
top: 1px;
left: 2px;
}
/* rank inputs and RB outputs container
--------------------------------------- */
div.rb-calc-box {
/* old: background-color: rgb(97, 97, 84);*/
background-color: #E2DBBAD0;
border: 1px solid rgb(110, 110, 94);
border-top: 0px;
padding: 10px 20px 20px 20px;
display: flex;
flex-flow: row wrap;
}
/* "Basics" & "Subskill" rank inputs table
------------------------------------------ */
div.rb-rank-inputs-box {
flex-grow: 1;
}
table.rb-rank-inputs {
width: 100%;
height: 100%;
}
table.rb-rank-inputs tr td {
padding: 5px;
text-align: center;
}
table.rb-rank-inputs input {
padding: 6px 6px 6px 16px;
font-size: 16px;
width: 7.9em;
border-radius: 4px;
border: 1px solid #333;
}
table.rb-rank-inputs input:focus {
outline: 2px solid #333;
}
/* rank bonus calculated outputs table
-------------------------------------- */
div.rb-rank-bonuses-box {
flex-grow: 2.5;
}
table.rb-rank-bonuses {
width: 100%;
height: 100%;
border-collapse: separate;
border-spacing: 1px;
font-size: 14px;
color: #322E1E;
}
@media only screen and (max-width: 600px) {
table.rb-rank-bonuses {
font-size: 10px;
}
}
table.rb-rank-bonuses tr td {
padding: 3px 0.2em 2px 0.2em;
}
table.rb-rank-bonuses tr.rb-table-headers td {
padding-top: 0;
}
table.rb-rank-bonuses input {
width: 75%;
padding: 2px 9%;
border-radius: 4px;
border: 0px;
background-color: rgb(255, 255, 255);
height: 100%;
min-height: 1.65em;
max-height: 2em;
}
table.rb-rank-bonuses input:focus {
outline: none;
}
table.rb-rank-bonuses tr td.offensive-stance, table.rb-rank-bonuses tr td.defensive-stance {
text-align: right;
padding-right: 0.7em;
width: 1px;
padding-top: 0.5em;
}
table.rb-rank-bonuses tr td.defensive-stance {
display: none;
/* table starts with offensive stance labels; hide defensive ones until switching to defensive mode */
}
/* Plus button to create new calculator instance
------------------------------------------------ */
div.rb-plus-new {
margin: 20px 30%;
background: url("/assets/wikidot/rank-bonus-calculator/plus.png") no-repeat;
background-size: 40px;
background-position: 50% 5px;
height: 50px;
border-radius: 25px;
border: 1px solid rgba(0, 0, 0, 0);
transition-duration: 0.45s;
}
div.rb-plus-new:hover {
background-color: #dcc475;
border: 1px solid rgb(110, 110, 94);
cursor: pointer;
}
/* Styles for page content after calculator
------------------------------------------- */
h3 {
border: 2px solid #314200;
background: #315203;
border-radius: 6px;
color: #FFFFFF;
padding-left: 6px;
font-weight: normal;
font-size: 140%;
margin-bottom: 8px;
margin-top: 24px;
}
p {
padding-left: 18px;
}
table.info-table th, table.info-table td {
text-align: left;
padding: 2px 18px;
background-color: #E2DBBAD0;
color: #000000;
}
table.info-table th {
font-size: 115%;
padding-top: 5px;
padding-bottom: 5px;
}
<script src="/assets/wikidot/rank-bonus-calculator/decimal.min.js"></script>
<script type="text/javascript">
//process menubar button clicks and adjust calculator accordingly
//---------------------------------------------------------------
function toggleButton(elem, isFirstLoad) {
if (isFirstLoad) {
var rbTypeButton = getCookie("rbTypeButton") || "sword";
var rbRowButton = getCookie("rbRowButton") || "five";
var rbColButton = getCookie("rbColButton") || "five";
}
var offCells = elem.parentElement.parentElement.getElementsByClassName("offensive-stance"); //table column headers (Bers, Aggr, Norm, Wary, Def)
var defCells = elem.parentElement.parentElement.getElementsByClassName("defensive-stance"); //alt table column headers (Def, Wary, Norm, Aggr, Bers)
var basCells = elem.parentElement.parentElement.getElementsByClassName("basic-rb-values"); //basics column
var impCells = elem.parentElement.parentElement.getElementsByClassName("impos-rb-values"); //impossible column
var berRows = elem.parentElement.parentElement.getElementsByClassName("berserk-row") //berserk row only
var modRows = elem.parentElement.parentElement.getElementsByClassName("stance-rb-mod-row"); //all non-berserk rows
var berDefRows = elem.parentElement.parentElement.getElementsByClassName("ber-def-row"); //berserk & defensive rows
var aggWarRows = elem.parentElement.parentElement.getElementsByClassName("agg-war-row"); //aggressive & wary rows
var rowButton = document.getElementById("rb-row-button");
if (elem.classList.contains("disabled")) {
return;
} else if ((isFirstLoad && (elem.id === "rb-main-button") && (rbTypeButton === "shield")) || (!isFirstLoad && elem.classList.contains("sword-icon"))) {
elem.classList.remove("sword-icon");
elem.classList.remove("tree-icon");
elem.classList.add("shield-icon");
hideElems(offCells);
showElems(defCells);
document.getElementById("rb-menu-title").innerHTML = "Defensive Rank Bonus";
setCookie("rbTypeButton", "shield", 999);
} else if ((isFirstLoad && (elem.id === "rb-main-button") && (rbTypeButton === "tree")) || (!isFirstLoad && elem.classList.contains("shield-icon"))) {
elem.classList.remove("sword-icon");
elem.classList.remove("shield-icon");
elem.classList.add("tree-icon");
hideElems(offCells);
hideElems(defCells);
hideElems(modRows);
showElems(berRows);
rowButton.classList.add("disabled");
document.getElementById("rb-menu-title").innerHTML = "Non-Combat Rank Bonus";
setCookie("rbTypeButton", "tree", 999);
} else if ((isFirstLoad && (elem.id === "rb-main-button") && (rbTypeButton === "sword")) || (!isFirstLoad && elem.classList.contains("tree-icon"))) {
elem.classList.remove("shield-icon");
elem.classList.remove("tree-icon");
elem.classList.add("sword-icon");
hideElems(defCells);
showElems(offCells);
showElems(modRows);
rowButton.classList.remove("disabled");
if (rowButton.classList.contains("three-row-icon")) {
hideElems(berDefRows);
} else if (rowButton.classList.contains("one-row-icon")) {
hideElems(berDefRows);
hideElems(aggWarRows);
}
document.getElementById("rb-menu-title").innerHTML = "Offensive Rank Bonus";
setCookie("rbTypeButton", "sword", 999);
} else if ((isFirstLoad && (elem.id === "rb-col-button") && (rbColButton === "three")) || (!isFirstLoad && elem.classList.contains("five-col-icon"))) {
elem.classList.remove("five-col-icon");
elem.classList.add("three-col-icon");
hideElems(basCells);
hideElems(impCells);
setCookie("rbColButton", "three", 999);
} else if ((isFirstLoad && (elem.id === "rb-col-button") && (rbColButton === "five")) || (!isFirstLoad && elem.classList.contains("three-col-icon"))) {
elem.classList.remove("three-col-icon");
elem.classList.add("five-col-icon");
showElems(basCells);
showElems(impCells);
setCookie("rbColButton", "five", 999);
} else if ((isFirstLoad && (elem.id === "rb-row-button") && (rbRowButton === "three")) || (!isFirstLoad && elem.classList.contains("five-row-icon"))) {
elem.classList.remove("five-row-icon");
elem.classList.remove("one-row-icon");
elem.classList.add("three-row-icon");
hideElems(berDefRows);
setCookie("rbRowButton", "three", 999);
} else if ((isFirstLoad && (elem.id === "rb-row-button") && (rbRowButton === "one")) || (!isFirstLoad && elem.classList.contains("three-row-icon"))) {
elem.classList.remove("three-row-icon");
elem.classList.remove("five-row-icon");
elem.classList.add("one-row-icon");
hideElems(aggWarRows);
setCookie("rbRowButton", "one", 999);
} else if ((isFirstLoad && (elem.id === "rb-row-button") && (rbRowButton === "five")) || (!isFirstLoad && elem.classList.contains("one-row-icon"))) {
elem.classList.remove("one-row-icon");
elem.classList.remove("three-row-icon");
elem.classList.add("five-row-icon");
showElems(berDefRows);
showElems(aggWarRows);
setCookie("rbRowButton", "five", 999);
}
}
function hideElems(elems) {
for (var i = 0; i < elems.length; i++) {
elems[i].style.display = "none";
}
}
function showElems(elems) {
for (var i = 0; i < elems.length; i++) {
if (elems[i].tagName.toLowerCase() == "td") {
elems[i].style.display = "table-cell";
} else if (elems[i].tagName.toLowerCase() == "tr") {
elems[i].style.display = "table-row";
}
}
}
function toggleDecimals(elem, isFirstLoad) {
if (isFirstLoad) {
var rbDecButton = getCookie("rbDecButton") || "infin";
elem.classList.remove("dec-infin"); //remove initial default value
}
if ((isFirstLoad && (rbDecButton === "one")) || (!isFirstLoad && elem.classList.contains("dec-none"))) {
elem.classList.remove("dec-none");
elem.classList.add("dec-one");
setCookie("rbDecButton", "one", 999);
} else if ((isFirstLoad && (rbDecButton === "two")) || (!isFirstLoad && elem.classList.contains("dec-one"))) {
elem.classList.remove("dec-one");
elem.classList.add("dec-two");
setCookie("rbDecButton", "two", 999);
} else if ((isFirstLoad && (rbDecButton === "three")) || (!isFirstLoad && elem.classList.contains("dec-two"))) {
elem.classList.remove("dec-two");
elem.classList.add("dec-three");
setCookie("rbDecButton", "three", 999);
} else if ((isFirstLoad && (rbDecButton === "infin")) || (!isFirstLoad && elem.classList.contains("dec-three"))) {
elem.classList.remove("dec-three");
elem.classList.add("dec-infin");
setCookie("rbDecButton", "infin", 999);
} else if ((isFirstLoad && (rbDecButton === "none")) || (!isFirstLoad && elem.classList.contains("dec-infin"))) {
elem.classList.remove("dec-infin");
elem.classList.add("dec-none");
setCookie("rbDecButton", "none", 999);
}
if (!isFirstLoad) {
refreshRankBonuses();
}
}
//add a new RB calculator instance to the page
//--------------------------------------------
function addRbContainer() {
var containers = document.getElementsByClassName("rb-calc-box");
var newContainer = containers[containers.length - 1].cloneNode(true);
containers[0].parentNode.insertBefore(newContainer, null);
var basicsRanks = document.getElementsByName('basicsRank');
var subSkillRanks = document.getElementsByName('subSkillRank');
basicsRanks[basicsRanks.length - 1].value = "";
subSkillRanks[subSkillRanks.length - 1].value = "";
refreshRankBonuses();
}
//perform the actual rank bonus calculations
//------------------------------------------
var rankTierModifiers = new Array();
rankTierModifiers[0] = 0;
rankTierModifiers[1] = 3;
rankTierModifiers[2] = 2;
rankTierModifiers[3] = 1;
rankTierModifiers[4] = 0.5;
rankTierModifiers[5] = 0.25;
rankTierModifiers[6] = 0.125;
rankTierModifiers[7] = 0.0675;
rankTierModifiers[8] = 0.025;
rankTierModifiers[9] = 0.01;
var rankTierModifierEndLevels = new Array();
rankTierModifierEndLevels[0] = 0;
rankTierModifierEndLevels[1] = 0;
rankTierModifierEndLevels[2] = 10;
rankTierModifierEndLevels[3] = 30;
rankTierModifierEndLevels[4] = 50;
rankTierModifierEndLevels[5] = 100;
rankTierModifierEndLevels[6] = 150;
rankTierModifierEndLevels[7] = 200;
rankTierModifierEndLevels[8] = 500;
rankTierModifierEndLevels[9] = 1000;
function getDifficultyModifier(diff) {
if (diff == "easy") {
return '0.75';
}
if (diff == "average") {
return '0.5';
}
if (diff == "difficult") {
return '0.25';
}
if (diff == "impossible") {
return '0.1';
}
return "ERROR";
}
function getStanceModifier(stance) {
if (stance == "berserk") {
return '1.0';
}
if (stance == "aggressive") {
return '0.75';
}
if (stance == "normal") {
return '0.5';
}
if (stance == "wary") {
return '0.25';
}
if (stance == "defensive") {
return '0';
}
return "ERROR";
}
function calcRankTierBonus(rank) {
var rankTierBonus = new Decimal(0);
for (var i = rankTierModifierEndLevels.length; i > 0; i--) {
if (rank > rankTierModifierEndLevels[i]) {
var ranksInThisTier = new Decimal(rank - rankTierModifierEndLevels[i]);
// rankTierBonus += ranksInThisTier * rankTierModifiers[i];
rankTierBonus = rankTierBonus.plus(ranksInThisTier.times(rankTierModifiers[i]));
rank = rank - ranksInThisTier.toNumber(); // remove the ranks we already evaluated before moving on to other tiers
}
}
return rankTierBonus.toString();
}
function calcBasicsRankBonus(basicsRank, difficulty, stance, decPlaces) {
if (basicsRank == "" || basicsRank < 1) {
return "";
}
return calcRankBonus(0, basicsRank, difficulty, stance, decPlaces);
}
function calcRankBonus(basicsRank, subSkillRank, difficulty, stance, decPlaces) {
if (subSkillRank == "") {
return "";
}
var basicRB = new Decimal(calcRankTierBonus(basicsRank));
var basicDiffMod = new Decimal(getDifficultyModifier(difficulty));
var subSkillRB = new Decimal(calcRankTierBonus(subSkillRank));
var stanceMod = new Decimal(getStanceModifier(stance));
// basicRB.floor().times(basicDiffMod);
var calculatedRB = basicRB.floor().times(basicDiffMod).plus(subSkillRB).times(stanceMod);
// calculatedRB.plus(subSkillRB).times(stanceMod);
return truncateDecimalPlaces(calculatedRB.toString(), decPlaces);
// return truncateDecimalPlaces((Math.floor(calcRankTierBonus(basicsRank)) * getDifficultyModifier(difficulty) + calcRankTierBonus(subSkillRank)) * getStanceModifier(stance), decPlaces);
}
function getNumDecimalPlaces() {
var decButton = document.getElementById('rb-dec-button');
if (decButton.classList.contains('dec-none')) {
return 0;
} else if (decButton.classList.contains('dec-one')) {
return 1;
} else if (decButton.classList.contains('dec-two')) {
return 2;
} else if (decButton.classList.contains('dec-three')) {
return 3;
}
return 8; //eight is the max number of decimal places mathematically possible with RB calculations - but javascript might go above this due to floating point arithmetic resolution limitations. Rounding to 8 places will always safely preserve the true RB.
}
function truncateDecimalPlaces(number, decPlaces) {
var multiplier = new Decimal(10).toPower(decPlaces);
var adjustedNum = new Decimal(number).times(multiplier);
var finalNum = adjustedNum.floor().dividedBy(multiplier);
return finalNum.toString();
}
function refreshRankBonuses() {
var basicsRanks = document.getElementsByName('basicsRank');
var subSkillRanks = document.getElementsByName('subSkillRank');
var rankBonusShifts = document.getElementsByName('rankBonusShift'); New calculator no longer supports an arbitrary modifier
var decPlaces = getNumDecimalPlaces();
var BBs = document.getElementsByName('bb');
var BAs = document.getElementsByName('ba');
var BNs = document.getElementsByName('bn');
var BWs = document.getElementsByName('bw');
var BDs = document.getElementsByName('bd');
var EBs = document.getElementsByName('eb');
var EAs = document.getElementsByName('ea');
var ENs = document.getElementsByName('en');
var EWs = document.getElementsByName('ew');
var EDs = document.getElementsByName('ed');
var ABs = document.getElementsByName('ab');
var AAs = document.getElementsByName('aa');
var ANs = document.getElementsByName('an');
var AWs = document.getElementsByName('aw');
var ADs = document.getElementsByName('ad');
var DBs = document.getElementsByName('db');
var DAs = document.getElementsByName('da');
var DNs = document.getElementsByName('dn');
var DWs = document.getElementsByName('dw');
var DDs = document.getElementsByName('dd');
var IBs = document.getElementsByName('ib');
var IAs = document.getElementsByName('ia');
var INs = document.getElementsByName('in');
var IWs = document.getElementsByName('iw');
var IDs = document.getElementsByName('id');
for (var i = basicsRanks.length - 1; i >= 0; i--) {
BBs[i].value = calcBasicsRankBonus(basicsRanks[i].value, "easy", "berserk", decPlaces);
BAs[i].value = calcBasicsRankBonus(basicsRanks[i].value, "easy", "aggressive", decPlaces);
BNs[i].value = calcBasicsRankBonus(basicsRanks[i].value, "easy", "normal", decPlaces);
BWs[i].value = calcBasicsRankBonus(basicsRanks[i].value, "easy", "wary", decPlaces);
BDs[i].value = calcBasicsRankBonus(basicsRanks[i].value, "easy", "defensive", decPlaces);
EBs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "easy", "berserk", decPlaces);
EAs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "easy", "aggressive", decPlaces);
ENs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "easy", "normal", decPlaces);
EWs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "easy", "wary", decPlaces);
EDs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "easy", "defensive", decPlaces);
ABs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "average", "berserk", decPlaces);
AAs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "average", "aggressive", decPlaces);
ANs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "average", "normal", decPlaces);
AWs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "average", "wary", decPlaces);
ADs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "average", "defensive", decPlaces);
DBs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "difficult", "berserk", decPlaces);
DAs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "difficult", "aggressive", decPlaces);
DNs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "difficult", "normal", decPlaces);
DWs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "difficult", "wary", decPlaces);
DDs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "difficult", "defensive", decPlaces);
IBs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "impossible", "berserk", decPlaces);
IAs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "impossible", "aggressive", decPlaces);
INs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "impossible", "normal", decPlaces);
IWs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "impossible", "wary", decPlaces);
IDs[i].value = calcRankBonus(basicsRanks[i].value, subSkillRanks[i].value, "impossible", "defensive", decPlaces);
}
}
/ ADD COOKIE FUNCTIONS; USED TO PRESERVE USER PREFERENCES WITH THE TOGGLE BUTTONS /
function setCookie(cname, cvalue, exdays) {
var d = new Date();
d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));
var expires = "expires=" + d.toUTCString();
document.cookie = cname + "=" + cvalue + ";" + expires + ";path=/";
}
function getCookie(cname) {
var name = cname + "=";
var ca = document.cookie.split(';');
for (var i = 0; i < ca.length; i++) {
var c = ca[i];
while (c.charAt(0) == ' ') {
c = c.substring(1);
}
if (c.indexOf(name) == 0) {
return c.substring(name.length, c.length);
}
}
return "";
}
function calcStartUp() { //loads cookies and sets each button to user preference
toggleButton(document.getElementById('rb-row-button'), true);
toggleButton(document.getElementById('rb-col-button'), true);
toggleButton(document.getElementById('rb-main-button'), true);
toggleDecimals(document.getElementById('rb-dec-button'), true);
}
| Basic | Easy | Avg. | Diff. | Impos. | ||
| Bers. | Def. | |||||
| Aggr. | Wary | |||||
| Norm. | Norm. | |||||
| Wary | Aggr. | |||||
| Def. | Bers. |
Loading...
Rank Bonus gained per Rank learned¶
Rank bonus improves quickly at low skill ranks, but then begins to increase at a reduced rate per rank as you become more skilled.
| Rank | Rank Bonus Added |
|---|---|
| 1-10 | 3 |
| 11-30 | 2 |
| 31-50 | 1 |
| 51-100 | 0.5 |
| 101-150 | 0.25 |
| 151-200 | 0.125 |
| 201-500 | 0.0675 |
| 501-1000 | 0.025 |
| 1001 and Up | 0.01 |
Basic Rank Bonus Contribution toward Sub-Skill Rank Bonus¶
Your sub-skills gain an additional bonus from your knowledge in the skill basics. The bonus is highest for Easy skills, which absorb 75% of your basic skill rank bonus.
Only each full point of basics rank bonus will add a fraction to the subskill rank bonus (i.e. 34.5 in the "Basic" column is no better than 34).
| Subskill Difficulty | Rank Bonus Added |
|---|---|
| Easy | 75% |
| Average | 50% |
| Difficult | 25% |
| Impossible | 10% |
Rank Bonus Modification by Stance¶
Combat skill rank bonuses are affected by your combat stance. Offensive skills get their full rank bonus benefit if you are in a Berserk stance. However, your defensive skills will be effectively useless in a Berserk stance (and vice versa).
Non-combat skills always get 100% of their rank bonus in any stance.
| Stance | Attack Rank Bonus | Defense Rank Bonus |
|---|---|---|
| Berserk | 100% | 0% |
| Aggressive | 75% | 25% |
| Normal | 50% | 50% |
| Wary | 25% | 75% |
| Defensive | 0% | 100% |
Rank Bonus for Multiple Layers of Defense¶
If you have multiple defenses against an attack, you'll see the full benefit of your defensive skill with the highest rank bonus, but additional "layers" of defense will only provide you a fraction of their full rank bonus.
(Note: Only the whole number portion of your rank bonus is used to determine success with a skill. However, the decimal portion is used to determine the highest-RB skill for defensive layering.)
| Defensive Skill | Cumulative Effect |
|---|---|
| Block/dodge with highest rank bonus | 100% of rank bonus applied |
| Block/dodge with 2nd highest rank bonus | 50% of rank bonus applied |
| Block/dodge with 3rd highest rank bonus | 33% of rank bonus applied |
You are allowed at most only 3 layers of defense against any attack (1 weapon block layer, 1 dodge layer, and 1 shield layer). There are some scenarios where two different dodges or two different weapon blocks could potentially apply against an attack. In these scenarios, only the block or dodge with the highest rank bonus is used.
Notes¶
The calculator will allow you to enter a subskill rank higher than your basics rank, which is impossible in-game. This is to facilitate calculating skills which may not assign the basics rank bonus in a standard way.