Datamodel + Appv2 migration, WIP
This commit is contained in:
@@ -18,6 +18,9 @@ import { BoLHotbar } from "./system/bol-hotbar.js"
|
||||
import { BoLCommands } from "./system/bol-commands.js"
|
||||
import { BoLRoll } from "./controllers/bol-rolls.js"
|
||||
|
||||
// Import DataModels
|
||||
import * as models from "./models/_module.mjs"
|
||||
|
||||
/* -------------------------------------------- */
|
||||
Hooks.once('init', async function () {
|
||||
|
||||
@@ -28,7 +31,8 @@ Hooks.once('init', async function () {
|
||||
BoLRoll,
|
||||
BoLUtility,
|
||||
macros: Macros,
|
||||
config: BOL
|
||||
config: BOL,
|
||||
models
|
||||
};
|
||||
|
||||
// Game socket
|
||||
@@ -47,7 +51,19 @@ Hooks.once('init', async function () {
|
||||
|
||||
// Define custom Entity classes
|
||||
CONFIG.Actor.documentClass = BoLActor;
|
||||
CONFIG.Actor.dataModels = {
|
||||
character: models.BoLCharacter,
|
||||
encounter: models.BoLEncounter,
|
||||
horde: models.BoLHorde,
|
||||
vehicle: models.BoLVehicle
|
||||
}
|
||||
|
||||
CONFIG.Item.documentClass = BoLItem;
|
||||
CONFIG.Item.dataModels = {
|
||||
item: models.BoLItem,
|
||||
feature: models.BoLFeature
|
||||
}
|
||||
|
||||
CONFIG.Combat.documentClass = BoLCombatManager;
|
||||
|
||||
// Register sheet application classes
|
||||
|
||||
Reference in New Issue
Block a user