Compare commits

...

39 Commits

Author SHA1 Message Date
939cfb1e86 Update compendiums 2025-09-15 22:23:25 +02:00
5f5e0e2a8c Update magie 2025-09-15 21:10:46 +02:00
c993a9a5b1 Update magie 2025-09-15 21:09:09 +02:00
cc7de0e53c Amelioration diverses pour la magie 2025-09-14 20:12:02 +02:00
4d41986c12 Ajout pour la magie 2025-09-13 00:24:58 +02:00
d04731f475 Ajout pour la magie 2025-09-13 00:24:08 +02:00
44a641a0ca Update arts obscurs 2025-08-13 09:39:04 +02:00
1ad022d193 Update arts obscurs 2025-08-13 09:38:35 +02:00
1c7cf343b1 Update arts obscurs 2025-08-12 23:24:50 +02:00
d4b00e3508 Update arts obscurs 2025-08-12 23:20:51 +02:00
adc912e6cd Ajout/upgrade des arts obscurs 2025-08-11 22:53:23 +02:00
51a457ebf6 Foundry v13 migration 2025-05-02 08:34:22 +02:00
2e9c558027 Ajout arts obscurs 2024-11-17 22:46:52 +01:00
bcd0758328 Ajout arts obscurs 2024-11-17 22:45:48 +01:00
2b680a203f Fix jet avec prestance 2024-08-11 14:40:41 +02:00
e3d7874dce Fix masque/demaque + pouvoir passif avec point 2024-07-30 13:45:50 +02:00
ab6a5832c0 Various v12 fixes 2024-07-13 12:13:06 +02:00
d83a999974 Various v12 fixes 2024-07-13 12:12:38 +02:00
b83890a764 Add v12 support 2024-05-23 15:38:50 +02:00
5ad3c165e5 Add v12 support 2024-05-23 11:25:51 +02:00
2b3e774cbb Correction sur les pouvoirs des fiches de PNJ 2024-04-25 10:30:15 +02:00
96f8d2bceb Fix roll pouvoir + pouvoirs passifs 2024-04-11 12:36:50 +02:00
e288c90ee4 Bouton d'ajout d'items dans la fiche PNJ 2024-04-01 17:27:20 +02:00
8916de8613 Bouton d'ajout d'items dans la fiche 2024-03-31 17:53:56 +02:00
8598df5a57 Ajout de la gestion des Points d'usage 2024-03-23 11:37:15 +01:00
8781462c8d Correction sur competences à 0 + diverses ameliorations 2024-03-06 19:00:01 +01:00
8c38aead3e Correction sur competences à 0 + diverses ameliorations 2024-03-06 18:46:53 +01:00
67bf71e6c0 Fix competences 2024-03-01 13:39:32 +01:00
63d15e82bb Enhance stats 2024-02-08 12:56:25 +01:00
62c3787cea Affichage des specialisations 2023-12-19 22:13:26 +01:00
df61abac19 Gestion des heritages 2023-12-19 21:35:20 +01:00
a7d1a14c52 Fix css for compendiums 2023-05-29 17:00:57 +02:00
b0dc6f36e4 Fix css for compendiums 2023-05-29 16:33:08 +02:00
5109d2aa91 Modification CSS pour compendiums 2023-05-29 13:22:43 +02:00
51c162ecbb v10/v11 compat 2023-05-25 15:43:55 +02:00
44d02b0cd1 Fix sur pouvoirs, heritage et 2 pts de tricherie 2023-05-01 18:48:34 +02:00
9b1600304a Fix sur pouvoirs, heritage et 2 pts de tricherie 2023-04-30 20:08:29 +02:00
2dff59c829 Fix pv value pour PNJ 2023-04-24 15:59:07 +02:00
55a2a8e3c3 Fix malus 2023-04-23 23:13:31 +02:00
130 changed files with 5336 additions and 2740 deletions

BIN
assets/icons/sort.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

View File

