Deckorator
Tools for creating card games & board games. This is intended to be used by a developer.
Usage
import deckorator.dart
to get all the tools or just import the specific category of tools listed below.
package:deckorator/http.dart
Http tools.
fetchCsvFromGoogleSpeadsheet(...)
Fetches the CSV output form a google spreadsheet. In order for this to work you need to make sure you have sharing options for the spreadsheet set to 'Anyone with a link can view'.
// import BrowserClient or IoClient as required from package:http
final client = new IoClient();
final String csvString = fetchCsvFromGoogleSpeadsheet(
client, 'your-spreadsheet-id-here', 'Sheet 1');
package:deckorator/data.dart
Data tools
csvToDataTable(...)
Creates a DataTable
representing the data stored in a csv.
final DataTable data = csvToDataTable(csvString);
package:deckorator/pdf.dart
PDF related tools.
outputPdfSheet(...)
Outputs a sheet of PDF components. Provide it with the sheet size, a list of GameComponent
and it will lay the components out. You can also provide optional parameters for:
bleed
: bleed for artworkseperateFiles
: Each page of components will be seperate PDFsseperateFilesSeperateBacks
: If usingseperateFiles
you can have front and back in same file by setting this to false.componentOutline
will outline your components for cutting. Note this is only advised if creating a rough draft. If using for production just leave the default cut lines on which will not enter the bleed.backSheetOffsetVertical
Useful for duplex printing, if the reverse side of the print has a vertical offset set that here.backSheetOffsetHorizontal
Useful for duplex printing, if the reverse side of the print has a horizontal offset set that here.
outputPdfCard(...)
Outputs a PDF card.
package:deckorator/image.dart
Image processing related tools.
resizePng(...)
Resizes a single PNG file
resizePngs(...)
Resizes numerous PNG files.