Difference between revisions of "Widget:RuneDisp"

From Official Runecraft Wiki
Line 41: Line 41:
 
const option = document.createElement('option');
 
const option = document.createElement('option');
 
option.value = rne;
 
option.value = rne;
if (layer == activationlayer) {
+
if (runefiles.indexOf(rne)+1 == activationlayer) {
 
option.textContent = 'Activation Layer';
 
option.textContent = 'Activation Layer';
 
} else {
 
} else {
option.textContent = 'Layer '+runefiles.indexOf(rne);
+
option.textContent = 'Layer '+runefiles.indexOf(rne)+1;
 
}
 
}
 
select.appendChild(option);
 
select.appendChild(option);

Revision as of 17:44, 14 January 2022