Fix 0.8.2 actors
This commit is contained in:
parent
c7ba56b90b
commit
6d7d55e12b
@ -63,6 +63,7 @@ export class RdDActorSheet extends ActorSheet {
|
|||||||
|
|
||||||
// // Copy Active Effects
|
// // Copy Active Effects
|
||||||
// data.effects = effects;
|
// data.effects = effects;
|
||||||
|
console.log("---- data");
|
||||||
|
|
||||||
// // Return template data
|
// // Return template data
|
||||||
let formData = {
|
let formData = {
|
||||||
|
@ -108,7 +108,7 @@ export class RdDActor extends Actor {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const competences = await RdDUtility.loadCompendium(RdDItemCompetence.actorCompendium(actorData.type));
|
const competences = await RdDUtility.loadCompendium(RdDItemCompetence.actorCompendium(actorData.type));
|
||||||
actorData.items = competences.map(it => Misc.data(it));
|
actorData.items = competences.map(i => i.toObject());
|
||||||
if (isPersonnage) {
|
if (isPersonnage) {
|
||||||
actorData.items = actorData.items.concat(Monnaie.monnaiesData());
|
actorData.items = actorData.items.concat(Monnaie.monnaiesData());
|
||||||
}
|
}
|
||||||
@ -2014,6 +2014,7 @@ export class RdDActor extends Actor {
|
|||||||
return draconicList;
|
return draconicList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* -------------------------------------------- */
|
||||||
getDraconicsSort(draconicList, sort) {
|
getDraconicsSort(draconicList, sort) {
|
||||||
//console.log(draconicList, bestDraconic, draconic, voie);
|
//console.log(draconicList, bestDraconic, draconic, voie);
|
||||||
switch (Grammar.toLowerCaseNoAccent(sort.name)) {
|
switch (Grammar.toLowerCaseNoAccent(sort.name)) {
|
||||||
|
@ -488,6 +488,7 @@ export class RdDUtility {
|
|||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
static async loadCompendium(compendium, filter = item => true) {
|
static async loadCompendium(compendium, filter = item => true) {
|
||||||
let compendiumData = await RdDUtility.loadCompendiumData(compendium);
|
let compendiumData = await RdDUtility.loadCompendiumData(compendium);
|
||||||
|
console.log(compendiumData);
|
||||||
return compendiumData.filter(filter);
|
return compendiumData.filter(filter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -22,15 +22,18 @@ export class PixiTMR {
|
|||||||
|
|
||||||
load(onLoad = (loader, resources) => {}) {
|
load(onLoad = (loader, resources) => {}) {
|
||||||
let loader = this.pixiApp.loader;
|
let loader = this.pixiApp.loader;
|
||||||
|
console.log("LOADING 1");
|
||||||
for (const [name, img] of Object.entries(PixiTMR.textures)) {
|
for (const [name, img] of Object.entries(PixiTMR.textures)) {
|
||||||
loader = loader.add(name, img);
|
loader = loader.add(name, img);
|
||||||
}
|
}
|
||||||
|
console.log("LOADING 2");
|
||||||
loader.load((loader, resources) => {
|
loader.load((loader, resources) => {
|
||||||
onLoad(loader, resources);
|
onLoad(loader, resources);
|
||||||
for (let onAnimate of this.callbacksOnAnimate) {
|
for (let onAnimate of this.callbacksOnAnimate) {
|
||||||
onAnimate();
|
onAnimate();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
console.log("LOADING 3");
|
||||||
}
|
}
|
||||||
|
|
||||||
static register(name, img) {
|
static register(name, img) {
|
||||||
|
Loading…
Reference in New Issue
Block a user