Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

This is a simple tool which can help rapidly prototype cards/tiles/chits for board/card games. It uses csv files to import data, and jade templates to generate html from them. Finally, it uses wkhtmltopdf to generate pdfs which can be printed.

License

Notifications You must be signed in to change notification settings

jchaffer/ludomatic5000

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

31 Commits

Repository files navigation

ludomatic5000

This is a simple tool which can help rapidly prototype cards/tiles/chits for board/card games. It uses csv files to import data, and jade templates to generate html from them. Finally, it uses wkhtmltopdf to generate pdfs which can be printed.

Installation

  • Download and install wkhtmltopdf.
  • Install node.js.
  • From the terminal, run npm install ludomatic5000 -g.
  • You should now be able to use the ludo command.

Usage

  • cd to a directory that you want to put your new project
  • Use the command ludo init
  • To see the default print results, use the command ludo draw.
  • To open a browser window for feedback when designing, use the command ludo design.

Creating your game

There are 3 required files for any component of a game.

  • The template: This is a jade or mustache template in the templates directory.
  • The styles: This is a css file in the styles directory.
  • The data: This is a csv file in the data directoy.

Your template and styles files will be responsible for outputting the html and styling for a single component. Ludomatic will handle the rest by inserting that html into a layout file which will be sized correctly for your target output. Using ludo init will create the stub files you need. Using ludo new <component-name> will create a new component in the same project directory.

Options

usage: ludo [<options] <command> <component>
Global Options:
 -h, --help Display help
 -v, --version Output version information and exit
Draw Options:
 -t, --target <target> What print/print company format should be
 used? Avaliable options are "pnp" for
 print and play printing on a personal printer
 or "tgc" for output targeting "The Game Crafter"
 -o, --output <outputfile> Path and filename of the output pdf in the case
 of print and play, or the output directory in
 case of The Game Crafter output.
 -p, --paper <papersize> I the case of pnp, allows you to specify what type of
 paper should be used to layout the components for
 the output pdf. Available sizes are "letter" and "a4"
Design Options:
 --port <portnumber> When the server runs, which port should be used?
 
The commands are:
 init [empty] Initializes a new project with the correct default directories,
 default data/template/style files and configuration file. If 
 "empty" is specified as an arg, it will only generate the
 directories and config file.
 new <component> Adds a new component, generating stub data/template/style files,
 and adding an entry to the ludo.json config file.
 draw <component> Generates output file(s) based on the selected target.
 design <component> Opens a webpage which displays an interactive live preview of the
 component being designed.
 
The component specied after the command indicates which component should be drawn or designed.
Knowing the component determines which data/template/styles should be used. Configuration specific
to a component can either use defaults, specify configuration in the ludo.json file, or override from
the command line options.

About

This is a simple tool which can help rapidly prototype cards/tiles/chits for board/card games. It uses csv files to import data, and jade templates to generate html from them. Finally, it uses wkhtmltopdf to generate pdfs which can be printed.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 97.0%
  • HTML 1.3%
  • Pug 1.1%
  • CSS 0.6%

AltStyle によって変換されたページ (->オリジナル) /