@@ -1,30 +1,24 @@
{
"ACTOR": {
"TypePersonnage": "Personnage",
"TypePNJ": "PNJ"
},
"ITEM": {
"TypeArtefact": "Artefact",
"TypeArme": "Arme",
"TypeTalent": "Talent",
"TypeHistorique": "Historique",
"TypeProfil": "Profil",
"TypeCompetence": "Compétence",
"TypeProtection": "Protection",
"TypeMonnaie": "Monnaie",
"TypeEquipement": "Equipement",
"TypeRessource": "Ressource",
"TypeContact": "Contact"
},
"HAWKMOON": {
"ui": {
"editContact": "Modifier le contact",
"deleteContact": "Supprimer le contact",
"editTrait": "Modifier le trait",
"deleteTrait": "Supprimer le trait"
"TYPES": {
"Actor": {
"personnage": "Personnage",
"pnj": "PNJ"
},
"Item": {
"accessoire": "Accessoire",
"arme": "Arme",
"atoutfeerique": "Atout féerique",
"avantage": "Avantage",
"capacitenaturelle": "Capacité naturelle",
"competence": "Compétence",
"contact": "Contact",
"desavantage": "Désavantage",
"equipement": "Equipement",
"fee": "e",
"pouvoir": "Pouvoir",
"profil": "Profil",
"protection": "Protection",
"sort": "Sort"
}
}
}

View File

@@ -12,7 +12,7 @@ export class HeritiersActorPNJSheet extends HeritiersActorSheet {
/** @override */
static get defaultOptions() {
return mergeObject(super.defaultOptions, {
return foundry.utils.mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "actor"],
template: "systems/fvtt-les-heritiers/templates/actor-pnj-sheet.html",
width: 780,

View File

@@ -6,12 +6,12 @@
import { HeritiersUtility } from "./heritiers-utility.js";
/* -------------------------------------------- */
export class HeritiersActorSheet extends ActorSheet {
export class HeritiersActorSheet extends foundry.appv1.sheets.ActorSheet {
/** @override */
static get defaultOptions() {
return mergeObject(super.defaultOptions, {
return foundry.utils.mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "actor"],
template: "systems/fvtt-les-heritiers/templates/actor-sheet.html",
width: 780,
@@ -24,7 +24,7 @@ export class HeritiersActorSheet extends ActorSheet {
/* -------------------------------------------- */
async getData() {
const objectData = duplicate(this.object)
const objectData = foundry.utils.duplicate(this.object)
let formData = {
title: this.title,
@@ -38,30 +38,33 @@ export class HeritiersActorSheet extends ActorSheet {
effects: this.object.effects.map(e => foundry.utils.deepClone(e.data)),
limited: this.object.limited,
skills: this.actor.getSkills(),
utileSkillsMental :this.actor.organizeUtileSkills("mental"),
utileSkillsPhysical :this.actor.organizeUtileSkills("physical"),
futileSkills :this.actor.organizeFutileSkills(),
utileSkillsMental: this.actor.organizeUtileSkills("mental"),
utileSkillsPhysical: this.actor.organizeUtileSkills("physical"),
competencesMagie: HeritiersUtility.getCompetencesMagie(),
futileSkills: this.actor.organizeFutileSkills(),
contacts: this.actor.organizeContacts(),
armes: duplicate(this.actor.getWeapons()),
monnaies: duplicate(this.actor.getMonnaies()),
pouvoirs: duplicate(this.actor.getPouvoirs()),
fee: duplicate(this.actor.getFee() || {} ),
protections: duplicate(this.actor.getArmors()),
combat: this.actor.getCombatValues(),
equipements: duplicate(this.actor.getEquipments()),
avantages: duplicate(this.actor.getAvantages()),
atouts: duplicate(this.actor.getAtouts()),
capacites: duplicate(this.actor.getCapacites()),
desavantages: duplicate(this.actor.getDesavantages()),
profils: duplicate(this.actor.getProfils()),
pvMalus: this.actor.getPvMalus(),
armes: foundry.utils.duplicate(this.actor.getWeapons()),
monnaies: foundry.utils.duplicate(this.actor.getMonnaies()),
pouvoirs: foundry.utils.duplicate(this.actor.getPouvoirs()),
fee: foundry.utils.duplicate(this.actor.getFee() || {}),
protections: foundry.utils.duplicate(this.actor.getArmors()),
combat: this.actor.getCombatValues(),
equipements: foundry.utils.duplicate(this.actor.getEquipments()),
avantages: foundry.utils.duplicate(this.actor.getAvantages()),
atouts: foundry.utils.duplicate(this.actor.getAtouts()),
capacites: foundry.utils.duplicate(this.actor.getCapacites()),
desavantages: foundry.utils.duplicate(this.actor.getDesavantages()),
profils: foundry.utils.duplicate(this.actor.getProfils()),
pvMalus: this.actor.getPvMalus(),
heritage: game.settings.get("fvtt-les-heritiers", "heritiers-heritage"),
initiative: this.actor.getFlag("world", "last-initiative") || -1,
description: await TextEditor.enrichHTML(this.object.system.biodata.description, {async: true}),
revesetranges: await TextEditor.enrichHTML(this.object.system.biodata.revesetranges, {async: true}),
secretsdecouverts: await TextEditor.enrichHTML(this.object.system.biodata.secretsdecouverts, {async: true}),
questions: await TextEditor.enrichHTML(this.object.system.biodata.questions, {async: true}),
habitat: await TextEditor.enrichHTML(this.object.system.biodata.habitat, {async: true}),
playernotes: await TextEditor.enrichHTML(this.object.system.biodata.playernotes, {async: true}),
description: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.description, { async: true }),
revesetranges: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.revesetranges, { async: true }),
secretsdecouverts: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.secretsdecouverts, { async: true }),
questions: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.questions, { async: true }),
habitat: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.habitat, { async: true }),
playernotes: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.biodata.playernotes, { async: true }),
magieList: this.actor.prepareMagie(),
options: this.options,
owner: this.document.isOwner,
editScore: this.options.editScore,
@@ -76,19 +79,42 @@ export class HeritiersActorSheet extends ActorSheet {
}
/* -------------------------------------------- */
getCelluleTalents( ) {
let talents = []
for(let cellule of game.actors) {
if (cellule.type == "cellule") {
let found = cellule.system.members.find( it => it.id == this.actor.id)
if (found) {
talents = talents.concat( cellule.getTalents() )
dialogRecupUsage() {
new Dialog({
title: "Récupération des Points d'Usage",
content: "<p>Combien de Points d'Usage souhaitez-vous récupérer ?</p>",
buttons: {
one: {
icon: '<i class="fas fa-check"></i>',
label: "1 Point",
callback: () => {
this.actor.recupUsage(1)
}
},
two: {
icon: '<i class="fas fa-check"></i>',
label: "2 Points",
callback: () => {
this.actor.recupUsage(2)
}
},
four: {
icon: '<i class="fas fa-check"></i>',
label: "4 Points",
callback: () => {
this.actor.recupUsage(4)
}
},
all: {
icon: '<i class="fas fa-check"></i>',
label: "Tous les Points",
callback: () => {
this.actor.recupUsage(100)
}
}
}
}
return talents
}).render(true)
}
/* -------------------------------------------- */
/** @override */
activateListeners(html) {
@@ -96,14 +122,14 @@ export class HeritiersActorSheet extends ActorSheet {
// Everything below here is only needed if the sheet is editable
if (!this.options.editable) return;
// Update Inventory Item
html.find('.item-edit').click(ev => {
const li = $(ev.currentTarget).parents(".item")
let itemId = li.data("item-id")
const item = this.actor.items.get( itemId )
const item = this.actor.items.get(itemId)
item.sheet.render(true)
})
})
// Delete Inventory Item
html.find('.item-delete').click(ev => {
const li = $(ev.currentTarget).parents(".item");
@@ -111,8 +137,8 @@ export class HeritiersActorSheet extends ActorSheet {
})
html.find('.edit-item-data').change(ev => {
const li = $(ev.currentTarget).parents(".item")
let itemId = li.data("item-id")
let itemType = li.data("item-type")
let itemId = li.data("item-id")
let itemType = li.data("item-type")
let itemField = $(ev.currentTarget).data("item-field")
let dataType = $(ev.currentTarget).data("dtype")
let value = ev.currentTarget.value
@@ -125,17 +151,17 @@ export class HeritiersActorSheet extends ActorSheet {
let value = Number($(event.currentTarget).data("adversite-value"))
this.actor.incDecAdversite(adv, value)
})
html.find('.quantity-modify').click(event => {
const li = $(event.currentTarget).parents(".item")
const value = Number($(event.currentTarget).data("quantite-value"))
this.actor.incDecQuantity( li.data("item-id"), value );
this.actor.incDecQuantity(li.data("item-id"), value);
})
html.find('.roll-initiative').click((event) => {
this.actor.rollInitiative()
})
html.find('.roll-carac').click((event) => {
const key = $(event.currentTarget).data("key")
this.actor.rollCarac(key, false)
@@ -143,60 +169,76 @@ export class HeritiersActorSheet extends ActorSheet {
html.find('.roll-rang').click((event) => {
const key = $(event.currentTarget).data("rang-key")
this.actor.rollRang(key, false)
})
})
html.find('.roll-root-competence').click((event) => {
const compKey = $(event.currentTarget).data("attr-key")
this.actor.rollRootCompetence(compKey)
})
html.find('.roll-competence').click((event) => {
const li = $(event.currentTarget).parents(".item")
let compId = li.data("item-id")
let compId = li.data("item-id")
this.actor.rollCompetence(compId)
})
html.find('.roll-sort').click((event) => {
const li = $(event.currentTarget).parents(".item")
let sortId = li.data("item-id")
this.actor.rollSort(sortId)
})
html.find('.roll-attaque-arme').click((event) => {
const li = $(event.currentTarget).parents(".item")
let armeId = li.data("item-id")
let armeId = li.data("item-id")
this.actor.rollAttaqueArme(armeId)
})
html.find('.roll-attaque-brutale-arme').click((event) => {
const li = $(event.currentTarget).parents(".item")
let armeId = li.data("item-id")
let armeId = li.data("item-id")
this.actor.rollAttaqueBrutaleArme(armeId)
})
})
html.find('.roll-attaque-charge-arme').click((event) => {
const li = $(event.currentTarget).parents(".item")
let armeId = li.data("item-id")
let armeId = li.data("item-id")
this.actor.rollAttaqueChargeArme(armeId)
})
html.find('.roll-assomer-arme').click((event) => {
const li = $(event.currentTarget).parents(".item")
let armeId = li.data("item-id")
let armeId = li.data("item-id")
this.actor.rollAssomerArme(armeId)
})
html.find('.roll-pouvoir').click((event) => {
const li = $(event.currentTarget).parents(".item")
let pouvoirId = li.data("item-id")
this.actor.rollPouvoir(pouvoirId)
})
html.find('.dialog-recup-usage').click((event) => {
this.dialogRecupUsage()
})
html.find('.item-add').click((event) => {
const itemType = $(event.currentTarget).data("type")
if (itemType == "sort") {
// Get data-sort-competence
let sortCompetence = $(event.currentTarget).data("sort-competence");
if (sortCompetence) {
this.actor.createEmbeddedDocuments('Item', [{ name: `Nouveau ${itemType} de ${sortCompetence}`, type: itemType, system: { competence: sortCompetence } }], { renderSheet: true })
return
}
}
this.actor.createEmbeddedDocuments('Item', [{ name: `Nouveau ${itemType}`, type: itemType }], { renderSheet: true })
})
html.find('.lock-unlock-sheet').click((event) => {
this.options.editScore = !this.options.editScore;
this.render(true);
});
});
html.find('.item-equip').click(ev => {
const li = $(ev.currentTarget).parents(".item");
this.actor.equipItem( li.data("item-id") );
this.render(true);
this.actor.equipItem(li.data("item-id"));
this.render(true);
});
}
/* -------------------------------------------- */
/** @override */
setPosition(options = {}) {

View File

@@ -17,8 +17,8 @@ export class HeritiersActor extends Actor {
/**
* Override the create() function to provide additional SoS functionality.
*
* This overrided create() function adds initial items
* Namely: Basic skills, money,
* This overrided create() function adds initial items
* Namely: Basic skills, money,
*
* @param {Object} data Barebones actor data which this function adds onto.
* @param {Object} options (Unused) Additional options which customize the creation workflow.
@@ -41,7 +41,7 @@ export class HeritiersActor extends Actor {
const skills = await HeritiersUtility.loadCompendium("fvtt-les-heritiers.competences")
data.items = []
for (let skill of skills) {
if (skill.system.categorie == "utile") {
if (skill.system.categorie == "utile" && skill.system.profil != "magie") {
data.items.push(skill.toObject())
}
}
@@ -54,7 +54,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
prepareArme(arme) {
arme = duplicate(arme)
arme = foundry.utils.duplicate(arme)
arme.system.isMelee = HeritiersUtility.isArmeMelee(arme)
return arme
}
@@ -73,7 +73,7 @@ export class HeritiersActor extends Actor {
getOtherMeleeWeapons(excludeArme) {
let armes = []
for (let arme of this.items) {
if ( HeritiersUtility.isArmeMelee(arme) && arme.id != excludeArme._id) {
if (HeritiersUtility.isArmeMelee(arme) && arme.id != excludeArme._id) {
armes.push(this.prepareArme(arme))
}
}
@@ -86,7 +86,7 @@ export class HeritiersActor extends Actor {
/* ----------------------- --------------------- */
addMember(actorId) {
let members = duplicate(this.system.members)
let members = foundry.utils.duplicate(this.system.members)
members.push({ id: actorId })
this.update({ 'system.members': members })
}
@@ -135,13 +135,102 @@ export class HeritiersActor extends Actor {
return this.getItemSorted(["profil"])
}
getPouvoirs() {
return this.getItemSorted(["pouvoir"])
let pouvoirs = []
for (let item of this.items) {
if (item.type == "pouvoir") {
let itemObj = foundry.utils.duplicate(item)
itemObj.maxUsage = this.getPouvoirUsageMax(item)
pouvoirs.push(itemObj)
}
}
HeritiersUtility.sortArrayObjectsByName(pouvoirs)
return pouvoirs
}
getSorts() {
return this.getItemSorted(["sort"])
}
getCompetencesMagie() {
let comp = []
for (let item of this.items) {
if (item.type == "competence" && item.system.profil == "magie") {
let itemObj = foundry.utils.duplicate(item)
comp.push(itemObj)
}
}
HeritiersUtility.sortArrayObjectsByName(comp)
return comp
}
prepareMagie() {
let magieList = []
for (let item of this.items) {
if (item.type == "competence" && item.system.profil == "magie") {
let magie = {}
magie.name = item.name
magie.competence = foundry.utils.duplicate(item)
magie.rang = Math.round(item.system.niveau / 2);
magie.rangGenericName = game.system.lesheritiers.config.rangName[magie.rang];
console.log("Magie", item.name, item.system.niveau, magie.rang, magie.rangGenericName)
//magie.rangSpecificName = game.system.lesheritiers.config.rangNameSpecific[item.name][magie.rangGenericName];
magie.sorts = {}
if (item.name == "Magie du Clan") {
magie.sorts = {
"soufflecombat": {
1: { nomNiveau: magie.competence.system.nomniveausouffle.soufflecombat["1"], sorts: [] },
2: { nomNiveau: magie.competence.system.nomniveausouffle.soufflecombat["2"], sorts: [] },
3: { nomNiveau: magie.competence.system.nomniveausouffle.soufflecombat["3"], sorts: [] },
4: { nomNiveau: magie.competence.system.nomniveausouffle.soufflecombat["4"], sorts: [] }
},
"soufflemouvement": {
1: { nomNiveau: magie.competence.system.nomniveausouffle.soufflemouvement["1"], sorts: [] },
2: { nomNiveau: magie.competence.system.nomniveausouffle.soufflemouvement["2"], sorts: [] },
3: { nomNiveau: magie.competence.system.nomniveausouffle.soufflemouvement["3"], sorts: [] },
4: { nomNiveau: magie.competence.system.nomniveausouffle.soufflemouvement["4"], sorts: [] }
},
"souffleesprit": {
1: { nomNiveau: magie.competence.system.nomniveausouffle.souffleesprit["1"], sorts: [] },
2: { nomNiveau: magie.competence.system.nomniveausouffle.souffleesprit["2"], sorts: [] },
3: { nomNiveau: magie.competence.system.nomniveausouffle.souffleesprit["3"], sorts: [] },
4: { nomNiveau: magie.competence.system.nomniveausouffle.souffleesprit["4"], sorts: [] }
}
}
for (let sort of this.items) {
if (sort.type == "sort" && sort.system.competence == item.name) {
let sortObj = foundry.utils.duplicate(sort)
sortObj.sdValue = HeritiersUtility.getSDSortValue(Number(sort.system.niveau))
if (!magie.sorts[sort.system?.souffle]) {
console.warn("Sort with unknown souffle ", sort.system.souffle, sort)
continue
}
magie.sorts[sort.system.souffle][Number(sort.system.niveau)].sorts.push(sortObj)
}
}
} else {
magie.sorts = {
1: { nomNiveau: magie.competence.system.nomniveau["1"], sorts: [] },
2: { nomNiveau: magie.competence.system.nomniveau["2"], sorts: [] },
3: { nomNiveau: magie.competence.system.nomniveau["3"], sorts: [] },
4: { nomNiveau: magie.competence.system.nomniveau["4"], sorts: [] }
}
for (let sort of this.items) {
if (sort.type == "sort" && sort.system.competence == item.name) {
let sortObj = foundry.utils.duplicate(sort)
sortObj.sdValue = HeritiersUtility.getSDSortValue(Number(sort.system.niveau))
magie.sorts[Number(sort.system.niveau)].sorts.push(sortObj)
}
}
}
magieList.push(magie)
}
}
return magieList
}
/* -------------------------------------------- */
getSkills() {
let comp = []
for (let item of this.items) {
item = duplicate(item)
item = foundry.utils.duplicate(item)
if (item.type == "competence") {
comp.push(item)
}
@@ -152,7 +241,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
prepareUtileSkill(item) {
let specList = []
if (item && item.system.categorie && item.system.categorie == "utile") {
if (item?.system?.categorie == "utile") {
for (let spec of item.system.specialites) {
specList.push(spec.name)
}
@@ -161,6 +250,28 @@ export class HeritiersActor extends Actor {
item.specList = specList.toString()
}
/* -------------------------------------------- */
organizeMagicSkills() {
let comp = {}
for (let key in game.system.lesheritiers.config.competenceProfil) {
if (game.system.lesheritiers.config.competenceProfil[key].kind == "magical")
comp[key] = { skills: [], niveau: 0 }
}
for (let item of this.items) {
if (item.type == "competence") {
if (item.system.categorie == "utile" && comp[item.system.profil]) {
this.prepareUtileSkill(item)
comp[item.system.profil].skills.push(item)
}
}
}
for (let key in comp) {
HeritiersUtility.sortArrayObjectsByName(comp[key].skills)
}
return Object.fromEntries(Object.entries(comp).sort())
}
/* -------------------------------------------- */
organizeUtileSkills(kind = "mental") {
let comp = {}
@@ -182,6 +293,7 @@ export class HeritiersActor extends Actor {
}
return Object.fromEntries(Object.entries(comp).sort())
}
/* -------------------------------------------- */
organizeContacts() {
let contactList = {}
@@ -248,9 +360,39 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
async prepareData() {
let pvMax = (this.system.caracteristiques.con.rang * 3) + 9 + this.system.pv.mod
if (this.system.pv.max != pvMax) {
this.update({ 'system.pv.max': pvMax })
}
if (this.system.biodata.magie || this.type == "pnj") {
let pointsAmes = this.system.caracteristiques.esp.rang + this.system.caracteristiques.san.rang + this.getMaxRangMagie()
if (this.system.magie.pointsame.max != pointsAmes) {
this.update({ 'system.magie.pointsame.max': pointsAmes })
}
}
super.prepareData();
}
/* -------------------------------------------- */
getMaxRangMagie() {
let niv = 0
let bestMagie
for (let comp of this.items) {
if (comp.type == "competence" && comp.system.profil == "magie") {
if (comp.system.niveau > niv) {
bestMagie = comp
niv = comp.system.niveau
}
}
}
if (bestMagie) {
return Math.round(bestMagie.system.niveau / 2)
}
return 0
}
/* -------------------------------------------- */
prepareDerivedData() {
@@ -270,7 +412,7 @@ export class HeritiersActor extends Actor {
getItemById(id) {
let item = this.items.find(item => item.id == id);
if (item) {
item = duplicate(item)
item = foundry.utils.duplicate(item)
}
return item;
}
@@ -278,7 +420,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
async equipItem(itemId) {
let item = this.items.find(item => item.id == itemId)
if (item && item.system) {
if (item?.system) {
let update = { _id: item.id, "system.equipped": !item.system.equipped }
await this.updateEmbeddedDocuments('Item', [update]); // Updates one EmbeddedEntity
}
@@ -304,12 +446,12 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
getPvMalus() {
if (this.system.pv.value > 0) {
if (this.system.pv.value < this.system.pv.max / 2) {
return { name: "Santé", value: -1 }
}
if (this.system.pv.value < 5) {
return { name: "Santé", value: -2 }
}
if (this.system.pv.value < this.system.pv.max / 2) {
return { name: "Santé", value: -1 }
}
return { name: "Santé", value: 0 }
}
return { name: "Moribond(e)", value: -50 }
@@ -328,7 +470,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
getCarac(attrKey) {
return duplicate(this.system.caracteristiques)
return foundry.utils.duplicate(this.system.caracteristiques)
}
/* -------------------------------------------- */
@@ -339,7 +481,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
async equipGear(equipmentId) {
let item = this.items.find(item => item.id == equipmentId);
if (item && item.system.data) {
if (item?.system) {
let update = { _id: item.id, "system.equipped": !item.system.equipped };
await this.updateEmbeddedDocuments('Item', [update]); // Updates one EmbeddedEntity
}
@@ -349,13 +491,13 @@ export class HeritiersActor extends Actor {
getSubActors() {
let subActors = [];
for (let id of this.system.subactors) {
subActors.push(duplicate(game.actors.get(id)));
subActors.push(foundry.utils.duplicate(game.actors.get(id)));
}
return subActors;
}
/* -------------------------------------------- */
async addSubActor(subActorId) {
let subActors = duplicate(this.system.subactors);
let subActors = foundry.utils.duplicate(this.system.subactors);
subActors.push(subActorId);
await this.update({ 'system.subactors': subActors });
}
@@ -377,11 +519,12 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
async incDecAdversite(adv, incDec = 0) {
let adversite = duplicate(this.system.adversite)
let adversite = foundry.utils.duplicate(this.system.adversite)
adversite[adv] += Number(incDec)
adversite[adv] = Math.max(adversite[adv], 0)
this.update({ 'system.adversite': adversite })
}
/* -------------------------------------------- */
async incDecQuantity(objetId, incDec = 0) {
let objetQ = this.items.get(objetId)
@@ -424,7 +567,7 @@ export class HeritiersActor extends Actor {
/* -------------------------------------------- */
async setPredilectionUsed(compId, predIdx) {
let comp = this.items.get(compId)
let pred = duplicate(comp.system.predilections)
let pred = foundry.utils.duplicate(comp.system.predilections)
pred[predIdx].used = true
await this.updateEmbeddedDocuments('Item', [{ _id: compId, 'system.predilections': pred }])
}
@@ -446,7 +589,7 @@ export class HeritiersActor extends Actor {
}
if (arme.system.totalDefensif > maxDef) {
maxDef = arme.system.totalDefensif
bestArme = duplicate(arme)
bestArme = foundry.utils.duplicate(arme)
}
}
return bestArme
@@ -461,7 +604,7 @@ export class HeritiersActor extends Actor {
for (let auto of talent.system.automations) {
if (auto.eventtype === "prepare-roll") {
if (auto.competence.toLowerCase() == competence.name.toLowerCase()) {
talent = duplicate(talent)
talent = foundry.utils.duplicate(talent)
talent.system.bonus = auto.bonus
talent.system.baCost = auto.baCost
talents.push(talent)
@@ -501,15 +644,20 @@ export class HeritiersActor extends Actor {
incDecTricherie(value) {
let tricherie = this.system.rang.tricherie
tricherie.value += value
if (tricherie.value < 0 || tricherie.value > tricherie.max) {
ui.notifications.warn("Pas assez de points de Tricherie !")
return false
}
tricherie.value = Math.max(tricherie.value, 0)
tricherie.value = Math.min(tricherie.value, tricherie.max)
this.update({ 'system.rang.tricherie': tricherie })
return true
}
/* -------------------------------------------- */
getPireCompetence(compName1, compName2) {
let comp1 = this.items.find( it => it.name == compName1)
let comp2 = this.items.find( it => it.name == compName2)
if ( comp1 && comp2 ) {
let comp1 = this.items.find(it => it.name == compName1)
let comp2 = this.items.find(it => it.name == compName2)
if (comp1 && comp2) {
if (comp1.system.niveau > comp2.system.niveau) {
return comp1
} else {
@@ -518,6 +666,7 @@ export class HeritiersActor extends Actor {
}
return undefined
}
/* -------------------------------------------- */
getCommonRollData(compId = undefined, compName = undefined) {
let rollData = HeritiersUtility.getBasicRollData()
@@ -533,16 +682,17 @@ export class HeritiersActor extends Actor {
rollData.useTricherie = false
rollData.useSpecialite = false
rollData.useHeritage = false
rollData.pouvoirPointsUsage = 1
rollData.rulesMalus.push(this.getPvMalus())
if (compId) {
rollData.competence = duplicate(this.items.get(compId) || {})
rollData.competence = foundry.utils.duplicate(this.items.get(compId) || {})
this.prepareUtileSkill(rollData.competence)
rollData.actionImg = rollData.competence?.img
}
if (compName) {
rollData.competence = duplicate(this.items.find(item => item.name.toLowerCase() == compName.toLowerCase()) || {})
if (rollData.competence && rollData.competence.name) {
rollData.competence = foundry.utils.duplicate(this.items.find(item => item.name.toLowerCase() == compName.toLowerCase()) || {})
if (rollData.competence?.name) {
this.prepareUtileSkill(rollData.competence)
rollData.actionImg = rollData.competence?.img
} else {
@@ -590,7 +740,6 @@ export class HeritiersActor extends Actor {
async rollRootCompetence(compKey) {
let rollData = this.getCommonRollData()
rollData.mode = "competence"
console.log("Compkey", compKey)
rollData.competence = { name: this.system.competences[compKey].label, system: { niveau: this.system.competences[compKey].niveau } }
console.log("RollDatra", rollData)
let rollDialog = await HeritiersRollDialog.create(this, rollData)
@@ -606,15 +755,89 @@ export class HeritiersActor extends Actor {
rollDialog.render(true)
}
/* -------------------------------------------- */
inDecCarac(key, incDec) {
let carac = this.system.caracteristiques[key]
carac.value += incDec
if (carac.value < 0 || carac.value > carac.rang) {
ui.notifications.warn("Pas assez de points dans cette caractéristique ou rang max atteint !")
return false
}
carac.value = Math.max(carac.value, 0)
carac.value = Math.min(carac.value, carac.rang)
this.update({ [`system.caracteristiques.${key}`]: carac })
return true
}
/* -------------------------------------------- */
async rollSort(sortId) {
let sort = this.items.get(sortId)
let comp = this.items.find(it => it.type == "competence" && it.name.toLowerCase() == sort.system.competence.toLowerCase())
if (!comp) {
ui.notifications.warn("Compétence de magie associée non trouvée !")
return
}
if (sort.system.informatif) {
if (sort.system.texteinformatif) {
let chatData = { user: game.user.id, speaker: { actor: this, alias: this.name }, content: `<div class="heritiers-informatif-sort"><h4>Sort informatif !</h4>${sort.system.texteinformatif}</div>` }
ChatMessage.create(chatData)
} else {
ui.notifications.info("Ce sort est uniquement informatif et ne peut pas être lancé.")
}
return
}
let rollData = this.getCommonRollData(comp.id)
rollData.mode = "sort"
rollData.sort = foundry.utils.duplicate(sort)
rollData.sdValue = HeritiersUtility.getSDSortValue(Number(sort.system.niveau))
if (Number(sort.system.sdspecial) && Number(sort.system.sdspecial) > 0) {
rollData.sdValue = Number(sort.system.sdspecial)
}
rollData.sortPointsAme = Number(sort.system.niveau)
rollData.totalEsprit = 1
if (sort.system.competence == "Grand Langage") {
rollData.sortPointsAme *= 2
rollData.totalEsprit = Math.floor((rollData.sortPointsAme) / 3)
}
if (rollData.sortPointsAme > this.system.magie.pointsame.value) {
// Vérifier si au moins 1 point d'Esprit est disponible
if (this.system.caracteristiques.esp.value <= rollData.totalEsprit) {
ui.notifications.warn(`Pas assez de Points d'Esprit ni de Points d'Ame pour lancer ce sort (requis: ${rollData.totalEsprit}, disponible: ${this.system.caracteristiques.esp.value})`)
return
} else {
rollData.spendEsprit = true
ui.notifications.warn(`Vous n'avez pas assez de Points d'Ame pour lancer ce sort (requis: ${rollData.sortPointsAme}, disponible: ${this.system.magie.pointsame.value}).`)
ui.notifications.warn(`${rollData.totalEsprit} Points d'Esprit seront utilisés à la place si vous effectuez le lancer.`)
}
}
if (sort.system.carac2 != "none") {
// get the best carac between carac1 and carac2
if (this.system.caracteristiques[sort.system.carac1].value > this.system.caracteristiques[sort.system.carac2].value) {
rollData.caracKey = sort.system.carac1
} else {
rollData.caracKey = sort.system.carac2
}
rollData.caracMessage = "Ce sort peut être lancé avec " + game.system.lesheritiers.config.caracList[sort.system.carac1] + " ou " + game.system.lesheritiers.config.caracList[sort.system.carac2] + ". La meilleure caractéristique a été selectionnée."
} else {
rollData.caracKey = sort.system.carac1
}
console.log("RollData", rollData)
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
/* -------------------------------------------- */
async rollAttaqueArme(armeId) {
let arme = this.items.get(armeId)
if (arme) {
arme = duplicate(arme)
arme = foundry.utils.duplicate(arme)
arme.system.isMelee = HeritiersUtility.isArmeMelee(arme)
let competenceName = "Tir"
let key = "prec"
if ( arme.system.isMelee) {
if (arme.system.isMelee) {
competenceName = "Mêlée"
key = "agi"
}
@@ -624,7 +847,7 @@ export class HeritiersActor extends Actor {
rollData.arme = arme
rollData.mode = "arme"
rollData.armes = this.getOtherMeleeWeapons(arme)
if (rollData.defenderTokenId && arme.system.isMelee ) {
if (rollData.defenderTokenId && arme.system.isMelee) {
rollData.cacheDifficulte = true
}
console.log(">>>> ARME", rollData)
@@ -643,10 +866,10 @@ export class HeritiersActor extends Actor {
let rollData = this.getCommonRollData(undefined, competenceName)
rollData.carac = this.system.caracteristiques[key]
rollData.caracKey = key
rollData.arme = duplicate(arme)
rollData.arme = foundry.utils.duplicate(arme)
rollData.mode = "attaquebrutale"
rollData.armes = this.getOtherMeleeWeapons(arme)
rollData.rulesMalus.push({ name: "Attaque brutale", value: -2 } )
rollData.rulesMalus.push({ name: "Attaque brutale", value: -2 })
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
@@ -661,14 +884,14 @@ export class HeritiersActor extends Actor {
let rollData = this.getCommonRollData(undefined, pireCompetence.name)
rollData.carac = this.system.caracteristiques[key]
rollData.caracKey = key
rollData.arme = duplicate(arme)
rollData.arme = foundry.utils.duplicate(arme)
rollData.armes = this.getOtherMeleeWeapons(arme)
rollData.mode = "attaquecharge"
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
}
/* -------------------------------------------- */
async rollAssomerArme(armeId) {
let arme = this.items.get(armeId)
@@ -678,7 +901,7 @@ export class HeritiersActor extends Actor {
let rollData = this.getCommonRollData(undefined, competenceName)
rollData.carac = this.system.caracteristiques["agi"]
rollData.caracKey = "agi"
rollData.arme = duplicate(arme)
rollData.arme = foundry.utils.duplicate(arme)
rollData.mode = "assommer"
if (rollData.defenderTokenId) {
rollData.cacheDifficulte = true
@@ -688,22 +911,153 @@ export class HeritiersActor extends Actor {
}
}
/* -------------------------------------------- */
pouvoirPassifDialog(pouvoir) {
let rollData = this.getCommonRollData()
rollData.pouvoir = pouvoir
rollData.mode = "pouvoirpassif"
rollData.pouvoirPointsUsage = 0
rollData.noRoll = true
let d = new Dialog({
title: "Activer le pouvoir passif " + pouvoir.name,
content: "<p>Choisissez le nombre de Points d'Usage</p>",
buttons: {
one: {
icon: '<i class="fas fa-check"></i>',
label: "1 Point d'Usage",
callback: () => {
rollData.pouvoirPointsUsage = 1;
HeritiersUtility.rollHeritiers(rollData);
}
},
two: {
icon: '<i class="fas fa-check"></i>',
label: "2 Points d'Usage",
callback: () => {
rollData.pouvoirPointsUsage = 2;
HeritiersUtility.rollHeritiers(rollData);
}
},
three: {
icon: '<i class="fas fa-check"></i>',
label: "3 Points d'Usage",
callback: () => {
rollData.pouvoirPointsUsage = 3;
HeritiersUtility.rollHeritiers(rollData);
}
},
four: {
icon: '<i class="fas fa-check"></i>',
label: "4 Points d'Usage",
callback: () => {
rollData.pouvoirPointsUsage = 4;
HeritiersUtility.rollHeritiers(rollData);
}
},
close: {
icon: '<i class="fas fa-times"></i>',
label: "Annuler",
callback: () => {
}
}
},
default: "one",
render: html => console.log("Pouvoir passif"),
close: html => console.log("No option")
});
d.render(true);
}
/* -------------------------------------------- */
async rollPouvoir(pouvoirId) {
let pouvoir = this.items.get(pouvoirId)
if (pouvoir) {
let rollData = this.getCommonRollData(undefined, undefined)
if (pouvoir.system.feeriemasque != "autre") {
rollData.pouvoirBase = duplicate(this.system.rang[pouvoir.system.feeriemasque.toLowerCase()])
rollData.pouvoirBase.label = "Féerie"
rollData.carac = duplicate(this.system.caracteristiques[pouvoir.system.carac])
rollData.caracKey = pouvoir.system.carac
if (pouvoir.system.pouvoirtype == "passif") {
this.pouvoirPassifDialog(pouvoir)
return
}
rollData.pouvoir = duplicate(pouvoir)
let rollData = this.getCommonRollData(undefined, undefined)
rollData.pouvoirMaxUsage = this.getPouvoirUsageMax(pouvoir)
rollData.pouvoir = foundry.utils.duplicate(pouvoir)
rollData.mode = "pouvoir"
if (pouvoir.system.feeriemasque != "autre") {
rollData.pouvoirBase = foundry.utils.duplicate(this.system.rang[pouvoir.system.feeriemasque.toLowerCase()])
rollData.pouvoirBase.label = "Féerie"
if (pouvoir.system.istest && !pouvoir.system.carac) {
ui.notifications.warn("Le pouvoir actif " + pouvoir.name + " n'a pas de caractéristique associée")
}
if (pouvoir.system.istest) {
rollData.carac = foundry.utils.duplicate(this.system.caracteristiques[pouvoir.system.carac])
rollData.caracKey = pouvoir.system.carac
} else {
rollData.noRoll = true
HeritiersUtility.rollHeritiers(rollData);
return;
//this.incDecPointsUsage(pouvoir.id, -rollData.pouvoirPointsUsage)
//ui.notifications.warn("Le pouvoir actif " + pouvoir.name + " a été utilisé, dépense de " + pouvoirPointsUsage + " points d'usage")
}
}
let rollDialog = await HeritiersRollDialog.create(this, rollData)
rollDialog.render(true)
}
}
/* -------------------------------------------- */
incDecPointsAme(value) {
let newValue = this.system.magie.pointsame.value + value
newValue = Math.max(newValue, 0)
newValue = Math.min(newValue, this.system.magie.pointsame.max)
this.update({ 'system.magie.pointsame.value': newValue })
}
/* -------------------------------------------- */
incDecPV(value) {
let newValue = this.system.pv.value + value
newValue = Math.max(newValue, 0)
newValue = Math.min(newValue, this.system.pv.max)
this.update({ 'system.pv.value': newValue })
}
/* -------------------------------------------- */
incDecPointsUsage(pouvoirId, value) {
let pouvoir = this.items.get(pouvoirId)
let newValue = pouvoir.system.pointsusagecourant + value
newValue = Math.max(newValue, 0)
newValue = Math.min(newValue, this.getPouvoirUsageMax(pouvoir))
this.updateEmbeddedDocuments('Item', [{ _id: pouvoirId, 'system.pointsusagecourant': newValue }])
}
/* -------------------------------------------- */
getPouvoirUsage(pouvoirId) {
let pouvoir = this.items.get(pouvoirId)
return pouvoir.system.pointsusagecourant
}
/* -------------------------------------------- */
getPouvoirUsageMax(pouvoir) {
if (pouvoir.system.masquetype == "masque") {
return this.system.rang.masque.value
}
return this.system.rang.feerie.value
}
/* -------------------------------------------- */
recupUsage(value) {
let updates = []
for (let pouvoir of this.items) {
if (pouvoir.type == "pouvoir") {
let newValue = pouvoir.system.pointsusagecourant + value
newValue = Math.max(newValue, 0)
newValue = Math.min(newValue, this.getPouvoirUsageMax(pouvoir))
updates.push({ _id: pouvoir.id, 'system.pointsusagecourant': newValue })
}
}
if (updates.length > 0) {
this.updateEmbeddedDocuments('Item', updates)
}
}
}

View File

@@ -12,25 +12,26 @@ export const HERITIERS_CONFIG = {
"san": "Sang-Froid"
},
competenceCategorie : {
competenceCategorie: {
"utile": "Utile",
"futile": "Futile"
},
contactType: {
contact: "Contact",
contact: "Contact",
allie: "Allié",
ennemi: "Ennemi",
interet: "Personne d'interêt"
},
competenceProfil : {
"aventurier": {kind: "physical", name: "Aventurier"},
"roublard": {kind: "physical",name: "Roublard"},
"combattant": {kind: "physical",name:"Combattant"},
"erudit": {kind: "mental",name:"Erudit"},
"savant": {kind: "mental",name:"Savant"},
"gentleman": {kind: "mental",name:"Gentleman"}
competenceProfil: {
"aventurier": { kind: "physical", name: "Aventurier" },
"roublard": { kind: "physical", name: "Roublard" },
"combattant": { kind: "physical", name: "Combattant" },
"erudit": { kind: "mental", name: "Erudit" },
"savant": { kind: "mental", name: "Savant" },
"gentleman": { kind: "mental", name: "Gentleman" },
"magie": { kind: "magical", name: "Magie" },
},
baseTestPouvoir: {
"feerie": "Féerie",
@@ -52,7 +53,7 @@ export const HERITIERS_CONFIG = {
},
statutMasque: {
"masque": "Masqué",
"demasque":"Démasqué"
"demasque": "Démasqué"
},
niveauPouvoir: {
"normal": "Normal",
@@ -65,32 +66,32 @@ export const HERITIERS_CONFIG = {
},
seuilsDifficulte: {
"-1": "Aucun/Non applicable",
"5": "Enfantine",
"6": "Triviale",
"7": "Moins Triviale",
"8": "Aisée",
"7": "Moins Aisée",
"10": "Normale",
"11": "Moins Normale",
"12": "Compliquée",
"13": "Plus Compliquée",
"14": "Difficile",
"15": "Plus Difficile",
"16": "Très Difficile",
"17": "Très Très Difficile",
"18": "Critique",
"19": "Plus Critique",
"20": "Insurmontable",
"20": "Très Insurmontable",
"22": "Surhumaine",
"23": "Très Surhumaine",
"24": "Epique",
"25": "Plus Epique",
"26": "Légendaire",
"26": "Très Légendaire",
"28": "Mythique",
"29": "Plus Mythique",
"30": "Divine"
"5": "Enfantine (5)",
"6": "Triviale (6)",
"7": "Moins Triviale (7)",
"8": "Aisée (8)",
"9": "Moins Aisée (9)",
"10": "Normale (10)",
"11": "Moins Normale (11)",
"12": "Compliquée (12)",
"13": "Plus Compliquée (13)",
"14": "Difficile (14)",
"15": "Plus Difficile (15)",
"16": "Très Difficile (16)",
"17": "Très Très Difficile (17)",
"18": "Critique (18)",
"19": "Plus Critique (19)",
"20": "Insurmontable (20)",
"21": "Très Insurmontable (21)",
"22": "Surhumaine (22)",
"23": "Très Surhumaine (23)",
"24": "Epique (24)",
"25": "Plus Epique (25)",
"26": "Légendaire (26)",
"27": "Très Légendaire (27)",
"28": "Mythique (28)",
"29": "Plus Mythique (29)",
"30": "Divine (30)"
},
attaqueCible: {
@@ -99,8 +100,8 @@ export const HERITIERS_CONFIG = {
"main": "Main",
"tete": "Tête/Coeur"
},
categorieArme : {
categorieArme: {
"trait": "Arme de trait",
"poing": "Arme de poing",
"epaule": "Arme d'épaule",
@@ -108,7 +109,7 @@ export const HERITIERS_CONFIG = {
"blanche": "Arme blanche",
"improvise": "Arme improvisée",
"explosif": "Explosif"
},
},
typeArme: {
"naturelle": "Arme naturelle",
"trait": "Trait",
@@ -130,13 +131,13 @@ export const HERITIERS_CONFIG = {
"controlee": "Contrôlée (C)",
"prohibee": "Prohibée (P)"
},
armeDissimulation :{
armeDissimulation: {
"tresfacile": "Très facile (TF)",
"facile": "Facile (F)",
"difficile": "Difficile (D)",
"impossible": "Impossible (I)"
},
typeProtection : {
typeProtection: {
"balle": "Protège ds balles",
"melee": "Protège en mélée",
"tout": "Tout type de dégats"
@@ -145,7 +146,137 @@ export const HERITIERS_CONFIG = {
"traditionnelle": "Traditionnelle",
"moderne": "Moderne",
"orientale": "Orientale"
},
typeContact: {
"contact": "Contact",
"allie": "Allié",
"ennemi": "Ennemi",
"interet": "Personne d'interêt"
},
niveauContact: {
"1": "1",
"2": "2",
"3": "3",
},
pointsUsageList: {
"1": "1",
"2": "2",
"3": "3",
"4": "4",
},
attaquePlusieursList: {
"0": "0",
"1": "+1",
"2": "+2",
},
attaque2ArmesListe: [
{ value: "0", label: "Aucun" },
{ value: "-4", label: "Deux armes à 1 main" },
{ value: "-2", label: "Deux armes naturelles" },
{ value: "-2", label: "Avec spécialisation \"Mauvaise Main\"" }
],
typeProfil: {
"mineur": "Mineur",
"majeur": "Majeur",
},
bonusMalusContext: [
{ value: "-6", label: "-6" },
{ value: "-5", label: "-5" },
{ value: "-4", label: "-4" },
{ value: "-3", label: "-3" },
{ value: "-2", label: "-2" },
{ value: "-1", label: "-1" },
{ value: "0", label: "0" },
{ value: "1", label: "+1" },
{ value: "2", label: "+2" },
{ value: "3", label: "+3" },
{ value: "4", label: "+4" },
{ value: "5", label: "+5" },
{ value: "6", label: "+6" }
],
listNiveauSort: {
"1": "1",
"2": "2",
"3": "3",
"4": "4"
},
listRangSort: {
"1": "1",
"2": "2",
"3": "3",
"4": "4",
"5": "5",
"6": "6",
"7": "7"
},
listNiveau: {
"0": "0",
"1": "1",
"2": "2",
"3": "3",
"4": "4",
"5": "5",
"6": "6",
"7": "7",
"8": "8",
"9": "9",
"10": "10"
},
rangName: [
"Novice",
"Novice",
"Adepte",
"Maître",
"Grand Maître"
],
rangNameSpecific: {
"Druidisme": {
"Novice": "Eubage",
"Adepte": "Saronide",
"Maître": "Ovate",
"Grand Maître": "Archidruide"
},
"Faëomancie": {
"Novice": "Marmiton",
"Adepte": "Queux",
"Maître": "Chef",
"Grand Maître": "Maître-queux"
},
"Nécromancie": {
"Novice": "Inexpertus",
"Adepte": "Discipulus",
"Maître": "Dominus",
"Grand Maître": "Magister"
},
"Necromancie": {
"Novice": "Inexpertus",
"Adepte": "Discipulus",
"Maître": "Dominus",
"Grand Maître": "Magister"
},
"Magie du Clan": {
"Novice": "Apprenti",
"Adepte": "Disciple",
"Maître": "Maître",
"Grand Maître": "Éminence"
},
"Théurgie": {
"Novice": "Frère",
"Adepte": "Père",
"Maître": "Saint",
"Grand Maître": "Apôtre"
},
"Grand Langage": {
"Novice": "Éveillé",
"Adepte": "Initié",
"Maître": "Sage",
"Grand Maître": "Docteur"
}
},
soufflesMagieDuClan: {
"soufflecombat": "Souffle du Combat",
"soufflemouvement": "Souffle du Mouvement",
"souffleesprit": "Souffle de l'Esprit"
}
}

View File

@@ -1,25 +0,0 @@
/**
* Extend the basic ActorSheet with some very simple modifications
* @extends {ActorSheet}
*/
import { HeritiersActorSheet } from "./heritiers-actor-sheet.js";
import { HeritiersUtility } from "./heritiers-utility.js";
/* -------------------------------------------- */
export class HeritiersCreatureSheet extends HeritiersActorSheet {
/** @override */
static get defaultOptions() {
return mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "actor"],
template: "systems/fvtt-les-heritiers/templates/creature-sheet.html",
width: 640,
height: 720,
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "stats" }],
dragDrop: [{ dragSelector: ".item-list .item", dropSelector: null }],
editScore: false
})
}
}

View File

@@ -4,18 +4,18 @@ import { HeritiersUtility } from "./heritiers-utility.js";
* Extend the basic ItemSheet with some very simple modifications
* @extends {ItemSheet}
*/
export class HeritiersItemSheet extends ItemSheet {
export class HeritiersItemSheet extends foundry.appv1.sheets.ItemSheet {
/** @override */
static get defaultOptions() {
return mergeObject(super.defaultOptions, {
return foundry.utils.mergeObject(super.defaultOptions, {
classes: ["fvtt-les-heritiers", "sheet", "item"],
template: "systems/fvtt-les-heritiers/templates/item-sheet.html",
dragDrop: [{ dragSelector: null, dropSelector: null }],
width: 620,
height: 550,
tabs: [{navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description"}]
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description" }]
});
}
@@ -48,7 +48,7 @@ export class HeritiersItemSheet extends ItemSheet {
/* -------------------------------------------- */
async getData() {
const objectData = duplicate(this.object)
const objectData = foundry.utils.duplicate(this.object)
let formData = {
title: this.title,
id: this.id,
@@ -63,11 +63,24 @@ export class HeritiersItemSheet extends ItemSheet {
owner: this.document.isOwner,
config: game.system.lesheritiers.config,
isArmeMelee: HeritiersUtility.isArmeMelee(this.object),
description: await TextEditor.enrichHTML(this.object.system.description, {async: true}),
description: await foundry.applications.ux.TextEditor.implementation.enrichHTML(this.object.system.description, { async: true }),
mr: (this.object.type == 'specialisation'),
isGM: game.user.isGM
isGM: game.user.isGM,
usageMax: -1
}
// Items specific data
if (this.object.type == 'pouvoir' && this.document.isOwner && this.actor) {
formData.usageMax = this.actor.getPouvoirUsageMax(this.object)
if (this.object.system.pointsusagecourant == -1) {
this.object.system.pointsusagecourant = formData.usageMax
}
}
if (this.object.type == 'sort') {
formData.competencesMagie = HeritiersUtility.getCompetencesMagie()
}
//this.options.editable = !(this.object.origin == "embeddedItem");
console.log("ITEM DATA", formData, this);
return formData;
@@ -87,7 +100,7 @@ export class HeritiersItemSheet extends ItemSheet {
/* -------------------------------------------- */
postItem() {
let chatData = duplicate(HeritiersUtility.data(this.item));
let chatData = foundry.utils.duplicate(HeritiersUtility.data(this.item));
if (this.actor) {
chatData.actor = { id: this.actor.id };
}
@@ -129,55 +142,55 @@ export class HeritiersItemSheet extends ItemSheet {
})
html.find('#add-specialite').click(ev => {
let spec = duplicate(this.object.system.specialites)
spec.push( { name: "Nouvelle Spécialité", id: randomID(16), used: false })
this.object.update( { 'system.specialites': spec })
let spec = foundry.utils.duplicate(this.object.system.specialites)
spec.push({ name: "Nouvelle Spécialité", id: foundry.utils.randomID(16), used: false })
this.object.update({ 'system.specialites': spec })
})
html.find('.delete-specialite').click(ev => {
const li = $(ev.currentTarget).parents(".specialite-item")
let index = li.data("specialite-index")
let spec = duplicate(this.object.system.specialites)
spec.splice(index,1)
this.object.update( { 'system.specialites': spec })
let spec = foundry.utils.duplicate(this.object.system.specialites)
spec.splice(index, 1)
this.object.update({ 'system.specialites': spec })
})
html.find('.edit-specialite').change(ev => {
const li = $(ev.currentTarget).parents(".specialite-item")
let index = li.data("specialite-index")
let spec = duplicate(this.object.system.specialites)
let spec = foundry.utils.duplicate(this.object.system.specialites)
spec[index].name = ev.currentTarget.value
spec[index].id = spec[index].id || randomID(16)
this.object.update( { 'system.specialites': spec })
spec[index].id = spec[index].id || foundry.utils.randomID(16)
this.object.update({ 'system.specialites': spec })
})
html.find('.edit-specialite-description').change(ev => {
const li = $(ev.currentTarget).parents(".specialite-item")
let index = li.data("specialite-index")
let spec = duplicate(this.object.system.specialites)
let spec = foundry.utils.duplicate(this.object.system.specialites)
spec[index].description = ev.currentTarget.value
spec[index].id = spec[index].id || randomID(16)
this.object.update( { 'system.specialites': spec })
})
spec[index].id = spec[index].id || foundry.utils.randomID(16)
this.object.update({ 'system.specialites': spec })
})
html.find('#add-automation').click(ev => {
let autom = duplicate(this.object.system.automations)
autom.push( { eventtype: "on-drop", name: "Automatisation 1", competence: "", minLevel: 0, id: randomID(16) })
this.object.update( { 'system.automations': autom })
let autom = foundry.utils.duplicate(this.object.system.automations)
autom.push({ eventtype: "on-drop", name: "Automatisation 1", competence: "", minLevel: 0, id: foundry.utils.randomID(16) })
this.object.update({ 'system.automations': autom })
})
html.find('.delete-automation').click(ev => {
const li = $(ev.currentTarget).parents(".automation-item")
let index = li.data("automation-index")
let autom = duplicate(this.object.system.automations)
autom.splice(index,1)
this.object.update( { 'system.automations': autom })
let autom = foundry.utils.duplicate(this.object.system.automations)
autom.splice(index, 1)
this.object.update({ 'system.automations': autom })
})
html.find('.automation-edit-field').change(ev => {
let index = $(ev.currentTarget).data("automation-index")
let field = $(ev.currentTarget).data("automation-field")
let auto = duplicate(this.object.system.automations)
let auto = foundry.utils.duplicate(this.object.system.automations)
auto[index][field] = ev.currentTarget.value
auto[index].id = auto[index].id || randomID(16)
this.object.update( { 'system.automations': auto })
})
auto[index].id = auto[index].id || foundry.utils.randomID(16)
this.object.update({ 'system.automations': auto })
})
// Update Inventory Item
html.find('.item-delete').click(ev => {
const li = $(ev.currentTarget).parents(".item");

View File

@@ -18,6 +18,7 @@ export const defaultItemImg = {
fee: "systems/fvtt-les-heritiers/assets/icons/faery_type.webp",
profil: "systems/fvtt-les-heritiers/assets/icons/profil.webp",
equipement: "systems/fvtt-les-heritiers/assets/icons/equipement.webp",
sort: "systems/fvtt-les-heritiers/assets/icons/sort.webp",
}
/**

View File

@@ -12,7 +12,6 @@ import { HeritiersActor } from "./heritiers-actor.js";
import { HeritiersItemSheet } from "./heritiers-item-sheet.js";
import { HeritiersActorSheet } from "./heritiers-actor-sheet.js";
import { HeritiersActorPNJSheet } from "./heritiers-actor-pnj-sheet.js";
import { HeritiersCreatureSheet } from "./heritiers-creature-sheet.js";
import { HeritiersUtility } from "./heritiers-utility.js";
import { HeritiersCombat } from "./heritiers-combat.js";
import { HeritiersItem } from "./heritiers-item.js";
@@ -31,7 +30,7 @@ Hooks.once("init", async function () {
HeritiersUtility.preloadHandlebarsTemplates()
/* -------------------------------------------- */
// Set an initiative formula for the system
// Set an initiative formula for the system
CONFIG.Combat.initiative = {
formula: "1d10",
decimals: 1
@@ -47,6 +46,8 @@ Hooks.once("init", async function () {
CONFIG.Combat.documentClass = HeritiersCombat
CONFIG.Actor.documentClass = HeritiersActor
CONFIG.Item.documentClass = HeritiersItem
// Create an object of bonus/malus from -6 to +6 signed
HERITIERS_CONFIG.bonusMalus = Array.from({ length: 7 }, (v, k) => toString(k - 6))
game.system.lesheritiers = {
HeritiersUtility,
config: HERITIERS_CONFIG
@@ -54,12 +55,12 @@ Hooks.once("init", async function () {
/* -------------------------------------------- */
// Register sheet application classes
Actors.unregisterSheet("core", ActorSheet);
Actors.registerSheet("fvtt-les-heritiers", HeritiersActorSheet, { types: ["personnage"], makeDefault: true })
Actors.registerSheet("fvtt-les-heritiers", HeritiersActorPNJSheet, { types: ["pnj"], makeDefault: true })
foundry.documents.collections.Actors.unregisterSheet("core", foundry.appv1.sheets.ActorSheet);
foundry.documents.collections.Actors.registerSheet("fvtt-les-heritiers", HeritiersActorSheet, { types: ["personnage"], makeDefault: true })
foundry.documents.collections.Actors.registerSheet("fvtt-les-heritiers", HeritiersActorPNJSheet, { types: ["pnj"], makeDefault: true })
Items.unregisterSheet("core", ItemSheet);
Items.registerSheet("fvtt-les-heritiers", HeritiersItemSheet, { makeDefault: true })
foundry.documents.collections.Items.unregisterSheet("core", foundry.appv1.sheets.ItemSheet);
foundry.documents.collections.Items.registerSheet("fvtt-les-heritiers", HeritiersItemSheet, { makeDefault: true })
HeritiersUtility.init()
@@ -79,31 +80,17 @@ function welcomeMessage() {
}
/* -------------------------------------------- */
// Register world usage statistics
function registerUsageCount(registerKey) {
if (game.user.isGM) {
game.settings.register(registerKey, "world-key", {
name: "Unique world key",
scope: "world",
config: false,
default: "",
type: String
});
let worldKey = game.settings.get(registerKey, "world-key")
if (worldKey == undefined || worldKey == "") {
worldKey = randomID(32)
game.settings.set(registerKey, "world-key", worldKey)
}
// Simple API counter
let regURL = `https://www.uberwald.me/fvtt_appcount/count.php?name="${registerKey}"&worldKey="${worldKey}"&version="${game.release.generation}.${game.release.build}"&system="${game.system.id}"&systemversion="${game.system.version}"`
//$.ajaxSetup({
//headers: { 'Access-Control-Allow-Origin': '*' }
//})
$.ajax(regURL)
async function importDefaultScene() {
let exists = game.scenes.find(j => j.name == "Accueil");
if (!exists) {
const scenes = await HeritiersUtility.loadCompendium("fvtt-les-heritiers.scenes")
let newDocuments = scenes.filter(i => i.name == "Accueil");
await game.scenes.documentClass.create(newDocuments);
game.scenes.find(i => i.name == "Accueil").activate();
}
}
/* -------------------------------------------- */
/* Foundry VTT Initialization */
/* -------------------------------------------- */
@@ -120,14 +107,15 @@ Hooks.once("ready", function () {
});
}
registerUsageCount(game.system.id)
welcomeMessage()
import("https://www.uberwald.me/fvtt_appcount/count-class-ready.js").then(moduleCounter => {
console.log("ClassCounter loaded", moduleCounter)
moduleCounter.ClassCounter.registerUsageCount()
}).catch(err =>
console.log("No stats available, giving up.")
)
welcomeMessage();
importDefaultScene();
// CSS patch for v9
if (game.version) {
let sidebar = document.getElementById("sidebar");
sidebar.style.width = "min-content";
}
});
/* -------------------------------------------- */
@@ -137,10 +125,9 @@ Hooks.on("chatMessage", (html, content, msg) => {
if (content[0] == '/') {
let regExp = /(\S+)/g;
let commands = content.match(regExp);
if (game.system.mournblade.commands.processChatCommand(commands, content, msg)) {
if (game.system.lesheritiers.commands.processChatCommand(commands, content, msg)) {
return false;
}
}
return true;
});

View File

@@ -6,7 +6,7 @@ export class HeritiersRollDialog extends Dialog {
static async create(actor, rollData) {
let options = { classes: ["HeritiersDialog"], width: 420, height: 'fit-content', 'z-index': 99999 };
let html = await renderTemplate('systems/fvtt-les-heritiers/templates/roll-dialog-generic.html', rollData);
let html = await foundry.applications.handlebars.renderTemplate('systems/fvtt-les-heritiers/templates/roll-dialog-generic.html', rollData);
return new HeritiersRollDialog(actor, rollData, html, options);
}
@@ -18,18 +18,31 @@ export class HeritiersRollDialog extends Dialog {
icon: '<i class="fas fa-check"></i>',
label: "Lancer 1d8",
callback: () => { this.roll("d8") }
},
rolld10: {
}
}
let enableD10 = false
let enableD12 = false
if (rollData.mode == "pouvoir" || rollData.competence?.system.niveau > 0) {
enableD10 = true
}
if (rollData.mode == "pouvoir" || rollData.competence?.system.niveau > 1) {
enableD12 = true
}
if (enableD10) {
buttons.rolld10 = {
icon: '<i class="fas fa-check"></i>',
label: "Lancer 1d10",
callback: () => { this.roll("d10") }
},
rolld12: {
}
}
if (enableD12) {
buttons.rolld12 = {
icon: '<i class="fas fa-check"></i>',
label: "Lancer 1d12",
callback: () => { this.roll("d12") }
}
}
if (rollData.tricherie) {
buttons["rollTricherie"] = {
icon: '<i class="fas fa-check"></i>',
@@ -55,7 +68,7 @@ export class HeritiersRollDialog extends Dialog {
buttons: buttons,
close: close
}
// Overwrite in case of carac only -> 1d10
// Overwrite in case of carac only -> 1d8
if (rollData.mode == "carac") {
conf.buttons = {
rolld8: {
@@ -96,7 +109,6 @@ export class HeritiersRollDialog extends Dialog {
activateListeners(html) {
super.activateListeners(html);
var dialog = this;
function onLoad() {
}
$(function () { onLoad(); });
@@ -105,6 +117,7 @@ export class HeritiersRollDialog extends Dialog {
this.rollData.sdValue = Number(event.currentTarget.value)
})
html.find('#caracKey').change(async (event) => {
//console.log("caracKey", event.currentTarget.value)
this.rollData.caracKey = String(event.currentTarget.value)
})
html.find('#bonus-malus-context').change((event) => {
@@ -116,6 +129,9 @@ export class HeritiersRollDialog extends Dialog {
html.find('#useSpecialite').change((event) => {
this.rollData.useSpecialite = event.currentTarget.checked
})
html.find('#pouvoirPointsUsage').change((event) => {
this.rollData.pouvoirPointsUsage = Number(event.currentTarget.value)
})
html.find('#attaqueDos').change((event) => {
this.rollData.attaqueDos = event.currentTarget.checked
})
@@ -125,6 +141,6 @@ export class HeritiersRollDialog extends Dialog {
html.find('#attaque-cible').change((event) => {
this.rollData.attaqueCible = String(event.currentTarget.value)
})
}
}

View File

@@ -2,6 +2,45 @@
import { HeritiersCombat } from "./heritiers-combat.js";
import { HeritiersCommands } from "./heritiers-commands.js";
const __facesAdjacentes = {
"d8": {
1: [4, 8, 6],
2: [7, 5, 3],
3: [2, 8, 6],
4: [1, 5, 7],
5: [2, 4, 8],
6: [1, 7, 3],
7: [2, 4, 6],
8: [1, 3, 5]
},
"d10": {
1: [4, 6, 9, 7],
2: [6, 8, 5, 9],
3: [7, 5, 8, 10],
4: [10, 6, 7, 1],
5: [3, 9, 2, 8],
6: [1, 4, 2, 9],
7: [1, 3, 4, 10],
8: [2, 10, 5, 3],
9: [1, 5, 6, 2],
10: [8, 4, 3, 7]
},
"d12": {
1: [2, 3, 4, 5, 6],
2: [1, 6, 8, 12, 3],
3: [1, 4, 11, 12, 2],
4: [1, 5, 10, 11, 3],
5: [1, 6, 9, 10, 4],
6: [1, 2, 8, 9, 5],
7: [8, 9, 10, 11, 12],
8: [2, 6, 9, 7, 12],
9: [5, 10, 7, 8, 6],
10: [4, 11, 7, 9, 5],
11: [7, 10, 4, 3, 12],
12: [2, 8, 7, 11, 3]
}
}
/* -------------------------------------------- */
export class HeritiersUtility {
@@ -9,7 +48,7 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static async init() {
Hooks.on('renderChatLog', (log, html, data) => HeritiersUtility.chatListeners(html))
Hooks.on("getChatLogEntryContext", (html, options) => HeritiersUtility.chatRollMenu(html, options))
/* Unused for Heitiers : Hooks.on("getChatMessageContextOptions", (html, options) => HeritiersUtility.chatRollMenu(html, options))*/
this.rollDataStore = {}
this.defenderStore = {}
@@ -65,6 +104,42 @@ export class HeritiersUtility {
const skills = await HeritiersUtility.loadCompendium("fvtt-les-heritiers.competences")
this.skills = skills.map(i => i.toObject())
this.competencesMagie = this.skills.filter(s => s.system.profil == "magie")
game.settings.register("fvtt-les-heritiers", "heritiers-heritage", {
name: "Points d'héritage",
hint: "Points d'héritage du groupe",
scope: "world",
config: true,
default: 0,
type: Number
})
}
/* -------------------------------------------- */
static getSDSortValue(niveau) {
if (niveau <= 1) return 12;
if (niveau == 2) return 14;
if (niveau == 3) return 16;
if (niveau > 3) return 18;
return 18;
}
/* -------------------------------------------- */
static getCompetencesMagie() {
return this.competencesMagie
}
/* -------------------------------------------- */
static buildCompetencesMagie() {
let competences = foundry.utils.duplicate(this.getCompetencesMagie())
for (let comp of competences) {
// Calcul du rang
let rang = Math.round(comp.system.niveau / 2);
competences.system.rang = rang;
competences.system.rangGenericName = game.system.lesheritiers.config.rangName[rang];
competences.system.rangSpecificName = game.system.lesheritiers.config.rangNameSpecific[comp.Name][competences.system.rangGenericName];
}
}
/* -------------------------------------------- */
@@ -86,18 +161,29 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static async chatListeners(html) {
html.on("click", '.predilection-reroll', async event => {
$(html).on("click", '.predilection-reroll', async event => {
let predIdx = $(event.currentTarget).data("predilection-index")
let messageId = HeritiersUtility.findChatMessageId(event.currentTarget)
let message = game.messages.get(messageId)
let rollData = message.getFlag("world", "heritiers-roll")
let actor = this.getActorFromRollData(rollData)
await actor.setPredilectionUsed(rollData.competence._id, predIdx)
rollData.competence = duplicate(actor.getCompetence(rollData.competence._id))
rollData.competence = foundry.utils.duplicate(actor.getCompetence(rollData.competence._id))
HeritiersUtility.rollHeritiers(rollData)
})
html.on("click", '.roll-chat-degat', async event => {
$(html).on("click", '.roll-tricherie-2', async event => {
let messageId = HeritiersUtility.findChatMessageId(event.currentTarget)
let message = game.messages.get(messageId)
let rollData = message.getFlag("world", "heritiers-roll")
let actor = this.getActorFromRollData(rollData)
if (await actor.incDecTricherie(-2)) {
rollData.forcedValue = Number($(event.currentTarget).data("dice-value"))
HeritiersUtility.rollHeritiers(rollData)
}
})
$(html).on("click", '.roll-chat-degat', async event => {
let messageId = HeritiersUtility.findChatMessageId(event.currentTarget)
let message = game.messages.get(messageId)
let rollData = message.getFlag("world", "heritiers-roll")
@@ -114,10 +200,9 @@ export class HeritiersUtility {
'systems/fvtt-les-heritiers/templates/partial-item-header.html',
'systems/fvtt-les-heritiers/templates/partial-item-description.html',
'systems/fvtt-les-heritiers/templates/partial-item-nav.html',
'systems/fvtt-les-heritiers/templates/partial-utile-skills.html',
'systems/fvtt-les-heritiers/templates/partial-list-niveau.html'
'systems/fvtt-les-heritiers/templates/partial-utile-skills.html'
]
return loadTemplates(templatePaths);
return foundry.applications.handlebars.loadTemplates(templatePaths);
}
/* -------------------------------------------- */
@@ -194,14 +279,14 @@ export class HeritiersUtility {
let id = rollData.rollId;
let oldRollData = this.rollDataStore[id] || {};
let newRollData = mergeObject(oldRollData, rollData);
let newRollData = foundry.utils.mergeObject(oldRollData, rollData);
this.rollDataStore[id] = newRollData;
}
/* -------------------------------------------- */
static saveRollData(rollData) {
game.socket.emit("system.fvtt-les-heritiers", {
name: "msg_update_roll", data: rollData
}); // Notify all other clients of the roll
}); // Notify all other clients of the roll
this.updateRollData(rollData);
}
@@ -212,7 +297,6 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static onSocketMesssage(msg) {
//console.log("SOCKET MESSAGE", msg.name, game.user.character.id, msg.data.defenderId);
if (msg.name == "msg_update_defense_state") {
this.updateDefenseState(msg.data.defenderId, msg.data.rollId);
}
@@ -290,11 +374,12 @@ export class HeritiersUtility {
if (isTricherieHeritage) {
let resTab = [rollData.roll.terms[0].results[0].result, rollData.roll.terms[0].results[1].result, rollData.roll.terms[0].results[2].result]
rollData.diceResult = resTab[0] + "," + resTab[1] + "," + resTab[2]
let foundryTotal = resTab[0] + resTab[1] + resTab[2]
let foundryTotal = resTab[0] + resTab[1] + resTab[2]
if (resTab[1] == 1) { resTab[1] -= 4 }
if (resTab[2] == 1) { resTab[2] -= 6 }
if (resTab[2] == 2) { resTab[2] -= 7 }
rollData.finalResult = rollData.roll.total - foundryTotal + Math.max(Math.max(resTab[0], resTab[1]), resTab[2])
rollData.diceValue = Math.max(Math.max(resTab[0], resTab[1]), resTab[2])
rollData.finalResult = rollData.roll.total - foundryTotal + rollData.diceValue
// Gestion des résultats spéciaux
resTab = resTab.sort()
@@ -319,8 +404,9 @@ export class HeritiersUtility {
} else {
rollData.finalResult = rollData.roll.total
let rollValue = rollData.roll.terms[0].results[0].result
rollData.diceResult = rollData.roll.terms[0].results[0].result
let rollValue = rollData.forcedValue || rollData.roll.terms[0].results[0].result
rollData.diceResult = rollValue
rollData.diceValue = rollValue
if (rollData.mainDice.includes("d10")) {
if (rollValue == 1) {
rollData.finalResult -= 3 + rollValue // substract 3 and the 1 value that has been added
@@ -331,14 +417,16 @@ export class HeritiersUtility {
rollData.finalResult -= 5 + rollValue // Remove also the dice result has it has been added already
}
}
if (!rollData.forcedValue) {
rollData.adjacentFaces = foundry.utils.duplicate(__facesAdjacentes[rollData.mainDice][rollData.diceValue])
}
}
}
/* -------------------------------------------- */
static computeArmeDegats(rollData, actor) {
rollData.degatsArme = rollData.arme.system.degats + rollData.marge
if (rollData.attaqueDeuxArmes != 0 && rollData.secondeArme ) {
if (rollData.attaqueDeuxArmes != 0 && rollData.secondeArme) {
let secondeArme = actor.items.get(secondeArme)
if (secondeArme) {
rollData.degatsArme += secondeArme.system.degats
@@ -353,7 +441,7 @@ export class HeritiersUtility {
}
if (rollData.mode == "attaquecharge") {
rollData.degatsArme += 3
}
}
}
if (rollData.attaqueCible == "membre") {
rollData.degatsArme -= 2
@@ -373,6 +461,10 @@ export class HeritiersUtility {
rollData.isSuccess = (rollData.finalResult >= seuil)
rollData.isCriticalSuccess = ((rollData.finalResult - seuil) >= 7)
rollData.isCriticalFailure = ((rollData.finalResult - seuil) <= -7)
// Si compétence > 0 et d8 -> echec critique impossible
if (rollData?.competence?.system.niveau > 0 && rollData?.mainDice == "d8") {
rollData.isCriticalFailure = false
}
}
}
@@ -386,7 +478,7 @@ export class HeritiersUtility {
this.computeArmeDegats(rollData, actor)
}
this.createChatWithRollMode(rollData.alias, {
content: await renderTemplate(`systems/fvtt-les-heritiers/templates/chat-cc-result.html`, rollData)
content: await foundry.applications.handlebars.renderTemplate(`systems/fvtt-les-heritiers/templates/chat-cc-result.html`, rollData)
}, rollData, "selfroll")
}
/* -------------------------------------------- */
@@ -396,9 +488,9 @@ export class HeritiersUtility {
rollData.defenderValue = valeurDefense
rollData.marge = 0
this.computeMarge(rollData, valeurDefense)
rollData.dureeAssommer = (rollData.marge) ? rollData.marge*2 : 1
rollData.dureeAssommer = (rollData.marge) ? rollData.marge * 2 : 1
this.createChatWithRollMode(rollData.alias, {
content: await renderTemplate(`systems/fvtt-les-heritiers/templates/chat-assommer-result.html`, rollData)
content: await foundry.applications.handlebars.renderTemplate(`systems/fvtt-les-heritiers/templates/chat-assommer-result.html`, rollData)
}, rollData, "selfroll")
}
/* -------------------------------------------- */
@@ -406,13 +498,23 @@ export class HeritiersUtility {
let actor = this.getActorFromRollData(rollData)
//rollData.actionImg = "systems/fvtt-les-heritiers/assets/icons/" + actor.system.attributs[rollData.attrKey].labelnorm + ".webp"
rollData.carac = duplicate(actor.system.caracteristiques[rollData.caracKey])
if (rollData.mode == "pouvoir" && actor.getPouvoirUsage(rollData.pouvoir._id) < rollData.pouvoirPointsUsage) {
ui.notifications.warn("Pas assez de points d'usage pour ce pouvoir.")
return
}
if (rollData.useTricherie || rollData.useHeritage) {
rollData.diceFormula = "{1d8, 1d10, 1d12}"
//rollData.actionImg = "systems/fvtt-les-heritiers/assets/icons/" + actor.system.attributs[rollData.attrKey].labelnorm + ".webp"
if (rollData.caracKey == "pre") rollData.caracKey = "pres"; // Patch tomanage wrong carac key
rollData.carac = foundry.utils.duplicate(actor.system.caracteristiques[rollData.caracKey])
if (rollData.forcedValue) {
rollData.diceFormula = rollData.forcedValue
} else {
rollData.diceFormula = "1" + rollData.mainDice + "kh1"
if (rollData.useTricherie || rollData.useHeritage) {
rollData.diceFormula = "{1d8, 1d10, 1d12}"
} else {
rollData.diceFormula = "1" + rollData.mainDice + "kh1"
}
}
let rangValue = 0
@@ -420,11 +522,11 @@ export class HeritiersUtility {
rangValue = rollData.rang.value
}
if (rollData.competence) {
let compmod = (rollData.competence.system.niveau == 0) ? -3 : 0
let compmod = 0 // Bonus de compétence à 0 dans Les Heritiers
let specBonus = (rollData.useSpecialite) ? 1 : 0
rollData.diceFormula += `+${rollData.carac.value}+${rangValue}+${rollData.competence.system.niveau}+${specBonus}+${rollData.bonusMalusContext}+${compmod}`
} else if (rollData.pouvoirBase) {
rollData.diceFormula += `+${rollData.pouvoirBase.value}+${rangValue}+${rollData.bonusMalusContext}`
rollData.diceFormula += `+${rollData.carac.value}+${rollData.pouvoirBase.value}+${rangValue}+${rollData.bonusMalusContext}`
} else {
rollData.diceFormula += `+${rollData.carac.value}+${rangValue}+${rollData.bonusMalusContext}`
}
@@ -438,7 +540,7 @@ export class HeritiersUtility {
let bonusAttaque = rollData.bonusAttaquePlusieurs
if (rollData.attaqueDos) {
bonusAttaque = 2
if (rollData.bonusAttaquePlusieurs) {
if (rollData.bonusAttaquePlusieurs) {
bonusAttaque = 3 // Valeur max, cf règle page 197
}
}
@@ -450,37 +552,54 @@ export class HeritiersUtility {
}
// Gestion des attaques ciblées
if (rollData.attaqueCible != "none") {
if ( rollData.attaqueCible == "membre") {
if (rollData.attaqueCible == "membre") {
rollData.diceFormula += `-2`
}
if ( rollData.attaqueCible == "main") {
if (rollData.attaqueCible == "main") {
rollData.diceFormula += `-3`
}
if ( rollData.attaqueCible == "tete") {
if (rollData.attaqueCible == "tete") {
rollData.diceFormula += `-6`
}
}
let myRoll = new Roll(rollData.diceFormula).roll({ async: false })
await this.showDiceSoNice(myRoll, game.settings.get("core", "rollMode"))
rollData.roll = myRoll
console.log(">>>> ", myRoll)
this.computeResult(actor, rollData)
this.computeMarge(rollData, rollData.sdValue) // Calcul de la marge si seuil présent
if (!rollData.noRoll) {
let myRoll = await new Roll(rollData.diceFormula).roll()
await this.showDiceSoNice(myRoll, game.settings.get("core", "rollMode"))
rollData.roll = foundry.utils.duplicate(myRoll)
console.log(">>>> ", myRoll)
this.computeResult(actor, rollData)
this.computeMarge(rollData, rollData.sdValue) // Calcul de la marge si seuil présent
}
if (rollData.mode == "init") {
actor.setFlag("world", "last-initiative", rollData.finalResult)
}
// Gestion pouvoir et points d'usage
if (rollData.mode == "pouvoir" || rollData.mode == "pouvoirpassif") {
actor.incDecPointsUsage(rollData.pouvoir._id, -rollData.pouvoirPointsUsage)
}
// Gestion sort et points d'âme
if (rollData.mode == "sort") {
if (rollData.spendEsprit) {
actor.inDecCarac("esp", -rollData.totalEsprit)
} else {
actor.incDecPointsAme(-rollData.sortPointsAme)
if (rollData.sort.system.competence == "Magie du Clan") {
actor.incDecPV(-2)
}
}
}
this.createChatWithRollMode(rollData.alias, {
content: await renderTemplate(`systems/fvtt-les-heritiers/templates/chat-generic-result.html`, rollData)
content: await foundry.applications.handlebars.renderTemplate(`systems/fvtt-les-heritiers/templates/chat-generic-result.html`, rollData)
}, rollData)
// Gestion attaque standard
if ( (rollData.mode == "arme" || rollData.mode == "attaquebrutale" || rollData.mode == "attaquecharge") &&
rollData.defenderTokenId && rollData.arme) {
if (rollData.arme.system.categorie != "trait" && rollData.arme.system.categorie != "poing" && rollData.arme.system.categorie != "epaule" ) {
if ((rollData.mode == "arme" || rollData.mode == "attaquebrutale" || rollData.mode == "attaquecharge") &&
rollData.defenderTokenId && rollData.arme) {
if (rollData.arme.system.categorie != "trait" && rollData.arme.system.categorie != "poing" && rollData.arme.system.categorie != "epaule") {
await this.displayUneDefense(rollData, actor, "Parade", rollData.defenderParade)
await this.displayUneDefense(rollData, actor, "Esquive", rollData.defenderEsquive)
} else if (rollData.sdValue) {
@@ -492,9 +611,9 @@ export class HeritiersUtility {
// Gestion assomer
if (rollData.mode == "assommer" && rollData.defenderTokenId && rollData.arme) {
await this.displayAsssomer(rollData, actor, "Assommer", "Surprise", rollData.defenderResistancePhysique)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Résistance+6", rollData.defenderResistancePhysique+6)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Parade", rollData.defenderParade)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Esquive", rollData.defenderEsquive+6)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Résistance+6", rollData.defenderResistancePhysique + 6)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Parade", rollData.defenderParade)
await this.displayAsssomer(rollData, actor, "Assommer", "Conscient, Esquive", rollData.defenderEsquive + 6)
}
}
@@ -503,16 +622,16 @@ export class HeritiersUtility {
static async bonusRollHeritiers(rollData) {
rollData.bonusFormula = rollData.addedBonus
let bonusRoll = new Roll(rollData.bonusFormula).roll({ async: false })
let bonusRoll = await new Roll(rollData.bonusFormula).roll()
await this.showDiceSoNice(bonusRoll, game.settings.get("core", "rollMode"));
rollData.bonusRoll = bonusRoll
rollData.bonusRoll = foundry.utils.duplicate(bonusRoll)
rollData.finalResult += rollData.bonusRoll.total
this.computeResult(rollData)
this.createChatWithRollMode(rollData.alias, {
content: await renderTemplate(`systems/fvtt-les-heritiers/templates/chat-generic-result.html`, rollData)
content: await foundry.applications.handlebars.renderTemplate(`systems/fvtt-les-heritiers/templates/chat-generic-result.html`, rollData)
}, rollData)
}
@@ -524,7 +643,7 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static isArmeMelee(arme) {
return (arme.type == "arme" && (arme.system.categorie == "lourde" || arme.system.categorie == "blanche" || arme.system.categorie == "improvise")) ? true : false
return (arme.type == "arme" && (arme.system.categorie == "lourde" || arme.system.categorie == "blanche" || arme.system.categorie == "improvise"))
}
/* -------------------------------------------- */
static getWhisperRecipients(rollMode, name) {
@@ -543,7 +662,7 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static blindMessageToGM(chatOptions) {
let chatGM = duplicate(chatOptions);
let chatGM = foundry.utils.duplicate(chatOptions);
chatGM.whisper = this.getUsers(user => user.isGM);
chatGM.content = "Blinde message of " + game.user.name + "<br>" + chatOptions.content;
console.log("blindMessageToGM", chatGM);
@@ -607,7 +726,7 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static getBasicRollData() {
let rollData = {
rollId: randomID(16),
rollId: foundry.utils.randomID(16),
rollMode: game.settings.get("core", "rollMode"),
sdList: game.system.lesheritiers.config.seuilsDifficulte,
sdValue: -1,
@@ -617,7 +736,7 @@ export class HeritiersUtility {
bonusMalusContext: 0,
attaqueCible: "none",
config: game.system.lesheritiers.config,
rulesMalus : []
rulesMalus: []
}
return rollData
}
@@ -685,13 +804,13 @@ export class HeritiersUtility {
static chatRollMenu(html, options) {
let canApply = li => canvas.tokens.controlled.length && li.find(".heritiers-roll").length
let canApplyBA = function (li) {
let message = game.messages.get(li.attr("data-message-id"))
let message = game.messages.get($(li).attr("data-message-id"))
let rollData = message.getFlag("world", "heritiers-roll")
let actor = this.getActorFromRollData(rollData)
return (!rollData.isReroll && actor.getBonneAventure() > 0)
}
let canApplyPE = function (li) {
let message = game.messages.get(li.attr("data-message-id"))
let message = game.messages.get($(li).attr("data-message-id"))
let rollData = message.getFlag("world", "heritiers-roll")
let actor = this.getActorFromRollData(rollData)
return (!rollData.isReroll && actor.getEclat() > 0)
@@ -726,11 +845,11 @@ export class HeritiersUtility {
/* -------------------------------------------- */
static async confirmDelete(actorSheet, li) {
let itemId = li.data("item-id");
let msgTxt = "<p>Are you sure to remove this Item ?";
let msgTxt = "<p>Certain de supprimer cet item ?";
let buttons = {
delete: {
icon: '<i class="fas fa-check"></i>',
label: "Yes, remove it",
label: "Oui !",
callback: () => {
actorSheet.actor.deleteEmbeddedDocuments("Item", [itemId]);
li.slideUp(200, () => actorSheet.render(false));
@@ -738,12 +857,12 @@ export class HeritiersUtility {
},
cancel: {
icon: '<i class="fas fa-times"></i>',
label: "Cancel"
label: "Non !"
}
}
msgTxt += "</p>";
let d = new Dialog({
title: "Confirm removal",
title: "Confirmer la suppression",
content: msgTxt,
buttons: buttons,
default: "cancel"
@@ -751,21 +870,56 @@ export class HeritiersUtility {
d.render(true);
}
/************************************************************************************/
static async __create_talents_table() {
let compName = "fvtt-les-heritiers.talents-cellule"
const compData = await HeritiersUtility.loadCompendium(compName)
let talents = compData.map(i => i.toObject())
let htmlTab = "<table border='1'><tbody>";
for (let entryData of talents) {
console.log(entryData)
htmlTab += `<tr><td>@UUID[Compendium.${compName}.${entryData._id}]{${entryData.name}}</td>`
htmlTab += `<td>${entryData.system.description}</td>`;
//htmlTab += `<td>${entryData.system.resumebonus}</td>`;
htmlTab += "</tr>\n";
static loadSort() {
// Create afolder in the item directory if it doesn't exist
if (!game.folders.getName("Magie du Clan")) {
Folder.create({
name: "Magie du Clan",
type: "Item",
color: "#3b1361"
});
}
htmlTab += "</table>";
await JournalEntry.create({ name: 'Liste des Talents de Cellule', content: htmlTab });
// Load the srcdata/sorts-druidisme.json file
return fetch("systems/fvtt-les-heritiers/srcdata/sort_magieduclan.json")
.then(response => response.json())
.then(data => {
console.log("Sorts Magie du Clan loaded:", data);
this.sortDruidisme = data;
// Loop through the spell and create the "sort "item based on the JSON content
data.forEach(spell => {
spell.name = spell.name;
spell.type = "sort";
spell.system = {
niveau: spell.niveau,
competence: spell.competence,
carac1: spell.carac1,
carac2: spell.carac2,
description: spell.description,
ingredients: spell.ingredients,
portee: spell.portee,
duree: spell.duree,
concentration: spell.concentration,
critique: spell.critique,
resistance: spell.resistance,
coutactivation: spell.coutactivation
};
spell.img = "systems/fvtt-les-heritiers/assets/icons/sort.webp";
spell.folder = game.folders.getName("Magie du Clan").id;
// Create the item in the world
Item.create(spell)
.then(item => {
console.log("Sort created:", item);
})
.catch(error => {
console.error("Error creating sort item:", error);
});
})
})
.catch(error => {
console.error("Error loading druidism spells:", error);
return [];
});
}
}

Binary file not shown.

View File

View File

@@ -0,0 +1 @@
MANIFEST-000300

View File

View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.823326 7f307affd6c0 Recovering log #298
2025/09/15-22:15:24.833041 7f307affd6c0 Delete type=3 #296
2025/09/15-22:15:24.833115 7f307affd6c0 Delete type=0 #298
2025/09/15-22:23:01.584235 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.584266 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.590949 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.597083 7f307a7fc6c0 Manual compaction at level-0 from '!items!1NhJH4IJpxsGmLB8' @ 72057594037927935 : 1 .. '!items!y1yOenfAJTsb3r6e' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.597126 7f307a7fc6c0 Manual compaction at level-1 from '!items!1NhJH4IJpxsGmLB8' @ 72057594037927935 : 1 .. '!items!y1yOenfAJTsb3r6e' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.325495 7f307affd6c0 Recovering log #294
2025/09/15-21:06:27.335836 7f307affd6c0 Delete type=3 #292
2025/09/15-21:06:27.335957 7f307affd6c0 Delete type=0 #294
2025/09/15-21:08:54.705256 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.705333 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.712270 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.731675 7f307a7fc6c0 Manual compaction at level-0 from '!items!1NhJH4IJpxsGmLB8' @ 72057594037927935 : 1 .. '!items!y1yOenfAJTsb3r6e' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.731735 7f307a7fc6c0 Manual compaction at level-1 from '!items!1NhJH4IJpxsGmLB8' @ 72057594037927935 : 1 .. '!items!y1yOenfAJTsb3r6e' @ 0 : 0; will stop at (end)

Binary file not shown.

Binary file not shown.

View File

View File

@@ -0,0 +1 @@
MANIFEST-000300

View File

View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.848609 7f307b7fe6c0 Recovering log #298
2025/09/15-22:15:24.859061 7f307b7fe6c0 Delete type=3 #296
2025/09/15-22:15:24.859140 7f307b7fe6c0 Delete type=0 #298
2025/09/15-22:23:01.577999 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.578051 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.584148 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.597073 7f307a7fc6c0 Manual compaction at level-0 from '!items!1ETVaPBtjDtzelK1' @ 72057594037927935 : 1 .. '!items!zbsVCsWxRzkzzG1N' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.597114 7f307a7fc6c0 Manual compaction at level-1 from '!items!1ETVaPBtjDtzelK1' @ 72057594037927935 : 1 .. '!items!zbsVCsWxRzkzzG1N' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.351420 7f307bfff6c0 Recovering log #294
2025/09/15-21:06:27.362201 7f307bfff6c0 Delete type=3 #292
2025/09/15-21:06:27.362258 7f307bfff6c0 Delete type=0 #294
2025/09/15-21:08:54.712395 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.712426 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.718406 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.731696 7f307a7fc6c0 Manual compaction at level-0 from '!items!1ETVaPBtjDtzelK1' @ 72057594037927935 : 1 .. '!items!zbsVCsWxRzkzzG1N' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.731747 7f307a7fc6c0 Manual compaction at level-1 from '!items!1ETVaPBtjDtzelK1' @ 72057594037927935 : 1 .. '!items!zbsVCsWxRzkzzG1N' @ 0 : 0; will stop at (end)

Binary file not shown.

Binary file not shown.

View File

View File

@@ -0,0 +1 @@
MANIFEST-000300

View File

View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.798700 7f307bfff6c0 Recovering log #298
2025/09/15-22:15:24.808066 7f307bfff6c0 Delete type=3 #296
2025/09/15-22:15:24.808115 7f307bfff6c0 Delete type=0 #298
2025/09/15-22:23:01.541562 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.541615 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.547814 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.565908 7f307a7fc6c0 Manual compaction at level-0 from '!items!0fPXtA5LkLgG8uDj' @ 72057594037927935 : 1 .. '!items!zvtBlG6KCIn0oCVk' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.565949 7f307a7fc6c0 Manual compaction at level-1 from '!items!0fPXtA5LkLgG8uDj' @ 72057594037927935 : 1 .. '!items!zvtBlG6KCIn0oCVk' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.300488 7f307bfff6c0 Recovering log #294
2025/09/15-21:06:27.310028 7f307bfff6c0 Delete type=3 #292
2025/09/15-21:06:27.310094 7f307bfff6c0 Delete type=0 #294
2025/09/15-21:08:54.685417 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.685439 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.692723 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.705096 7f307a7fc6c0 Manual compaction at level-0 from '!items!0fPXtA5LkLgG8uDj' @ 72057594037927935 : 1 .. '!items!zvtBlG6KCIn0oCVk' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.705139 7f307a7fc6c0 Manual compaction at level-1 from '!items!0fPXtA5LkLgG8uDj' @ 72057594037927935 : 1 .. '!items!zvtBlG6KCIn0oCVk' @ 0 : 0; will stop at (end)

Binary file not shown.

BIN
packs/avantages/000179.ldb Normal file

Binary file not shown.

View File

1
packs/avantages/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000300

0
packs/avantages/LOCK Normal file
View File

8
packs/avantages/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.760919 7f3080dfa6c0 Recovering log #298
2025/09/15-22:15:24.770694 7f3080dfa6c0 Delete type=3 #296
2025/09/15-22:15:24.770767 7f3080dfa6c0 Delete type=0 #298
2025/09/15-22:23:01.521581 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.521642 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.528012 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.534278 7f307a7fc6c0 Manual compaction at level-0 from '!items!0EAAt0qSzcD9VRBH' @ 72057594037927935 : 1 .. '!items!zfpjROW9LDAlXUkN' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.534315 7f307a7fc6c0 Manual compaction at level-1 from '!items!0EAAt0qSzcD9VRBH' @ 72057594037927935 : 1 .. '!items!zfpjROW9LDAlXUkN' @ 0 : 0; will stop at (end)

8
packs/avantages/LOG.old Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.262631 7f307bfff6c0 Recovering log #294
2025/09/15-21:06:27.272396 7f307bfff6c0 Delete type=3 #292
2025/09/15-21:06:27.272468 7f307bfff6c0 Delete type=0 #294
2025/09/15-21:08:54.666847 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.666873 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.672959 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.679358 7f307a7fc6c0 Manual compaction at level-0 from '!items!0EAAt0qSzcD9VRBH' @ 72057594037927935 : 1 .. '!items!zfpjROW9LDAlXUkN' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.679384 7f307a7fc6c0 Manual compaction at level-1 from '!items!0EAAt0qSzcD9VRBH' @ 72057594037927935 : 1 .. '!items!zfpjROW9LDAlXUkN' @ 0 : 0; will stop at (end)

Binary file not shown.

BIN
packs/capacites/000179.ldb Normal file

Binary file not shown.

View File

1
packs/capacites/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000300

0
packs/capacites/LOCK Normal file
View File

8
packs/capacites/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.786128 7f307affd6c0 Recovering log #298
2025/09/15-22:15:24.796141 7f307affd6c0 Delete type=3 #296
2025/09/15-22:15:24.796205 7f307affd6c0 Delete type=0 #298
2025/09/15-22:23:01.534415 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.534493 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.541334 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.565894 7f307a7fc6c0 Manual compaction at level-0 from '!items!0cNSRJVPk3GbvxfD' @ 72057594037927935 : 1 .. '!items!yWDg2KlXEz33TSmZ' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.565940 7f307a7fc6c0 Manual compaction at level-1 from '!items!0cNSRJVPk3GbvxfD' @ 72057594037927935 : 1 .. '!items!yWDg2KlXEz33TSmZ' @ 0 : 0; will stop at (end)

8
packs/capacites/LOG.old Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.288049 7f307b7fe6c0 Recovering log #294
2025/09/15-21:06:27.298262 7f307b7fe6c0 Delete type=3 #292
2025/09/15-21:06:27.298356 7f307b7fe6c0 Delete type=0 #294
2025/09/15-21:08:54.692841 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.692870 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.698762 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.705111 7f307a7fc6c0 Manual compaction at level-0 from '!items!0cNSRJVPk3GbvxfD' @ 72057594037927935 : 1 .. '!items!yWDg2KlXEz33TSmZ' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.705145 7f307a7fc6c0 Manual compaction at level-1 from '!items!0cNSRJVPk3GbvxfD' @ 72057594037927935 : 1 .. '!items!yWDg2KlXEz33TSmZ' @ 0 : 0; will stop at (end)

Binary file not shown.

Binary file not shown.

View File

View File

@@ -0,0 +1 @@
MANIFEST-000306

0
packs/competences/LOCK Normal file
View File

8
packs/competences/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.748857 7f307affd6c0 Recovering log #304
2025/09/15-22:15:24.758566 7f307affd6c0 Delete type=3 #302
2025/09/15-22:15:24.758631 7f307affd6c0 Delete type=0 #304
2025/09/15-22:23:01.528222 7f307a7fc6c0 Level-0 table #309: started
2025/09/15-22:23:01.528266 7f307a7fc6c0 Level-0 table #309: 0 bytes OK
2025/09/15-22:23:01.534172 7f307a7fc6c0 Delete type=0 #307
2025/09/15-22:23:01.534287 7f307a7fc6c0 Manual compaction at level-0 from '!folders!FBCujRu055QLePB2' @ 72057594037927935 : 1 .. '!items!zEl2NQsnCpELVWzh' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.534306 7f307a7fc6c0 Manual compaction at level-1 from '!folders!FBCujRu055QLePB2' @ 72057594037927935 : 1 .. '!items!zEl2NQsnCpELVWzh' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.249709 7f307b7fe6c0 Recovering log #300
2025/09/15-21:06:27.260222 7f307b7fe6c0 Delete type=3 #298
2025/09/15-21:06:27.260307 7f307b7fe6c0 Delete type=0 #300
2025/09/15-21:08:54.660355 7f307a7fc6c0 Level-0 table #305: started
2025/09/15-21:08:54.660389 7f307a7fc6c0 Level-0 table #305: 0 bytes OK
2025/09/15-21:08:54.666754 7f307a7fc6c0 Delete type=0 #303
2025/09/15-21:08:54.679346 7f307a7fc6c0 Manual compaction at level-0 from '!folders!FBCujRu055QLePB2' @ 72057594037927935 : 1 .. '!items!zEl2NQsnCpELVWzh' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.679378 7f307a7fc6c0 Manual compaction at level-1 from '!folders!FBCujRu055QLePB2' @ 72057594037927935 : 1 .. '!items!zEl2NQsnCpELVWzh' @ 0 : 0; will stop at (end)

Binary file not shown.

Binary file not shown.

View File

View File

@@ -0,0 +1 @@
MANIFEST-000300

0
packs/desavantages/LOCK Normal file
View File

8
packs/desavantages/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.773117 7f307b7fe6c0 Recovering log #298
2025/09/15-22:15:24.783458 7f307b7fe6c0 Delete type=3 #296
2025/09/15-22:15:24.783520 7f307b7fe6c0 Delete type=0 #298
2025/09/15-22:23:01.559017 7f307a7fc6c0 Level-0 table #303: started
2025/09/15-22:23:01.559048 7f307a7fc6c0 Level-0 table #303: 0 bytes OK
2025/09/15-22:23:01.565802 7f307a7fc6c0 Delete type=0 #301
2025/09/15-22:23:01.565930 7f307a7fc6c0 Manual compaction at level-0 from '!items!2QqvtClSVnh5ejXu' @ 72057594037927935 : 1 .. '!items!xzRJ6JP1HqoqxLdj' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.565957 7f307a7fc6c0 Manual compaction at level-1 from '!items!2QqvtClSVnh5ejXu' @ 72057594037927935 : 1 .. '!items!xzRJ6JP1HqoqxLdj' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.274645 7f3080dfa6c0 Recovering log #294
2025/09/15-21:06:27.285405 7f3080dfa6c0 Delete type=3 #292
2025/09/15-21:06:27.285486 7f3080dfa6c0 Delete type=0 #294
2025/09/15-21:08:54.679508 7f307a7fc6c0 Level-0 table #299: started
2025/09/15-21:08:54.679542 7f307a7fc6c0 Level-0 table #299: 0 bytes OK
2025/09/15-21:08:54.685322 7f307a7fc6c0 Delete type=0 #297
2025/09/15-21:08:54.705080 7f307a7fc6c0 Manual compaction at level-0 from '!items!2QqvtClSVnh5ejXu' @ 72057594037927935 : 1 .. '!items!xzRJ6JP1HqoqxLdj' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.705123 7f307a7fc6c0 Manual compaction at level-1 from '!items!2QqvtClSVnh5ejXu' @ 72057594037927935 : 1 .. '!items!xzRJ6JP1HqoqxLdj' @ 0 : 0; will stop at (end)

Binary file not shown.

BIN
packs/journaux/000005.ldb Normal file

Binary file not shown.

View File

1
packs/journaux/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000018

0
packs/journaux/LOCK Normal file
View File

8
packs/journaux/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.887393 7f3080dfa6c0 Recovering log #16
2025/09/15-22:15:24.897947 7f3080dfa6c0 Delete type=3 #14
2025/09/15-22:15:24.898013 7f3080dfa6c0 Delete type=0 #16
2025/09/15-22:23:01.610372 7f307a7fc6c0 Level-0 table #21: started
2025/09/15-22:23:01.610444 7f307a7fc6c0 Level-0 table #21: 0 bytes OK
2025/09/15-22:23:01.616579 7f307a7fc6c0 Delete type=0 #19
2025/09/15-22:23:01.623474 7f307a7fc6c0 Manual compaction at level-0 from '!journal!QZDy8zwSVh7t4meA' @ 72057594037927935 : 1 .. '!journal.pages!QZDy8zwSVh7t4meA.gdXBDBkPlBjfmTy7' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.623518 7f307a7fc6c0 Manual compaction at level-1 from '!journal!QZDy8zwSVh7t4meA' @ 72057594037927935 : 1 .. '!journal.pages!QZDy8zwSVh7t4meA.gdXBDBkPlBjfmTy7' @ 0 : 0; will stop at (end)

8
packs/journaux/LOG.old Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.389764 7f307affd6c0 Recovering log #12
2025/09/15-21:06:27.400118 7f307affd6c0 Delete type=3 #10
2025/09/15-21:06:27.400175 7f307affd6c0 Delete type=0 #12
2025/09/15-21:08:54.731831 7f307a7fc6c0 Level-0 table #17: started
2025/09/15-21:08:54.731879 7f307a7fc6c0 Level-0 table #17: 0 bytes OK
2025/09/15-21:08:54.738151 7f307a7fc6c0 Delete type=0 #15
2025/09/15-21:08:54.758915 7f307a7fc6c0 Manual compaction at level-0 from '!journal!QZDy8zwSVh7t4meA' @ 72057594037927935 : 1 .. '!journal.pages!QZDy8zwSVh7t4meA.gdXBDBkPlBjfmTy7' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.758952 7f307a7fc6c0 Manual compaction at level-1 from '!journal!QZDy8zwSVh7t4meA' @ 72057594037927935 : 1 .. '!journal.pages!QZDy8zwSVh7t4meA.gdXBDBkPlBjfmTy7' @ 0 : 0; will stop at (end)

Binary file not shown.

View File

Binary file not shown.

View File

@@ -0,0 +1 @@
MANIFEST-000103

0
packs/magie-sorts/LOCK Normal file
View File

15
packs/magie-sorts/LOG Normal file
View File

@@ -0,0 +1,15 @@
2025/09/15-22:15:24.810480 7f307b7fe6c0 Recovering log #101
2025/09/15-22:15:24.820390 7f307b7fe6c0 Delete type=3 #99
2025/09/15-22:15:24.820446 7f307b7fe6c0 Delete type=0 #101
2025/09/15-22:23:01.547894 7f307a7fc6c0 Level-0 table #106: started
2025/09/15-22:23:01.552623 7f307a7fc6c0 Level-0 table #106: 132165 bytes OK
2025/09/15-22:23:01.558854 7f307a7fc6c0 Delete type=0 #104
2025/09/15-22:23:01.565921 7f307a7fc6c0 Manual compaction at level-0 from '!folders!5pCYN0vTiCKOHrXM' @ 72057594037927935 : 1 .. '!items!zbZ88BQkH9ZCYlDK' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.565970 7f307a7fc6c0 Manual compaction at level-1 from '!folders!5pCYN0vTiCKOHrXM' @ 72057594037927935 : 1 .. '!items!zbZ88BQkH9ZCYlDK' @ 0 : 0; will stop at '!items!zbZ88BQkH9ZCYlDK' @ 457 : 0
2025/09/15-22:23:01.565979 7f307a7fc6c0 Compacting 1@1 + 1@2 files
2025/09/15-22:23:01.571458 7f307a7fc6c0 Generated table #107@1: 146 keys, 129863 bytes
2025/09/15-22:23:01.571503 7f307a7fc6c0 Compacted 1@1 + 1@2 files => 129863 bytes
2025/09/15-22:23:01.577463 7f307a7fc6c0 compacted to: files[ 0 0 1 0 0 0 0 ]
2025/09/15-22:23:01.577659 7f307a7fc6c0 Delete type=2 #86
2025/09/15-22:23:01.577865 7f307a7fc6c0 Delete type=2 #106
2025/09/15-22:23:01.597062 7f307a7fc6c0 Manual compaction at level-1 from '!items!zbZ88BQkH9ZCYlDK' @ 457 : 0 .. '!items!zbZ88BQkH9ZCYlDK' @ 0 : 0; will stop at (end)

View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.312840 7f3080dfa6c0 Recovering log #97
2025/09/15-21:06:27.322814 7f3080dfa6c0 Delete type=3 #95
2025/09/15-21:06:27.322901 7f3080dfa6c0 Delete type=0 #97
2025/09/15-21:08:54.698842 7f307a7fc6c0 Level-0 table #102: started
2025/09/15-21:08:54.698870 7f307a7fc6c0 Level-0 table #102: 0 bytes OK
2025/09/15-21:08:54.704908 7f307a7fc6c0 Delete type=0 #100
2025/09/15-21:08:54.705132 7f307a7fc6c0 Manual compaction at level-0 from '!folders!1ENmqNfRLUTmKPc6' @ 72057594037927935 : 1 .. '!items!zbZ88BQkH9ZCYlDK' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.705168 7f307a7fc6c0 Manual compaction at level-1 from '!folders!1ENmqNfRLUTmKPc6' @ 72057594037927935 : 1 .. '!items!zbZ88BQkH9ZCYlDK' @ 0 : 0; will stop at (end)

Binary file not shown.

View File

@@ -10,7 +10,7 @@
{"name":"Élémentaire majeur (Légendaire)","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"metamorphose","masquetype":"demasque","niveau":"legendaire","activation":"2 points dusage au lieu dun, ainsi qu1 point temporaire de Constitution.","istest":false,"feeriemasque":"feerie","zoneffet":"","testautre":"Attaque avec des crocs","carac":"pres","duree":"une scène","cibles":"","effet":"transformation en élémentaire de son\naffinité ; absorbe Féérie points de dégâts sauf contre des attaques efficaces (élément contraire ou argent). \nAttaques : effectuées avec Mêlée + AGI ; dégâts élémentaires = Féérie + MR (pas de bonus de Force).\n","portee":"","resistance":"aucune","resistanceautre":"Esquive / test dopposition de Mêlée ou Ressort + Force pour se dégager.","isvirulence":false,"virulence":"","description":"<p>Le djinn se transforme en &eacute;l&eacute;mentaire majeur de tr&egrave;s grande taille (environ 2,5 m&egrave;tres de haut et d&rsquo;envergure), avec d&rsquo;importants pouvoirs de contr&ocirc;le de son &eacute;l&eacute;ment de pr&eacute;dilection : tornade de sable ou d&rsquo;eau, contr&ocirc;le du feu, temp&ecirc;te, etc. Ce contr&ocirc;le &eacute;l&eacute;mentaire est de forme relativement libre selon la vraisemblance et ce qu&rsquo;autorise le Docte et sa puissance est comparable au Pouvoir profond du ph&eacute;nix Contr&ocirc;le du feu (voir p. 264). Il utilise ses longs bras (1,5 m) pour porter des attaques &eacute;l&eacute;mentaires avec des effets critiques li&eacute;s : le feu enflamme les v&ecirc;tements, l&rsquo;eau et le sable &eacute;tourdissent, l&rsquo;air ajoute des d&eacute;g&acirc;ts de projection ou de chute, etc.</p>\n<p>Les attaques physiques port&eacute;es contre lui sont r&eacute;duites d&rsquo;autant de points de d&eacute;g&acirc;ts que son rang de F&eacute;&eacute;rie, sauf si elles font intervenir de l&rsquo;argent. Toutefois, projeter sur lui une grande quantit&eacute; (1 m3 environ) d&rsquo;un &eacute;l&eacute;ment auquel il est vuln&eacute;rable (l&rsquo;eau pour les djinns du feu, la terre ou le sable pour les djinns de l&rsquo;eau, le vent pour les djinns de sable, le feu pour les djinns de l&rsquo;air) pourra contraindre un djinn l&eacute;gendaire &agrave; abandonner sa forme d&rsquo;&Eacute;l&eacute;mentaire majeur.</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678214487456,"modifiedTime":1678303349575,"lastModifiedBy":"xGnwWyEbO2k89UsP"},"_id":"4v8Z2ThDSwwWb0DU","folder":null,"sort":0,"ownership":{"default":0,"xGnwWyEbO2k89UsP":3}}
{"name":"Psychotopie","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"actif","masquetype":"masque","niveau":"normal","activation":"Féérie + Esprit et une transe de 5 minutes au moins, contre un SD variable selon la taille et les événements se déroulant dans le lieu (une chambre isolée depuis des années : SD10 ; un immeuble rempli d'habitants dans lequel il y a fréquemment du passage : SD 20).","istest":true,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"esp","duree":"","cibles":"un seul lieu","effet":"apprend des informations marquantes sur un lieu","portee":"un lieu (pas plus grand quun bâtiment)","resistance":"aucune","resistanceautre":"","isvirulence":false,"virulence":"","description":"<p><strong>Type de Pouvoir : </strong>actif.</p>\n<p><strong>Activation : </strong>F&eacute;&eacute;rie + Esprit et une transe de 5 minutes au moins, contre un SD variable selon la taille et les &eacute;v&eacute;nements se d&eacute;roulant dans le lieu (une chambre isol&eacute;e depuis des ann&eacute;es : SD10 ; un immeuble rempli d'habitants dans lequel il y a fr&eacute;quemment du passage : SD 20).</p>\n<p><strong>Cibles :</strong> un seul lieu.</p>\n<p><strong>Effet :</strong> apprend des informations marquantes sur un lieu.</p>\n<p><strong>Zone d&rsquo;effet : </strong>un lieu (pas plus grand qu&rsquo;un b&acirc;timent).</p>\n<p>La cr&eacute;ature est capable, apr&egrave;s avoir &eacute;tabli un contact mental avec un lieu par une transe prolong&eacute;e, de r&eacute;cup&eacute;rer des informations sur ce qui s&rsquo;y est pass&eacute;. En fonction de sa MR, elle aura acc&egrave;s &agrave; diff&eacute;rents d&eacute;tails : paroles prononc&eacute;es r&eacute;cemment ou qui ont marqu&eacute; l&rsquo;atmosph&egrave;re, traits physiques g&eacute;n&eacute;raux de protagonistes pr&eacute;sents (odeur, poids, etc.). Les &eacute;v&eacute;nements marquants (meurtre, incendie, etc.) impr&egrave;gnent davantage un lieu et faciliteront le SD du test &agrave; la discr&eacute;tion du Docte mais peuvent rester imperceptibles dans la masse d&rsquo;informations si le lieu est vaste et fr&eacute;quent&eacute;.</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678280900282,"modifiedTime":1678314472642,"lastModifiedBy":"3jSVOAZZNxArxD7h"},"_id":"672N9fk2mJahvJIL","folder":null,"sort":0,"ownership":{"default":0,"3jSVOAZZNxArxD7h":3}}
{"name":"Doppelgänger universel","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"metamorphose","masquetype":"demasque","niveau":"legendaire","activation":"test de Masque + Féérie contre un SD de 10 + Prestance de la personne imitée modifiée par la précision de la source servant à limitation (connaissance personnelle profonde = bonus de + 3, connaissance personnelle superficielle = + 1, photographie = - 1, illustration fidèle = - 2).","istest":true,"feeriemasque":"Masque","zoneffet":"","testautre":"","carac":"agi","duree":" une scène.","cibles":"","effet":"prendre lapparence de nimporte qui.","portee":"","resistance":"autre","resistanceautre":"percer à jour le protys légendaire nécessite un test de Sensibilité (Psychologie) + Perception en opposition au test de Féérie + Masque du protys.","isvirulence":false,"virulence":"","description":"<p><strong>Type de Pouvoir : </strong>d&eacute;masqu&eacute; ; actif puis m&eacute;tamorphose pour adopter l&rsquo;identit&eacute; imit&eacute;e.</p>\n<p><strong>Activation : </strong>test de Masque + F&eacute;&eacute;rie contre un SD de 10 + Prestance de la personne imit&eacute;e modifi&eacute;e par la pr&eacute;cision de la source servant &agrave; l&rsquo;imitation (connaissance personnelle profonde = bonus de + 3, connaissance personnelle superficielle = + 1, photographie = - 1, illustration fid&egrave;le = - 2).</p>\n<p><strong>Dur&eacute;e : </strong>une sc&egrave;ne.</p>\n<p><strong>Effet : </strong>prendre l&rsquo;apparence de n&rsquo;importe qui.</p>\n<p><strong>R&eacute;sistance : </strong>percer &agrave; jour le protys l&eacute;gendaire n&eacute;cessite un test de Sensibilit&eacute; (Psychologie) + Perception en opposition au test de F&eacute;&eacute;rie + Masque du protys.</p>\n<p>Le protys l&eacute;gendaire est capable, pendant une sc&egrave;ne, de prendre l&rsquo;apparence (traits du visage, corpulence, etc.) de n&rsquo;importe quel individu dont il aurait vu le visage en r&eacute;alit&eacute; ou en photographie, voire sur une illustration suffisamment fid&egrave;le. Il peut m&ecirc;me imiter une f&eacute;e avec ses capacit&eacute;s naturelles (ailes, crocs, pelage, etc.) au point de pouvoir s&rsquo;en servir normalement (il pourra ainsi voler, utiliser une queue pr&eacute;hensile, etc.). Il n&rsquo;aura en revanche pas acc&egrave;s aux Pouvoirs de la f&eacute;e imit&eacute;e.</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.21","coreVersion":"10.291","createdTime":1678354656026,"modifiedTime":1678356879899,"lastModifiedBy":"3jSVOAZZNxArxD7h"},"_id":"67ECitVegs2SFn2g","folder":null,"sort":0,"ownership":{"default":0,"3jSVOAZZNxArxD7h":3}}
{"name":"Souffle enflammé","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"actif","masquetype":"masque","niveau":"normal","activation":" test de Féérie + Agilité ou Précision.","istest":false,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"pre","duree":"","cibles":"une seule.","effet":"souffle de feu de dégâts = 2 + MR","portee":"Féérie mètres.","resistance":"autre","resistanceautre":"Esquive","isvirulence":false,"virulence":"","description":"<p><strong>Type de Pouvoir : </strong>actif.</p>\n<p><strong>Activation : </strong>test de F&eacute;&eacute;rie + Agilit&eacute; ou Pr&eacute;cision.</p>\n<p><strong>Cibles : </strong>une seule.</p>\n<p><strong>Effet : </strong>souffle de feu de d&eacute;g&acirc;ts = 2 + MR.</p>\n<p><strong>Port&eacute;e : </strong>F&eacute;&eacute;rie m&egrave;tres.</p>\n<p><strong>R&eacute;sistance : </strong>Esquive.</p>\n<p>La cr&eacute;ature souffle un jet de feu capables d&rsquo;enflammer les mat&eacute;riaux combustibles (papier, tissus, bois) et faire des d&eacute;g&acirc;ts sur une cible. Cette derni&egrave;re peut &ecirc;tre durablement enflamm&eacute;e si les d&eacute;g&acirc;ts subis sont de 8 ou plus (en cumulant les attaques). La cible subira alors 1 point de d&eacute;g&acirc;t par tour jusqu&rsquo;&agrave; ce que les flammes soient &eacute;teintes par la cible ou un alli&eacute;. En&nbsp; as de r&eacute;ussite critique du Souffle enflamm&eacute;, la cible peut perdre, en plus de points de Vie, un point de Prestance permanent &agrave; moins d&rsquo;&ecirc;tre soign&eacute;e imm&eacute;diatement.</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678293330850,"modifiedTime":1678314472644,"lastModifiedBy":"3jSVOAZZNxArxD7h"},"_id":"68wj1CJt4oipIedV","folder":null,"sort":0,"ownership":{"default":0,"3jSVOAZZNxArxD7h":3}}
{"name":"Souffle enflammé","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"actif","masquetype":"masque","niveau":"normal","activation":" test de Féérie + Agilité ou Précision.","istest":true,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"agi","duree":"","cibles":"une seule.","effet":"souffle de feu de dégâts = 2 + MR","portee":"Féérie mètres.","resistance":"autre","resistanceautre":"Esquive","isvirulence":false,"virulence":"","description":"<p><strong>Type de Pouvoir : </strong>actif.</p>\n<p><strong>Activation : </strong>test de F&eacute;&eacute;rie + Agilit&eacute; ou Pr&eacute;cision.</p>\n<p><strong>Cibles : </strong>une seule.</p>\n<p><strong>Effet : </strong>souffle de feu de d&eacute;g&acirc;ts = 2 + MR.</p>\n<p><strong>Port&eacute;e : </strong>F&eacute;&eacute;rie m&egrave;tres.</p>\n<p><strong>R&eacute;sistance : </strong>Esquive.</p>\n<p>La cr&eacute;ature souffle un jet de feu capables d&rsquo;enflammer les mat&eacute;riaux combustibles (papier, tissus, bois) et faire des d&eacute;g&acirc;ts sur une cible. Cette derni&egrave;re peut &ecirc;tre durablement enflamm&eacute;e si les d&eacute;g&acirc;ts subis sont de 8 ou plus (en cumulant les attaques). La cible subira alors 1 point de d&eacute;g&acirc;t par tour jusqu&rsquo;&agrave; ce que les flammes soient &eacute;teintes par la cible ou un alli&eacute;. En&nbsp; as de r&eacute;ussite critique du Souffle enflamm&eacute;, la cible peut perdre, en plus de points de Vie, un point de Prestance permanent &agrave; moins d&rsquo;&ecirc;tre soign&eacute;e imm&eacute;diatement.</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.1.3","coreVersion":"10.291","createdTime":1678293330850,"modifiedTime":1682875304779,"lastModifiedBy":"xGnwWyEbO2k89UsP"},"_id":"68wj1CJt4oipIedV","folder":null,"sort":0,"ownership":{"default":0,"3jSVOAZZNxArxD7h":3}}
{"name":"Chute indolore","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"passif","masquetype":"masque","niveau":"normal","activation":"","istest":false,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"pres","duree":"","cibles":"","effet":"la hauteur dune chute est réduite de Féérie x 4 m pour le calcul de son SD.","portee":"","resistance":"aucune","resistanceautre":"Celle de la structure ou de lobjet (voir p. 204).","isvirulence":false,"virulence":"","description":"<p>La cr&eacute;ature est capable d&rsquo;affronter les pires chutes sans se faire mal. Lorsque ce Pouvoir est actif, on soustrait F&eacute;&eacute;rie x 4 m &agrave; la hauteur de la chute pour le calcul de son SD.</p>\n<p><strong>Exemple</strong> : <em>si une cr&eacute;ature a 4 en F&eacute;&eacute;rie et chute de 20 m, c&rsquo;est comme si elle ne chutait que de 4 m (elle ignore 4 x 4 = 16 m). Le SD de son test de Ressort + Agilit&eacute; pour limiter les d&eacute;g&acirc;ts de la chute sera &eacute;gal &agrave; 8 au lieu de 22 (voir le tableau des chutes, p. 190).</em></p>"},"effects":[],"flags":{"core":{"sourceId":"Item.745Qz4iEGB7RnBPk"}},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678214487456,"modifiedTime":1678303349644,"lastModifiedBy":"xGnwWyEbO2k89UsP"},"_id":"6v3s1I0blnPJHipG","folder":null,"sort":0,"ownership":{"default":0,"xGnwWyEbO2k89UsP":3}}
{"name":"Charme","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"actif","masquetype":"masque","niveau":"normal","activation":"test de Féérie + Prestance.","istest":true,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"pres","duree":"Féérie + MR jours.","cibles":" une cible.","effet":"la cible tombe amoureuse.","portee":"conversation.","resistance":"psychiquepassive","resistanceautre":"Celle de la structure ou de lobjet (voir p. 204).","isvirulence":false,"virulence":"","description":"<p>La cr&eacute;ature est capable, au cours d&rsquo;une conversation, de faire tomber sa cible follement amoureuse d&rsquo;elle si elle ne R&eacute;siste pas. La cible, une fois &eacute;prise de la cr&eacute;ature, aura du mal &agrave; lui refuser quelque chose mais ne fera rien qui puisse directement nuire &agrave; ses jours et ira rarement contre son code moral.</p>\n<p>Pour la pousser &agrave; une telle extr&eacute;mit&eacute;, la cr&eacute;ature devra obtenir une r&eacute;ussite critique ou r&eacute;ussir un test de Rh&eacute;torique ou S&eacute;duction de SD 15 minimum (au jugement du Docte) b&eacute;n&eacute;ficiant d&rsquo;un bonus &eacute;gal &agrave; la MR du Pouvoir.</p>"},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678214487456,"modifiedTime":1678303349644,"lastModifiedBy":"xGnwWyEbO2k89UsP"},"_id":"745Qz4iEGB7RnBPk","folder":null,"sort":0,"ownership":{"default":0,"xGnwWyEbO2k89UsP":3}}
{"name":"Sujet qui fâche","type":"pouvoir","img":"systems/fvtt-les-heritiers/assets/icons/power.webp","system":{"pouvoirtype":"actif","masquetype":"masque","niveau":"normal","activation":"test de Féérie + Esprit.","istest":true,"feeriemasque":"feerie","zoneffet":"","testautre":"","carac":"esp","duree":"","cibles":" une cible","effet":"fait deviner ce qui fâche quelquun ; fait perdre automatiquement un point de Sang-froid quand ce sujet est abordé et pousse à la colère.","portee":" à vue","resistance":"autre","resistanceautre":"psychique pour ne pas être percé à jour puis Fortitude + Sang-froid pour garder le contrôle contre un SD difficile (13 ou plus) fixé par le Docte.","isvirulence":false,"virulence":"","description":"<p><strong>Type de Pouvoir :</strong> actif.</p>\n<p><strong>Activation : </strong>test de F&eacute;&eacute;rie + Esprit.</p>\n<p><strong>Cibles : </strong>une cible.</p>\n<p><strong>Effet :</strong> fait deviner ce qui f&acirc;che quelqu&rsquo;un ; fait perdre automatiquement un point de Sang-froid quand ce sujet est abord&eacute; et pousse &agrave; la col&egrave;re.</p>\n<p><strong>Port&eacute;e :</strong> &agrave; vue.</p>\n<p><strong>R&eacute;sistance : </strong>psychique pour ne pas &ecirc;tre perc&eacute; &agrave; jour puis Fortitude + Sang-froid pour garder le contr&ocirc;le contre un SD difficile (13 ou plus) fix&eacute; par le Docte.</p>\n<p>Lorsqu&rsquo;elle active ce Pouvoir, la cr&eacute;ature peut, en observant son interlocuteur (il peut avoir un bonus d&rsquo;apr&egrave;s des &eacute;l&eacute;ments qu&rsquo;il conna&icirc;t), trouver instinctivement le sujet qui va le f&acirc;cher et, selon son caract&egrave;re, le mettre en col&egrave;re ou le faire fuir en rougissant. Ce peut &ecirc;tre un complexe, une histoire louche, une phobie&hellip; Toutefois, elle n&rsquo;est pas oblig&eacute;e d&rsquo;en faire usage : le Docte doit juste lui communiquer le sujet susceptible de froisser la personne en question.<br>Si la victime R&eacute;siste, la cr&eacute;ature n&rsquo;est pas s&ucirc;re du &laquo; sujet qui f&acirc;che &raquo;. En cas de succ&egrave;s du Pouvoir, si la cr&eacute;ature se sert du Sujet qui f&acirc;che, la cible perd automatiquement un point de Sang-froid (effet non cumulable) et doit r&eacute;ussir &agrave; se ma&icirc;triser pour ne pas montrer sa col&egrave;re ou sa g&ecirc;ne. Toutefois, la victime ne peut que ma&icirc;triser ses r&eacute;actions apparentes (et bouillir int&eacute;rieurement).</p>","zoneeffet":""},"effects":[],"flags":{},"_stats":{"systemId":"fvtt-les-heritiers","systemVersion":"10.0.18","coreVersion":"10.291","createdTime":1678313273572,"modifiedTime":1678314472645,"lastModifiedBy":"3jSVOAZZNxArxD7h"},"_id":"7BsyUzwv31oxldYQ","folder":null,"sort":0,"ownership":{"default":0,"3jSVOAZZNxArxD7h":3}}

BIN
packs/pouvoirs/000180.ldb Normal file

Binary file not shown.

View File

1
packs/pouvoirs/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000301

0
packs/pouvoirs/LOCK Normal file
View File

8
packs/pouvoirs/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.835820 7f307bfff6c0 Recovering log #299
2025/09/15-22:15:24.845487 7f307bfff6c0 Delete type=3 #297
2025/09/15-22:15:24.845568 7f307bfff6c0 Delete type=0 #299
2025/09/15-22:23:01.591108 7f307a7fc6c0 Level-0 table #304: started
2025/09/15-22:23:01.591136 7f307a7fc6c0 Level-0 table #304: 0 bytes OK
2025/09/15-22:23:01.596986 7f307a7fc6c0 Delete type=0 #302
2025/09/15-22:23:01.597090 7f307a7fc6c0 Manual compaction at level-0 from '!items!19r9ijZUyvnlIqgm' @ 72057594037927935 : 1 .. '!items!zON0h5SjFyANjPnA' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.597120 7f307a7fc6c0 Manual compaction at level-1 from '!items!19r9ijZUyvnlIqgm' @ 72057594037927935 : 1 .. '!items!zON0h5SjFyANjPnA' @ 0 : 0; will stop at (end)

8
packs/pouvoirs/LOG.old Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.338726 7f307b7fe6c0 Recovering log #295
2025/09/15-21:06:27.348432 7f307b7fe6c0 Delete type=3 #293
2025/09/15-21:06:27.348491 7f307b7fe6c0 Delete type=0 #295
2025/09/15-21:08:54.718495 7f307a7fc6c0 Level-0 table #300: started
2025/09/15-21:08:54.718519 7f307a7fc6c0 Level-0 table #300: 0 bytes OK
2025/09/15-21:08:54.724957 7f307a7fc6c0 Delete type=0 #298
2025/09/15-21:08:54.731709 7f307a7fc6c0 Manual compaction at level-0 from '!items!19r9ijZUyvnlIqgm' @ 72057594037927935 : 1 .. '!items!zON0h5SjFyANjPnA' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.731758 7f307a7fc6c0 Manual compaction at level-1 from '!items!19r9ijZUyvnlIqgm' @ 72057594037927935 : 1 .. '!items!zON0h5SjFyANjPnA' @ 0 : 0; will stop at (end)

Binary file not shown.

0
packs/profils/000300.log Normal file
View File

1
packs/profils/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000298

0
packs/profils/LOCK Normal file
View File

7
packs/profils/LOG Normal file
View File

@@ -0,0 +1,7 @@
2025/09/15-22:15:24.861471 7f3080dfa6c0 Recovering log #296
2025/09/15-22:15:24.871507 7f3080dfa6c0 Delete type=3 #294
2025/09/15-22:15:24.871573 7f3080dfa6c0 Delete type=0 #296
2025/09/15-22:23:01.597208 7f307a7fc6c0 Level-0 table #301: started
2025/09/15-22:23:01.597240 7f307a7fc6c0 Level-0 table #301: 0 bytes OK
2025/09/15-22:23:01.603183 7f307a7fc6c0 Delete type=0 #299
2025/09/15-22:23:01.623429 7f307a7fc6c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)

7
packs/profils/LOG.old Normal file
View File

@@ -0,0 +1,7 @@
2025/09/15-21:06:27.364429 7f3080dfa6c0 Recovering log #292
2025/09/15-21:06:27.374643 7f3080dfa6c0 Delete type=3 #290
2025/09/15-21:06:27.374720 7f3080dfa6c0 Delete type=0 #292
2025/09/15-21:08:54.725160 7f307a7fc6c0 Level-0 table #297: started
2025/09/15-21:08:54.725200 7f307a7fc6c0 Level-0 table #297: 0 bytes OK
2025/09/15-21:08:54.731505 7f307a7fc6c0 Delete type=0 #295
2025/09/15-21:08:54.731723 7f307a7fc6c0 Manual compaction at level-0 from 'undefined' @ 72057594037927935 : 1 .. 'undefined' @ 0 : 0; will stop at (end)

Binary file not shown.

BIN
packs/scenes/000148.ldb Normal file

Binary file not shown.

0
packs/scenes/000271.log Normal file
View File

1
packs/scenes/CURRENT Normal file
View File

@@ -0,0 +1 @@
MANIFEST-000269

0
packs/scenes/LOCK Normal file
View File

8
packs/scenes/LOG Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-22:15:24.873861 7f307affd6c0 Recovering log #267
2025/09/15-22:15:24.883924 7f307affd6c0 Delete type=3 #265
2025/09/15-22:15:24.884000 7f307affd6c0 Delete type=0 #267
2025/09/15-22:23:01.616718 7f307a7fc6c0 Level-0 table #272: started
2025/09/15-22:23:01.616761 7f307a7fc6c0 Level-0 table #272: 0 bytes OK
2025/09/15-22:23:01.623192 7f307a7fc6c0 Delete type=0 #270
2025/09/15-22:23:01.623491 7f307a7fc6c0 Manual compaction at level-0 from '!scenes!8DjkNeeujp2qff1N' @ 72057594037927935 : 1 .. '!scenes!ypDutqjqZcr7lx6I' @ 0 : 0; will stop at (end)
2025/09/15-22:23:01.623509 7f307a7fc6c0 Manual compaction at level-1 from '!scenes!8DjkNeeujp2qff1N' @ 72057594037927935 : 1 .. '!scenes!ypDutqjqZcr7lx6I' @ 0 : 0; will stop at (end)

8
packs/scenes/LOG.old Normal file
View File

@@ -0,0 +1,8 @@
2025/09/15-21:06:27.376909 7f307b7fe6c0 Recovering log #263
2025/09/15-21:06:27.386759 7f307b7fe6c0 Delete type=3 #261
2025/09/15-21:06:27.386852 7f307b7fe6c0 Delete type=0 #263
2025/09/15-21:08:54.752330 7f307a7fc6c0 Level-0 table #268: started
2025/09/15-21:08:54.752369 7f307a7fc6c0 Level-0 table #268: 0 bytes OK
2025/09/15-21:08:54.758780 7f307a7fc6c0 Delete type=0 #266
2025/09/15-21:08:54.758945 7f307a7fc6c0 Manual compaction at level-0 from '!scenes!8DjkNeeujp2qff1N' @ 72057594037927935 : 1 .. '!scenes!ypDutqjqZcr7lx6I' @ 0 : 0; will stop at (end)
2025/09/15-21:08:54.758971 7f307a7fc6c0 Manual compaction at level-1 from '!scenes!8DjkNeeujp2qff1N' @ 72057594037927935 : 1 .. '!scenes!ypDutqjqZcr7lx6I' @ 0 : 0; will stop at (end)

Some files were not shown because too many files have changed in this diff Show More