2024-12-04 00:11:23 +01:00
|
|
|
import { SYSTEM } from "../config/system.mjs"
|
|
|
|
export default class CthulhuEternalArmor extends foundry.abstract.TypeDataModel {
|
|
|
|
static defineSchema() {
|
|
|
|
const fields = foundry.data.fields
|
|
|
|
const schema = {}
|
|
|
|
const requiredInteger = { required: true, nullable: false, integer: true }
|
|
|
|
|
|
|
|
schema.description = new fields.HTMLField({ required: true, textSearch: true })
|
2024-12-22 23:04:15 +01:00
|
|
|
schema.settings = new fields.StringField({ required: true, initial: "modern", choices: SYSTEM.AVAILABLE_SETTINGS })
|
2024-12-04 00:11:23 +01:00
|
|
|
schema.protection = new fields.NumberField({ ...requiredInteger, required: true, initial: 0, min: 0 })
|
|
|
|
schema.resourceLevel = new fields.NumberField({ required: true, initial: 0, min: 0 })
|
|
|
|
|
|
|
|
return schema
|
|
|
|
}
|
|
|
|
|
|
|
|
/** @override */
|
|
|
|
static LOCALIZATION_PREFIXES = ["CTHULHUETERNAL.Armor"]
|
|
|
|
}
|