diff options
author | Tor Andersson <tor@ccxvii.net> | 2022-11-20 15:14:37 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-02-18 13:02:37 +0100 |
commit | 62c5a54f132ec16a673fabb3e62a29864b63f54e (patch) | |
tree | 952bdf15b450d73e7f8ff70b2ab1bdd30a855126 /tools | |
parent | 24eaf8561801306327b0e92570e95a2aea67f0c6 (diff) | |
download | nevsky-62c5a54f132ec16a673fabb3e62a29864b63f54e.tar.gz |
Drop back side of service markers.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/build_counters3.sh | 8 | ||||
-rw-r--r-- | tools/gendata.js | 36 |
2 files changed, 21 insertions, 23 deletions
diff --git a/tools/build_counters3.sh b/tools/build_counters3.sh index 142d802..a4681f2 100644 --- a/tools/build_counters3.sh +++ b/tools/build_counters3.sh @@ -1,5 +1,5 @@ mkdir -p service300 -montage -mode concatenate -tile 2x counters300/lord_teutonic_andreas.a.png counters300/lord_teutonic_andreas.b.png counters300/lord_teutonic_heinrich.a.png counters300/lord_teutonic_heinrich.b.png counters300/lord_teutonic_hermann.a.png counters300/lord_teutonic_hermann.b.png counters300/lord_teutonic_knud_and_abel.a.png counters300/lord_teutonic_knud_and_abel.b.png counters300/lord_teutonic_rudolf.a.png counters300/lord_teutonic_rudolf.b.png counters300/lord_teutonic_yaroslav.a.png counters300/lord_teutonic_yaroslav.b.png service300/service_lords_teutonic.png -montage -mode concatenate -tile 2x counters300/vassal_teutonic_andreas_lettgallian_auxiliaries.a.png counters300/vassal_teutonic_andreas_lettgallian_auxiliaries.b.png counters300/vassal_teutonic_andreas_summer_crusaders.a.png counters300/vassal_teutonic_andreas_summer_crusaders.b.png counters300/vassal_teutonic_andreas_teutonic_vassals.a.png counters300/vassal_teutonic_andreas_teutonic_vassals.b.png counters300/vassal_teutonic_heinrich_heinrich_von_lode.a.png counters300/vassal_teutonic_heinrich_heinrich_von_lode.b.png counters300/vassal_teutonic_heinrich_odward_von_lode.a.png counters300/vassal_teutonic_heinrich_odward_von_lode.b.png counters300/vassal_teutonic_hermann_helmond_von_luneburg.a.png counters300/vassal_teutonic_hermann_helmond_von_luneburg.b.png counters300/vassal_teutonic_hermann_johannes_von_dolen.a.png counters300/vassal_teutonic_hermann_johannes_von_dolen.b.png counters300/vassal_teutonic_hermann_ugaunian_auxiliaries.a.png counters300/vassal_teutonic_hermann_ugaunian_auxiliaries.b.png counters300/vassal_teutonic_knud_and_abel_dietrich_von_kivel.a.png counters300/vassal_teutonic_knud_and_abel_dietrich_von_kivel.b.png counters300/vassal_teutonic_knud_and_abel_estonian_auxiliaries.a.png counters300/vassal_teutonic_knud_and_abel_estonian_auxiliaries.b.png counters300/vassal_teutonic_knud_and_abel_otto_von_luneburg.a.png counters300/vassal_teutonic_knud_and_abel_otto_von_luneburg.b.png counters300/vassal_teutonic_rudolf_ex_sword_brethren.a.png counters300/vassal_teutonic_rudolf_ex_sword_brethren.b.png counters300/vassal_teutonic_rudolf_jerwen_teutonic_vassals.a.png counters300/vassal_teutonic_rudolf_jerwen_teutonic_vassals.b.png counters300/vassal_teutonic_rudolf_summer_crusaders.a.png counters300/vassal_teutonic_rudolf_summer_crusaders.b.png counters300/vassal_teutonic_yaroslav_mstislavich_partisans.a.png counters300/vassal_teutonic_yaroslav_mstislavich_partisans.b.png service300/service_vassals_teutonic.png -montage -mode concatenate -tile 2x counters300/lord_russian_aleksandr.a.png counters300/lord_russian_aleksandr.b.png counters300/lord_russian_andrey.a.png counters300/lord_russian_andrey.b.png counters300/lord_russian_domash.a.png counters300/lord_russian_domash.b.png counters300/lord_russian_gavrilo.a.png counters300/lord_russian_gavrilo.b.png counters300/lord_russian_karelians.a.png counters300/lord_russian_karelians.b.png counters300/lord_russian_vladislav.a.png counters300/lord_russian_vladislav.b.png service300/service_lords_russian.png -montage -mode concatenate -tile 2x counters300/vassal_russian_aleksandr_mongols.a.png counters300/vassal_russian_aleksandr_mongols.b.png counters300/vassal_russian_aleksandr_pereyaslavl.a.png counters300/vassal_russian_aleksandr_pereyaslavl.b.png counters300/vassal_russian_aleksandr_rostov.a.png counters300/vassal_russian_aleksandr_rostov.b.png counters300/vassal_russian_aleksandr_yaroslavl.a.png counters300/vassal_russian_aleksandr_yaroslavl.b.png counters300/vassal_russian_andrey_kipchaqs.a.png counters300/vassal_russian_andrey_kipchaqs.b.png counters300/vassal_russian_andrey_suzdal.a.png counters300/vassal_russian_andrey_suzdal.b.png counters300/vassal_russian_andrey_vladimir.a.png counters300/vassal_russian_andrey_vladimir.b.png counters300/vassal_russian_domash_novgorod.a.png counters300/vassal_russian_domash_novgorod.b.png counters300/vassal_russian_gavrilo_borderland_russians.a.png counters300/vassal_russian_gavrilo_borderland_russians.b.png counters300/vassal_russian_gavrilo_pskov_militia.a.png counters300/vassal_russian_gavrilo_pskov_militia.b.png counters300/vassal_russian_gavrilo_pskov.a.png counters300/vassal_russian_gavrilo_pskov.b.png counters300/vassal_russian_vladislav_izhoran_auxiliaries.a.png counters300/vassal_russian_vladislav_izhoran_auxiliaries.b.png counters300/vassal_russian_vladislav_ingrian_auxiliaries.a.png counters300/vassal_russian_vladislav_ingrian_auxiliaries.b.png counters300/vassal_russian_vladislav_vepsian_auxiliaries.a.png counters300/vassal_russian_vladislav_vepsian_auxiliaries.b.png counters300/vassal_russian_vladislav_vodian_auxiliaries.a.png counters300/vassal_russian_vladislav_vodian_auxiliaries.b.png service300/service_vassals_russian.png +montage -mode concatenate -tile 1x counters300/lord_teutonic_andreas.a.png counters300/lord_teutonic_heinrich.a.png counters300/lord_teutonic_hermann.a.png counters300/lord_teutonic_knud_and_abel.a.png counters300/lord_teutonic_rudolf.a.png counters300/lord_teutonic_yaroslav.a.png service300/service_lords_teutonic.png +montage -mode concatenate -tile 1x counters300/lord_russian_aleksandr.a.png counters300/lord_russian_andrey.a.png counters300/lord_russian_domash.a.png counters300/lord_russian_gavrilo.a.png counters300/lord_russian_karelians.a.png counters300/lord_russian_vladislav.a.png service300/service_lords_russian.png +montage -mode concatenate -tile 3x counters300/vassal_teutonic_andreas_lettgallian_auxiliaries.a.png counters300/vassal_teutonic_andreas_summer_crusaders.a.png counters300/vassal_teutonic_andreas_teutonic_vassals.a.png counters300/vassal_teutonic_heinrich_heinrich_von_lode.a.png counters300/vassal_teutonic_heinrich_odward_von_lode.a.png counters300/vassal_teutonic_hermann_helmond_von_luneburg.a.png counters300/vassal_teutonic_hermann_johannes_von_dolen.a.png counters300/vassal_teutonic_hermann_ugaunian_auxiliaries.a.png counters300/vassal_teutonic_knud_and_abel_dietrich_von_kivel.a.png counters300/vassal_teutonic_knud_and_abel_estonian_auxiliaries.a.png counters300/vassal_teutonic_knud_and_abel_otto_von_luneburg.a.png counters300/vassal_teutonic_rudolf_ex_sword_brethren.a.png counters300/vassal_teutonic_rudolf_jerwen_teutonic_vassals.a.png counters300/vassal_teutonic_rudolf_summer_crusaders.a.png counters300/vassal_teutonic_yaroslav_mstislavich_partisans.a.png service300/service_vassals_teutonic.png +montage -mode concatenate -tile 3x counters300/vassal_russian_aleksandr_mongols.a.png counters300/vassal_russian_aleksandr_pereyaslavl.a.png counters300/vassal_russian_aleksandr_rostov.a.png counters300/vassal_russian_aleksandr_yaroslavl.a.png counters300/vassal_russian_andrey_kipchaqs.a.png counters300/vassal_russian_andrey_suzdal.a.png counters300/vassal_russian_andrey_vladimir.a.png counters300/vassal_russian_domash_novgorod.a.png counters300/vassal_russian_gavrilo_borderland_russians.a.png counters300/vassal_russian_gavrilo_pskov_militia.a.png counters300/vassal_russian_gavrilo_pskov.a.png counters300/vassal_russian_vladislav_izhoran_auxiliaries.a.png counters300/vassal_russian_vladislav_ingrian_auxiliaries.a.png counters300/vassal_russian_vladislav_vepsian_auxiliaries.a.png counters300/vassal_russian_vladislav_vodian_auxiliaries.a.png service300/service_vassals_russian.png diff --git a/tools/gendata.js b/tools/gendata.js index 43ee50d..ef29c5d 100644 --- a/tools/gendata.js +++ b/tools/gendata.js @@ -769,51 +769,49 @@ function to_path(name) { let lord_service = {Russian:[],Teutonic:[]} let vassal_service = {Russian:[],Teutonic:[]} -let last_path, last_side, last_ix +let last_path, last_side -last_path = null +last_path = [] last_side = null lords.forEach((lord,id) => { let side = lord.side let path = "counters300/lord_" + side.toLowerCase() + "_" + to_path(lord.name) if (side !== last_side) { - last_ix = 0 last_side = side + last_path = [] } - lord.image = last_ix - if (path !== last_path) { - last_ix++ - last_path = path + if (!last_path.includes(path)) { + last_path.push(path) lord_service[side].push(path + ".a.png") - lord_service[side].push(path + ".b.png") + // lord_service[side].push(path + ".b.png") } + lord.image = last_path.indexOf(path) }) -last_path = null +last_path = [] last_side = null vassals.forEach((vassal,id) => { let lord = lords[vassal.lord] let side = lord.side let path = "counters300/vassal_" + side.toLowerCase() + "_" + to_path(lord.name) + "_" + to_path(vassal.name) if (side !== last_side) { - last_ix = 0 last_side = side + last_path = [] } - vassal.image = last_ix - if (path !== last_path) { - last_ix++ - last_path = path + if (!last_path.includes(path)) { + last_path.push(path) vassal_service[side].push(path + ".a.png") - vassal_service[side].push(path + ".b.png") + // vassal_service[side].push(path + ".b.png") } + vassal.image = last_path.indexOf(path) }) let script = [] script.push("mkdir -p service300") -script.push("montage -mode concatenate -tile 2x " + lord_service.Teutonic.join(" ") + " service300/service_lords_teutonic.png") -script.push("montage -mode concatenate -tile 2x " + vassal_service.Teutonic.join(" ") + " service300/service_vassals_teutonic.png") -script.push("montage -mode concatenate -tile 2x " + lord_service.Russian.join(" ") + " service300/service_lords_russian.png") -script.push("montage -mode concatenate -tile 2x " + vassal_service.Russian.join(" ") + " service300/service_vassals_russian.png") +script.push("montage -mode concatenate -tile 1x " + lord_service.Teutonic.join(" ") + " service300/service_lords_teutonic.png") +script.push("montage -mode concatenate -tile 1x " + lord_service.Russian.join(" ") + " service300/service_lords_russian.png") +script.push("montage -mode concatenate -tile 3x " + vassal_service.Teutonic.join(" ") + " service300/service_vassals_teutonic.png") +script.push("montage -mode concatenate -tile 3x " + vassal_service.Russian.join(" ") + " service300/service_vassals_russian.png") print("const data = {") print("seaports:" + JSON.stringify(seaports) + ",") |