From b4abccdd44859c5c1c0a24a5e36be4c94c2bc51c Mon Sep 17 00:00:00 2001
From: Peter van der Meer <peter.vd.meer@gmail.com>
Date: Mon, 8 Jan 2024 20:48:10 +0100
Subject: [PATCH 22/22] Add highways to trident and hex2t tilesets

The highways are added at a 3 to 4 pixels offset to railroads,
this allows both to be visible on the same tile, while still
allowing them to connect as well. (Depending on if the ruleset
wants those roads to connect or be separate.)

See RM #255
---
 data/hex2t.tilespec        |   2 ++
 data/hex2t/Makefile.am     |   2 ++
 data/hex2t/highways.png    | Bin 0 -> 5262 bytes
 data/hex2t/highways.spec   |  38 ++++++++++++++++++++
 data/trident.tilespec      |   2 ++
 data/trident/Makefile.am   |   2 ++
 data/trident/highways.png  | Bin 0 -> 5372 bytes
 data/trident/highways.spec |  69 +++++++++++++++++++++++++++++++++++++
 meson.build                |   4 +++
 9 files changed, 119 insertions(+)
 create mode 100644 data/hex2t/highways.png
 create mode 100644 data/hex2t/highways.spec
 create mode 100644 data/trident/highways.png
 create mode 100644 data/trident/highways.spec

diff --git a/data/hex2t.tilespec b/data/hex2t.tilespec
index 73de5e44a2..0f79cd6952 100644
--- a/data/hex2t.tilespec
+++ b/data/hex2t.tilespec
@@ -161,6 +161,7 @@ files =
   "misc/flags.spec",
   "misc/shields.spec",
   "misc/cursors.spec",
+  "hex2t/highways.spec",
   "misc/space.spec",
   "misc/techs.spec",
   "misc/treaty.spec",
