grislyeye / vellum-monster Goto Github PK
View Code? Open in Web Editor NEWWeb component for displaying 5th Edition monster stat blocks
License: Apache License 2.0
Web component for displaying 5th Edition monster stat blocks
License: Apache License 2.0
Stat block should be slightly wider than the content body box.
Upgrade to Polymer 3 when it is released.
Paragraphs are not currently supported in <vellum-stat>
action/trait descriptions. This needs to be fixed
Based on the monster's hitDie
attribute we should automatically calculate the average hit points (hp
) if this value is not provided.
Automatically apply ability score bonuses to armor.
For example, let's say we have the following:
<vellum-monster
id="monster"
name="Monster"
named="true"
size="Small"
type="fey"
alignment="chaotic neutral"
baseAc="10"
armor="natural armor"
hit-die="2d6 - 2"
speeds='["30 ft.","swim 30ft."]'
str="10"
dex="14"
con="8"
int="13"
wis="10"
cha="15"
This would display as as an effective/actual AC of 10
(baseAc
+ Dex Modifier of +2
).
This would need to be supported with a default ac
attribute which allows users to ignore calculations and force the monster's AC.
Hit points calculations are rounding up instead of down, e.g. a creature with hit dice 3d6 - 2 shoul dhave average hit points of 8. We are calculating them as 9
Add a schema.org-style schema page for monsters to web site.
Add linting to the build process for:
Based on the monster's stats we should automatically calculate a monster's challenge rating (cr
) if this value is not provided.
This may need additional work so as to add new attributes to accuractely determine CR (i.e. whether the monster can fly, etc.).
Add documentation to custom elements using Storybook:
Hit points are not displaying when they are specified.
Add semantic data to stat-block element so that it can be parsed by other software (i.e. to calculate CRs, etc.)
Add CI build (and badge) to verify errors
HTML tags are stripped from the bodies of <vellum-stat>
. We should copy HTML tags so that stats are displayed with, for example, italicised emphasis.
Currently limited usages are supported for actions only, and not attacks. For example:
<dl itemscope itemprop="actions">
<dt>Name</dt><dd itemprop="name">Warping Blow</dd>
<dt>Limited Usage</dt><dd itemprop="limitedUsage">Recharge 5-6</dd>
<dt>Reach</dt><dd itemprop="reach">5ft.</dd>
<dt>Attack Type</dt><dd itemprop="type">melee-attack</dd>
<dt>Target</dt><dd itemprop="target">one target</dd>
<dt>Damage</dt><dd itemprop="damage">3 (0 + 3)</dd>
<dt>Damage Type</dt><dd itemprop="damageType">bludgeoning</dd>
</dl>
Displays as:
At the moment the multiattack
action only supports multiples of a single attack. We would like to support different types in one action.
Something like this:
"multiAttacks": [
{
"id": "knife",
"number": "2"
},
{
"id": "bite",
}
]
βοΈ Important announcement: Greenkeeper will be saying goodbye π and passing the torch to Snyk on June 3rd, 2020! Find out how to migrate to Snyk and more at greenkeeper.io
2.2.1
to 2.3.0
.π¨ View failing branch.
This version is covered by your current version range and after updating it in your project the build failed.
lit-element is a direct dependency of this project, and it is very likely causing it to break. If other packages depend on yours, this update is probably also breaking those in turn.
The new version differs by 144 commits.
0eda741
Prepare 2.3.0 release (#933)
5a421e1
Fix formatting of new decorator for consistency (#934)
61d9583
Merge pull request #925 from ianwith/fix-docs
b8b9f74
Prepare 2.3.0-pre.1 release
38a8b85
Removes index signature from PropertyDeclaration (#929)
6a4c94f
Fix static property for closure (#926)
9060da0
Correct docs: styles - CSS inheritance
e0dcd75
Add extra type information to help closure with type of static property. (#923)
8055b93
Merge pull request #914 from Polymer/customize-properties
90c85a5
Address review feedback.
8f5815f
Update comment.
ec9048b
Fix spacing.
def6df1
Fix spacing.
297b8b2
Address review feedback.
734adc5
Adds API doc for createPropertyDescriptor
There are 144 commits in total.
See the full diff
There is a collection of frequently asked questions. If those donβt help, you can always ask the humans behind Greenkeeper.
Your Greenkeeper Bot π΄
Automatically calculate attack and damage bonuses from ability score modifiers.
For example, if a Strength +3 monster has an attack defined without attack bonus or damage as follows:
{
"name": "Dagger",
"type": "melee-or-ranged-attack",
"reach": "5ft.",
"range": "20/60 ft.",
"target": "one target",
"damageDie": "2d4",
"damageType": "slashing"
}
We end up with actual attack bonus of +5
and a damage of 2d4+4
.
Add Monster Manual-like textures to the stat block backgrounds, including the top bar.
Convert project to use open-wc testing and linting frameworks.
Based on the monster's challenge rating (cr
) attribute we should automatically calculate a monster's experience points (xp
) if this value is not provided.
The end-to-end tests on desktop and front-end appear to be broken:
https://travis-ci.org/grislyeye/vellum-monster/builds/539441074
Add linting to the build process for:
Given the following HTML:
<vellum-monster
hp="200"
ac="18"
cr="2"
xp="450"
></vellum-monster>
Expected behavior:
It will display the following text in the stat block:
Armor Class 18
Hit Points 200
Challenge 2 (450 XP)
Actual behavior:
It will display the following text in the stat block:
Armor Class 18
Hit Points 200
Challenge 4 (450 XP)
Thank you a lot for all of the time and work you put into this project!
βοΈ Important announcement: Greenkeeper will be saying goodbye π and passing the torch to Snyk on June 3rd, 2020! Find out how to migrate to Snyk and more at greenkeeper.io
14.1.0
to 14.1.1
.π¨ View failing branch.
This version is covered by your current version range and after updating it in your project the build failed.
eslint-config-standard is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.
The new version differs by 7 commits.
3f4a3fe
14.1.1
2a14319
Merge pull request #164 from standard/remove-no-return-await
243d38f
Remove no-return-await rule
eb187de
chore: .npmrc with package-lock=false (#155)
dcf95fe
chore: .npmrc with package-lock=false
e5e81a8
Merge pull request #153 from standard/greenkeeper/eslint-plugin-node-10.0.0
83ba3be
chore(package): update eslint-plugin-node to version 10.0.0
See the full diff
There is a collection of frequently asked questions. If those donβt help, you can always ask the humans behind Greenkeeper.
Your Greenkeeper Bot π΄
Hello, thank you again for all of your hard work on this project.
I have a suggestion:
In textual data representations, empty arrays are often used to represent empty to-many relationships. (one such example)
A monster's immunities or reactions would be two cases of a to-many relationship. They can have anywhere between 0 and many immunities and/or reactions.
In vellum-monster, if an empty array is passed to a field expecting an array, such as immunities
or reactions
, it will still show the Immunities or Reactions text, even though they have no content.
My suggestion would be to hide these fields in the end result if the content passed to them is empty.
Given the following HTML:
<vellum-monster>
hp="200"
ac="18"
immunities='[]'
reactions='[]'
</vellum-monster>
Current outcome:
Hit Points 200
Armor Class 18
Damage ImmunitiesReactions
Suggested outcome:
Hit Points 200
Armor Class 18
Thank you again for your work! Let me know what you think!
Add Polymer API documentation to custom elements.
Separate the <vellum-stat-block>
into <vellum-stat-block>
and <vellum-monster>
:
<vellum-stat-block>
generic stat-block style container for any "thing", like locations, NPCS etc.<vellum-monster>
for standard monster stat blocks, as per the "old" <vellum-stat-block>
Add stat block drop shadow to official them.
Upgrade from Polymer 3 (deprecated) to use LitElement/lit-html.
Effective AC CR is being calculated incorrectly. Given a monster with 9 HP and AC 16 we get:
Value | Effective CR | |
---|---|---|
HP | 9 | β |
AC | 16 | +1 |
But the effective defensive CR for the AC should be +5.
Stat block should be slightly wider than the content body box.
Add Monster Manual-like textures to the stat block backgrounds, including the top bar.
Add unit tests as described here:
Add a schema.org-style schema page for monsters to web site.
Arguably the most important thing about this is what it looks like.
If you want others to use / contribute, I recommend adding a demo / image / gif in the readme.
Currently limited usages are supported for actions only, and not attacks. For example:
<dl itemscope itemprop="actions">
<dt>Name</dt><dd itemprop="name">Warping Blow</dd>
<dt>Limited Usage</dt><dd itemprop="limitedUsage">Recharge 5-6</dd>
<dt>Reach</dt><dd itemprop="reach">5ft.</dd>
<dt>Attack Type</dt><dd itemprop="type">melee-attack</dd>
<dt>Target</dt><dd itemprop="target">one target</dd>
<dt>Damage</dt><dd itemprop="damage">3 (0 + 3)</dd>
<dt>Damage Type</dt><dd itemprop="damageType">bludgeoning</dd>
</dl>
Displays as:
We can automatically calculate hit die based on size and Constitution. For this we will need a new attribute, something like numberOfHitDie
and we can calculate the rest by determing dice from size (Small is d6, etc.) and modifier from Constitution score (numberOfHitDie * Cons modifier
).
Automatically calculate skills/saves/weapon bonuses if new proficiency
stat is present.
Polymer has been deprecated, and our depedency on the unsupported polymer CLI is causing issues:
We should find another way to run the component tests in a browers outside of the polymer test
CLI.
Some attacks are spell attacks (ranged and melee). We should support these using the new attack types ranged-spell-attack
, melee-spell-attack
and melee-or-ranged-spell-attack
.
Add CDN script library so that stat-blocks can be easily used in other web sites, even from markdown!
Add stat block drop shadow to official theme
Add support for damage and attack bonuses for non-attack actions, and spell-like actions.
For example, the action:
{
"name": "Shadow Rift (1/day)",
"id": "shadow-rift",
"description": "The Gloaming Queen can open a rift to the abyss in a 20-foot sphere centred on a point she can see within 120 feet. Any creature within the rift takes 10d8 necrotic damage, or half damage with a successful DC 14 Constitution saving throw."
}
There should be a method to define the damage and saving throw for this action so that CR can be correctly calculated.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.