User:Habst/generateMarks.js

window.params = []; window.tids = []; window.coreCss = []; window.coreMarkTitles = []; window.coreMarkLatIfs = []; [...Array(250)].map((_, i) => i + 1).forEach(n => { const numAbbr = num => num <= 0 ? '' : numAbbr(Math.floor((num - 1) / 26)) + String.fromCharCode((num - 1) % 26 + 65);  if (n === 1) params.push(`| mark-lat1 = else params.push(`|    shape${n} =   if (n === 1) tids.push(`| mark-title1 =   Special:Random else tids.push(`| mark-title${n} =
 * mark-lon1 =
 * shape1 =
 * shape-color1 = #
 * shape-outline1 =
 * shape-angle1 =
 * mark1 =
 * mark-size1 =
 * mark-dim1 =
 * label1 =
 * labela1 =
 * labelb1 =
 * label-angle1 =
 * label-size1 =
 * label-color1 = #
 * label-pos1 =
 * ldx1 =
 * ldy1 =
 * jdx1=
 * numbered1 = `);
 * mark-lat${n} =
 * mark-lon${n} =
 * shape-color${n} = #
 * shape-outline${n} =
 * shape-angle${n} =
 * mark${n} =
 * mark-size${n} =
 * mark-dim${n} =
 * label${n} =
 * labela${n} =
 * labelb${n} =
 * label-angle${n} =
 * label-size${n} =
 * label-color${n} = #
 * label-pos${n} =
 * ldx${n} =
 * ldy${n} =
 * jdx${n} =
 * numbered${n} = `);
 * mark-image1 =
 * mark-description1 = `);
 * mark-image${n} =
 * mark-description${n} = `);

if (n === 1) coreCss.unshift(``); else coreCss.unshift(`}}`); if (n === 1) coreMarkTitles.push(``); else coreMarkTitles.push(``);

coreMarkLatIfs.push(``); });

console.log(params.join('\n\n')); console.log(tids.join('\n')); console.log(coreCss.join('\n')); console.log(coreMarkTitles.join('\n\n')); console.log(coreMarkLatIfs.join(''));