Files
foundryvtt-reve-de-dragon/module/models/danse.mjs
T

23 lines
965 B
JavaScript

import { TEMPLATE_DESCRIPTION } from "../common/_module.mjs";
import { CommonAppreciable } from "../common/appreciable.mjs";
import { INTEGER, STRING } from "../common/field-types.mjs";
const fields = foundry.data.fields;
const TEMPLATE_APPRECIABLE = new CommonAppreciable();
export default class RdDModelDanse extends foundry.abstract.TypeDataModel {
static defineSchema() {
return Object.assign({},
TEMPLATE_DESCRIPTION.fields(),
TEMPLATE_APPRECIABLE.fields(),
{
type: new fields.StringField({ label: "Type de danse", initial: "", ...STRING }),
agilite: new fields.BooleanField({ label: "Agilité", initial: false }),
apparence: new fields.BooleanField({ label: "Apparence", initial: false }),
niveau: new fields.NumberField({ label: "Niveau", initial: 0, integer: true, min: 0 }),
reference: new fields.StringField({ label: "Référence / Auteur", initial: "", ...STRING }),
}
);
}
}