Continued iterating on calculations, added failing test for bugs found

This commit is contained in:
Stefan Zermatten
2021-09-27 17:26:52 +02:00
parent 85e8756d1d
commit b0ee5cd304
9 changed files with 67 additions and 16 deletions

View File

@@ -9,6 +9,7 @@ const DamageSchema = createPropertySchema({
type: 'fieldToCompute',
optional: true,
defaultValue: '1d8 + strength.modifier',
parseLevel: 'compile',
},
// Who this damage applies to
target: {
@@ -31,6 +32,7 @@ const ComputedOnlyDamageSchema = createPropertySchema({
amount: {
type: 'computedOnlyField',
optional: true,
parseLevel: 'compile',
},
});

View File

@@ -38,6 +38,7 @@ function computedOnlyInlineCalculationField(field){
},
[`${field}.inlineCalculations.$`]: {
type: Object,
parseLevel: 'compile',
},
// The part between bracers {}
[`${field}.inlineCalculations.$.calculation`]: {