{"id":1809,"date":"2023-02-06T08:30:35","date_gmt":"2023-02-05T23:00:35","guid":{"rendered":"https:\/\/cosmicheroes.space\/blog\/?p=1809"},"modified":"2023-02-06T08:30:35","modified_gmt":"2023-02-05T23:00:35","slug":"welsh-piper-hex-map-algorithm-python","status":"publish","type":"post","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/2023\/02\/06\/welsh-piper-hex-map-algorithm-python\/","title":{"rendered":"Welsh Piper hex map algorithm &#8211; Python"},"content":{"rendered":"\n<p>In relation to HexDescribe and <a href=\"https:\/\/campaignwiki.org\/text-mapper\">TextMapper<\/a> &#8211; the random or Smale algorithm is the Welsh Piper&#8217;s. <a href=\"https:\/\/welshpiper.com\/hex-based-campaign-design-part-1\/\">https:\/\/welshpiper.com\/hex-based-campaign-design-part-1\/<\/a><\/p>\n\n\n\n<p>There&#8217;s a follow on part linked for stocking hexes.<\/p>\n\n\n\n<p>I translated this to python &#8211; partly as a ChatGPT exercise.<\/p>\n\n\n\n<p><a href=\"https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/smale.py\">https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/smale.py<\/a><\/p>\n\n\n\n<p>Where I did a few tweaks of the Primary and Secondary maps for the gnomeyland style based on the terrains I have put in Mokuy for HexDescribe.<\/p>\n\n\n\n<p>Here&#8217;s the TextMapper map <a href=\"https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/mokuy1.txt\">https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/mokuy1.txt<\/a><\/p>\n\n\n\n<p>and the HexDescribe tables so far &#8211; lengthy project the latter <a href=\"https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/mokuytables.txt\">https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/mokuytables.txt<\/a><\/p>\n\n\n\n<p>I need a ship and ship crew generator, speaking of such things (and\/or ChatGPT).<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In relation to HexDescribe and TextMapper &#8211; the random or Smale algorithm is the Welsh Piper&#8217;s. https:\/\/welshpiper.com\/hex-based-campaign-design-part-1\/ There&#8217;s a follow on part linked for stocking hexes. I translated this to python &#8211; partly as a ChatGPT exercise. https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/blob\/main\/smale.py Where I did a few tweaks of the Primary and Secondary maps for the gnomeyland style based &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/cosmicheroes.space\/blog\/index.php\/2023\/02\/06\/welsh-piper-hex-map-algorithm-python\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Welsh Piper hex map algorithm &#8211; Python&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[217,101,3,14,2],"tags":[513,134,512,510,293,28,26,492,511],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/paET2V-tb","jetpack-related-posts":[{"id":1833,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2023\/02\/07\/desert-maps\/","url_meta":{"origin":1809,"position":0},"title":"Desert Maps","author":"richard","date":"February 7, 2023","format":false,"excerpt":"Alex has made some adjustments to his Alpine algorithm for TextMapper to get better desert terrain - e.g. Australian. Lots of generic rpg maps assume European type things - e.g. cool to cold, whereas Australia is temperature to equatorial, in general. This one is a nice example https:\/\/campaignwiki.org\/text-mapper\/alpine\/document?width=52&bottom=3&peaks=7&bumps=2&height=48&steepness=4&peak=10&bump=2&arid=0&climate=desert&type=hex&seed=693329917","rel":"","context":"In &quot;Data Science&quot;","block_context":{"text":"Data Science","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/data-science\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1806,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2023\/02\/06\/mokuy-australia-hex-mapping-hex-describe-and-hex-mapper\/","url_meta":{"origin":1809,"position":1},"title":"Mokuy &#8211; Australia hex mapping, Hex Describe and Hex Mapper","author":"richard","date":"February 6, 2023","format":false,"excerpt":"Alex Schroeder has an 'Alpine' hex map generation option in https:\/\/campaignwiki.org\/hex-describe\/ . This allows you to tweak heights for maps. Also in TextMapper similarly. However, his native Switzerland and Australia are somewhat different in size and smoothness. These are great and the code is also here:- https:\/\/github.com\/kensanata?tab=repositories Australia DTM Histogram\u2026","rel":"","context":"In &quot;Data Science&quot;","block_context":{"text":"Data Science","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/data-science\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1716,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2023\/01\/26\/textmapper-with-gridmapper\/","url_meta":{"origin":1809,"position":2},"title":"Textmapper with Gridmapper","author":"richard","date":"January 26, 2023","format":false,"excerpt":"Making SVG maps from icons based on coordinates Example data file: https:\/\/campaignwiki.org\/contrib\/gridmapper-example.txt https:\/\/campaignwiki.org\/text-mapper GitHub https:\/\/github.com\/kensanata\/hex-mapping There's a git repository for the perl library version at the campaignwiki link,too. I should see if my generic shared hosting here can handle that sometime.","rel":"","context":"In &quot;Data Science&quot;","block_context":{"text":"Data Science","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/data-science\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1533,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2022\/12\/29\/dungeon23-mokuy-hex-map-australia-version-1\/","url_meta":{"origin":1809,"position":3},"title":"Dungeon23 &#8211; Mokuy hex map Australia &#8211; version 1","author":"richard","date":"December 29, 2022","format":false,"excerpt":"Not actually called Australia circa 1830 of course, but for reference. Mokuy Australia hex map A few different terrain types I think: Coastal Mountain Desert Rainforest Heavy Bush Bush Alluvial Grassland Volcanic - for Lord Howe Island, or as the more egotistical residents like to term it, Ruby Base Pine\u2026","rel":"","context":"In &quot;Fantasy&quot;","block_context":{"text":"Fantasy","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/fantasy\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=700%2C400&ssl=1 2x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=1050%2C600&ssl=1 3x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/australiamap.png?resize=1400%2C800&ssl=1 4x"},"classes":[]},{"id":1541,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2022\/12\/30\/dungeon23-maps-and-3d-models\/","url_meta":{"origin":1809,"position":4},"title":"Dungeon23 &#8211; Maps and 3D Models","author":"richard","date":"December 30, 2022","format":false,"excerpt":"Lord Howe Island 3m merged DEM I made a repository for these - or at least the lower resolution variety in the case of the DEMs. https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy Jupyter notebook here re: merging tiles for the high resolution DEM. Not got around to the point clouds as yet - and this\u2026","rel":"","context":"In &quot;Data Science&quot;","block_context":{"text":"Data Science","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/data-science\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=700%2C400&ssl=1 2x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=1050%2C600&ssl=1 3x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandDEM3m.png?resize=1400%2C800&ssl=1 4x"},"classes":[]},{"id":1547,"url":"https:\/\/cosmicheroes.space\/blog\/index.php\/2022\/12\/30\/dungeon-23-lord-howe-island-hexkit-hexmap\/","url_meta":{"origin":1809,"position":5},"title":"Dungeon 23 &#8211; Lord Howe Island HexKit HexMap","author":"richard","date":"December 30, 2022","format":false,"excerpt":"Or as the more egotistical mad scientist might call it 'Ruby Base'. This is at about 1km scale hex. The island is approximately 2 standard 'day travel' wilderness hexes N-S. Volcanic terrain of course making that part somewhat tougher. Added to here https:\/\/github.com\/bluetyson\/Dungeon23-Mokuy\/tree\/main\/Lord%20Howe%20Island","rel":"","context":"In &quot;Fantasy&quot;","block_context":{"text":"Fantasy","link":"https:\/\/cosmicheroes.space\/blog\/index.php\/category\/fantasy\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandMap1.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandMap1.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandMap1.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/cosmicheroes.space\/blog\/wp-content\/uploads\/2022\/12\/LordHoweIslandMap1.png?resize=700%2C400&ssl=1 2x"},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1809"}],"collection":[{"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=1809"}],"version-history":[{"count":2,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1809\/revisions"}],"predecessor-version":[{"id":1811,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1809\/revisions\/1811"}],"wp:attachment":[{"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=1809"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=1809"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cosmicheroes.space\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=1809"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}