I've mentioned this effect a few times long ago on the forum while developing it to get help with some stuff. A few months ago I was finally happy enough with it to release it as a 1.0 release (even though there are still a few known problems, see below):
http://www.lysator.liu.se/~perni/iboardgameexts/
It's the "Generate Countersheet" effect I want to describe here and ask about. The name is not very good. While my intention was to use it to do sheets of counters for boardgames (see http://en.wikipedia.org/wiki/Counter_(board_wargames)) it is also very well suited to do sheets of cards for cardgames (as shown on the homepage and in included examples). But I'm sure there has to be other uses I can't think of as well, and I think there is likely a better name it should have to make this more obvious (and maybe get attention from more developers...)
Basically it's the "Align and distribute" and "Create Tiled Clones" functions combined and mutated, on some heavy medication.
First you draw the parts you want to tile, then you open up Excel or OpenOffice Calc or a text editor and create a file of comma separated values that contains the info about what parts to combine to create the tiles, and also information on text and style and other things you want to modify for each tile. Each tile is created by copying one or more of the SVG parts (as specified on a row in the CSV file), putting them on the correct coordinate, and then optionally modifying some text contents etc or replacing references to external images, thus creating clones that are slightly different. Each sheet of generated tiles is placed on its own new layer to make printing easier. I hope you can imagine this is highly helpful when you have a cardgame of 300 different cards and want to draw everything in Inkscape, but be able to modify specific card values in a spreadsheet document. Changing the layout of all the cards can be done in Inkscape and then just rerun the effect.
One particularly useful thing when doing countersheets is that you can specify values to put on the front and back of each counter on the same row in the spreadsheet and the effect will generate separate layers with the tiled copies for fronts and backs, with the backs properly mirrored so that if you print the two layers and glue them to opposite sides of a sheet of cardboard they will line up properly.
If you want to you can draw rectangles in a layer with a special name (that I don't remember at the moment) and the generated copies will only be tiled within those rectangles. This is to make it possible to make sheets that exactly match the layout of a die if you want to diecut the sheets.
Now this is all very generic as you can see. There is nothing really boardgame specific about it apart from the name and included examples. But my imagination is too limited to come up with a better name or any good examples of what else to use it for.
One thing I can think of, although very basic, is creating sheets of invitation cards using Inkscape. Just draw one card, set the id attribute of some text containing the name of the recipient, then create a spreadsheet document with a list of everyone to send the cards to, run the effect, and you will get a sheet (or many sheets, if they do not all fit inside of one page) of cards each with its own recipient.
Currently known problems are basically problems with handling all possible SVG elements and attributes. For instance copying of gradients do not work very well at all times. It is unfortunate that each Inkscape plugin basically has to have full understanding of the SVG format. It would have been much easier if there was a proper API with access to internal Inkscape functions such as copy&paste, since obviously Inkscape already has all the code required to properly create a copy of an object (optionally) translating gradients with it.
Another big problem is that if I create a too big sheet Inkscape runs out of memory and crashes. This unfortunately happens sometimes with only ~100 counters, and some games are known to have 2000+ of them. So far I have been able to work around this by rendering static parts to bitmaps before using them with the effect, thus creating a much smaller SVG output. But it is possible to create huge sheets when using the effect as a stand-alone script, and then viewing these sheets in web browsers that can view SVG files.
So, any ideas or suggestions? I'm sure there are some obscure uses I can't think of.
countersheet extension (or is it?)
Re: countersheet extension (or is it?)
BTW the hexmap extension (used to create a grid of hexagons with coordinates written in them) is the same code as I used for an online version you can use here:
http://hexmaps.appspot.com/
It would be nice to have (some modified version of) that effect in the Inkscape distribution since so many people are asking for an application to render grids like that (well, if you hang out at forums were people discuss boardgame design it is a very common question, maybe not so often elsewhere).
http://hexmaps.appspot.com/
It would be nice to have (some modified version of) that effect in the Inkscape distribution since so many people are asking for an application to render grids like that (well, if you hang out at forums were people discuss boardgame design it is a very common question, maybe not so often elsewhere).
Re: countersheet extension (or is it?)
One of the examples of multiselect countersheets in 1.2:
This is from my latest post on bgg:
template
csv data file
result
(B is the multiselect column. Not very pedagogic screenshot perhaps. Some rows further down have the value "sad" in that column, to get the sad mouth.)
This is from my latest post on bgg:
template
csv data file
result
(B is the multiselect column. Not very pedagogic screenshot perhaps. Some rows further down have the value "sad" in that column, to get the sad mouth.)
Re: countersheet extension (or is it?)
I just found your extension and used it to create an Inkscape template. I used your countersheet extension to create custom game pieces for a PnP (print and play) Stratego-like game board. I'm going to dump the template onto a couple of game map and board game forums and send folks your way to get your extension so that they can use my template.
Thanks for the inspiration and tools!
matt
Thanks for the inspiration and tools!
matt