#5 Languages/Subcultures management

This commit is contained in:
2021-03-12 15:03:35 +01:00
parent 56eb2aeef1
commit 5795c42808
4 changed files with 76 additions and 7 deletions

View File

@ -47,12 +47,14 @@ export class SoSActorSheet extends ActorSheet {
data.data.currentWounds = this.actor.computeCurrentWounds();
data.data.totalWounds = this.actor.data.data.scores.wound.value;
data.data.subculture = this.actor.data.items.find( item => item.type == 'subculture');
data.data.geneline = this.actor.data.items.find( item => item.type == 'geneline');
data.data.subcultureList = this.actor.data.items.filter( item => item.type == 'subculture');
if ( data.data.subculture != "" ) { // background.subculture contains the main subculture ID
data.data.mainSubculture = data.data.subcultureList.find( subc => subc._id == data.data.subculture);
}
data.data.languageList = this.actor.data.items.filter( item => item.type == 'language');
data.data.geneline = this.actor.data.items.find( item => item.type == 'geneline');
data.data.editStatSkill = this.options.editStatSkill;
console.log("stats", data);
//data.stats = duplicate(this.actor.stats);
//data.scores = duplicate(this.actor.scores);
return data;
}