@@ -282,6 +283,7 @@ styles =
     { "name",          "style"
       "road.road",     "RoadAllSeparate"
       "road.rail",     "RoadAllSeparate"
+      "road.highway",  "RoadAllSeparate"
       "road.maglev",   "RoadAllSeparate"
       "road.river",    "River"
       "tx.irrigation", "Cardinals"
diff --git a/data/hex2t/Makefile.am b/data/hex2t/Makefile.am
index f089b1361b..4123a0ddfc 100644
--- a/data/hex2t/Makefile.am
+++ b/data/hex2t/Makefile.am
@@ -6,6 +6,8 @@ pkgdatadir = $(datadir)/$(PACKAGE)/hex2t
 pkgdata_DATA =          \
 	grid.png	\
 	grid.spec	\
+	highways.png	\
+	highways.spec	\
 	items.png	\
 	items.spec	\
 	overlays.png	\
diff --git a/data/hex2t/highways.png b/data/hex2t/highways.png
new file mode 100644
index 0000000000000000000000000000000000000000..aeafc4c672f59125596d4db66b349b18f92b8f7b
GIT binary patch
diff --git a/data/hex2t/highways.spec b/data/hex2t/highways.spec
new file mode 100644
index 0000000000..1ec2b100c8
--- /dev/null
+++ b/data/hex2t/highways.spec
@@ -0,0 +1,38 @@
+
+[spec]
+
+; Format and options of this spec file:
+options = "+Freeciv-spec-3.2-Devel-2023.Jan.01"
+
+[info]
+
+artists = "
+    Peter van der Meer (highways)
+"
+
+[file]
+gfx = "hex2t/highways"
+
+[grid_main]
+
+x_top_left = 1
+y_top_left = 1
+dx = 40
+dy = 72
+pixel_border = 1
+
+tiles = { "row", "column","tag"
+
+; Roads, Highways
+
+ 0, 0, "road.highway_n"
+ 0, 1, "road.highway_ne"
+ 0, 2, "road.highway_e"
+ 0, 7, "road.highway_se"
+ 0, 3, "road.highway_s"
+ 0, 4, "road.highway_sw"
+ 0, 5, "road.highway_w"
+ 0, 6, "road.highway_nw"
+
+ 0, 8, "road.highway_isolated"
+}
diff --git a/data/trident.tilespec b/data/trident.tilespec
index 6cd9f09563..55eea8b7dd 100644
--- a/data/trident.tilespec
+++ b/data/trident.tilespec
@@ -159,6 +159,7 @@ files =
   "misc/cursors.spec",
   "trident/grid.spec",
   "trident/roads.spec",
+  "trident/highways.spec",
   "misc/buildings.spec",
   "misc/space.spec",
   "misc/techs.spec",
@@ -335,6 +336,7 @@ styles =
     { "name",          "style"
       "road.road",     "RoadParityCombined"
       "road.rail",     "RoadParityCombined"
+      "road.highway",  "RoadParityCombined"
       "road.maglev",   "RoadParityCombined"
       "road.river",    "River"
       "tx.irrigation", "Cardinals"
diff --git a/data/trident/Makefile.am b/data/trident/Makefile.am
index b729a61d2d..9253c7c112 100644
--- a/data/trident/Makefile.am
+++ b/data/trident/Makefile.am
@@ -17,6 +17,8 @@ pkgdata_DATA =          \
 	fog.spec	\
 	grid.png	\
 	grid.spec	\
+	highways.png	\
+	highways.spec	\
 	roads.png	\
 	roads.spec	\
 	select.png	\
diff --git a/data/trident/highways.png b/data/trident/highways.png
new file mode 100644
index 0000000000000000000000000000000000000000..6796fa370250f260512c2474c120173f9dfaaf3e
GIT binary patch
diff --git a/data/trident/highways.spec b/data/trident/highways.spec
new file mode 100644
index 0000000000..4a1bd24402
--- /dev/null
+++ b/data/trident/highways.spec
@@ -0,0 +1,69 @@
+
+[spec]
+
+; Format and options of this spec file:
+options = "+Freeciv-spec-3.2-Devel-2023.Jan.01"
+
+[info]
+
+artists = "
+    Peter van der Meer (highways)
+"
+
+[file]
+gfx = "trident/highways"
+
+[grid_highways]
+
+x_top_left = 0
+y_top_left = 0
+dx = 30
+dy = 30
+
+tiles = { "row", "column", "tag"
+
+  0,  0, "road.highway_isolated"
+
+; Cardinal highways, connections north, south, east, west:
+
+  0,  1, "road.highway_c_n1e0s0w0"
+  0,  2, "road.highway_c_n0e1s0w0"
+  0,  3, "road.highway_c_n1e1s0w0"
+  0,  4, "road.highway_c_n0e0s1w0"
+  0,  5, "road.highway_c_n1e0s1w0"
+  0,  6, "road.highway_c_n0e1s1w0"
+  0,  7, "road.highway_c_n1e1s1w0"
+  0,  8, "road.highway_c_n0e0s0w1"
+  0,  9, "road.highway_c_n1e0s0w1"
+  0, 10, "road.highway_c_n0e1s0w1"
+  0, 11, "road.highway_c_n1e1s0w1"
+  0, 12, "road.highway_c_n0e0s1w1"
+  0, 13, "road.highway_c_n1e0s1w1"
+  0, 14, "road.highway_c_n0e1s1w1"
+  0, 15, "road.highway_c_n1e1s1w1"
+
+; Diagonal highways, connections same, rotated 45 degrees clockwise:
+
+  1,  1, "road.highway_d_ne1se0sw0nw0"
+  1,  2, "road.highway_d_ne0se1sw0nw0"
+  1,  3, "road.highway_d_ne1se1sw0nw0"
+  1,  4, "road.highway_d_ne0se0sw1nw0"
+  1,  5, "road.highway_d_ne1se0sw1nw0"
+  1,  6, "road.highway_d_ne0se1sw1nw0"
+  1,  7, "road.highway_d_ne1se1sw1nw0"
+  1,  8, "road.highway_d_ne0se0sw0nw1"
+  1,  9, "road.highway_d_ne1se0sw0nw1"
+  1, 10, "road.highway_d_ne0se1sw0nw1"
+  1, 11, "road.highway_d_ne1se1sw0nw1"
+  1, 12, "road.highway_d_ne0se0sw1nw1"
+  1, 13, "road.highway_d_ne1se0sw1nw1"
+  1, 14, "road.highway_d_ne0se1sw1nw1"
+  1, 15, "road.highway_d_ne1se1sw1nw1"
+
+; highway corners
+
+  0, 16, "road.highway_c_nw"
+  0, 17, "road.highway_c_ne"
+  1, 16, "road.highway_c_sw"
+  1, 17, "road.highway_c_se"
+}
diff --git a/meson.build b/meson.build
index c10787a293..4572981771 100644
--- a/meson.build
+++ b/meson.build
@@ -2923,6 +2923,8 @@ install_data('data/hexemplio/activities.png',
 
 install_data('data/hex2t/grid.png',
              'data/hex2t/grid.spec',
+             'data/hex2t/highways.png',
+             'data/hex2t/highways.spec',
              'data/hex2t/items.png',
              'data/hex2t/items.spec',
              'data/hex2t/overlays.png',
@@ -2960,6 +2962,8 @@ install_data('data/trident/cities.png',
              'data/trident/auto_ll.spec',
              'data/trident/grid.png',
              'data/trident/grid.spec',
+             'data/trident/highways.png',
+             'data/trident/highways.spec',
              'data/trident/roads.png',
              'data/trident/roads.spec',
              'data/trident/select.png',
-- 
2.43.0

