gloomhaven-cards

0.0.1 • Public • Published

Gloomhaven-Modifier

This is a Javascript package for the Attack-Modifier of the boardgame Gloomhaven.

For this purpose each modifier card and each modifier deck is explicitely implemented.

This package includes a corresponding .png file for every single card.


Features

The features folder contains the source code and pictures.

  • Create every modifier card
  • Create every character deck
  • Add or remove cards from the deck
  • Shuffle the deck
  • Draw a card from a deck with a given value
  • Draw with advantage/disadvantage

Tests

The __ tests __ folder contains the tests for the implemented features. Every implemented feature was tested seperately as well as within joined cases.

  • All cards with respective modifier
  • All implemented deck methods

Examples

// Create a card
const plusTwo = new PlusTwo
 
// Apply card modifier to a value
plusOne.modifier(3) == 5
 
// Create a deck
var deck = new Deck
 
// Add a card to the deck (i.e. +2 card)
deck.addCard(plusTwo)
 
// Draw a card with a value (i.e. 4)
deck.draw(4)
 
// Value after drawing
deck.modifier == 6
// Special after drawing
deck.special = []

Package Sidebar

Install

npm i gloomhaven-cards

Weekly Downloads

0

Version

0.0.1

License

MIT

Unpacked Size

76.9 MB

Total Files

471

Last publish

Collaborators

  • jfklorenz