RC-20 | Add Fate path to datamodel
This commit is contained in:
parent
27f668b92f
commit
550aeb084f
2 changed files with 17 additions and 0 deletions
|
|
@ -1,3 +1,5 @@
|
||||||
|
import { FatePath } from "../../gameTerms.mjs";
|
||||||
|
|
||||||
const { fields } = foundry.data;
|
const { fields } = foundry.data;
|
||||||
|
|
||||||
export class HeroData extends foundry.abstract.TypeDataModel {
|
export class HeroData extends foundry.abstract.TypeDataModel {
|
||||||
|
|
@ -53,6 +55,15 @@ export class HeroData extends foundry.abstract.TypeDataModel {
|
||||||
nullable: false,
|
nullable: false,
|
||||||
}),
|
}),
|
||||||
}),
|
}),
|
||||||
|
fate: new fields.StringField({
|
||||||
|
initial: ``,
|
||||||
|
blank: true,
|
||||||
|
trim: true,
|
||||||
|
nullable: false,
|
||||||
|
choices: () => {
|
||||||
|
return Object.values(FatePath).concat(``);
|
||||||
|
},
|
||||||
|
}),
|
||||||
level: new fields.SchemaField({
|
level: new fields.SchemaField({
|
||||||
glory: new fields.NumberField({
|
glory: new fields.NumberField({
|
||||||
min: 0,
|
min: 0,
|
||||||
|
|
|
||||||
6
module/gameTerms.mjs
Normal file
6
module/gameTerms.mjs
Normal file
|
|
@ -0,0 +1,6 @@
|
||||||
|
export const FatePath = {
|
||||||
|
NORTH: `North`,
|
||||||
|
EAST: `East`,
|
||||||
|
SOUTH: `South`,
|
||||||
|
WEST: `West`,
|
||||||
|
};
|
||||||
Loading…
Add table
Add a link
Reference in a new issue