Improved action and attack schemas

This commit is contained in:
Stefan Zermatten
2019-02-18 15:52:17 +02:00
parent e63ae96cb5
commit 3129b86ef0
5 changed files with 73 additions and 36 deletions

View File

@@ -0,0 +1,15 @@
import SimpleSchema from 'simpl-schema';
import schema from '/imports/api/schema.js';
const AdjustmentSchema = schema({
stat: {
type: String,
optional: true,
},
roll: {
type: String,
optional: true,
},
});
export default AdjustmentSchema;

View File

@@ -0,0 +1,31 @@
import SimpleSchema from 'simpl-schema';
import schema from '/imports/api/schema.js';
const DamageSchema = schema({
type: {
type: String,
allowedValues: [
"bludgeoning",
"piercing",
"slashing",
"acid",
"cold",
"fire",
"force",
"lightning",
"necrotic",
"poison",
"psychic",
"radiant",
"thunder",
],
defaultValue: "slashing",
},
roll: {
type: String,
optional: true,
defaultValue: '1d8 + strengthMod',
},
});
export default DamageSchema;