modality / obsidian-text-mapper

Render beautiful hex maps in Obsidian.md
MIT License
36 stars 8 forks source link

How difficult would it be for somebody to add the Traveller tileset? #2

Open themaster567 opened 1 year ago

themaster567 commented 1 year ago

I really would love to see support for the Traveller map added. I'm using this for my Starforged adventures and it's already perfect for planetside content. If it could cover content in space as well, then I could just out right remove the excalcudraw plugin and use this exclusively.

modality commented 1 year ago

The Gnomeyland tileset is here... as you can see it's just a big multiline string which contains some Textmapper appropriate code as well as raw SVG XML. When you declare SVG in this file, Textmapper will read the id attribute, and then use the SVG. You can also reference other icons to make composite icons with the use tag.

So here's the village icon. It scales and translates three other raw SVG icons (House, Thorp, and Flag), and wraps the whole thing in <g id="village"></g>

<g id="village"><g transform="scale(0.7)"><g transform="translate(0,40)"><use xlink:href="#House"/><use xlink:href="#Thorp"/><use xlink:href="#Flag"/></g></g></g>

Then you can use it in Textmapper like this (soil is a color and "Inn of Five Fishes" is a label).

0513 soil village "Inn of Five Fishes"

So if you were going to do this with Traveller icons, I'd say

thattreethatfell commented 8 months ago

@modality How difficult would it be to jury rig the dungeon library tiles in this way? Or would it not be possible with the current code?